Skip to content
Documentation
Skill

/validate

Check that an Open Knowledge Format (OKF) bundle is conformant with the v0.2 spec (§11). Use when asked to validate, lint, or check an OKF bundle, or before committing changes to one. Runs a deterministic Python checker — not an eyeball pass. Also migrates a v0.1 bundle to v0.2

From plugin
scaccogatto-okf
4304 skills2 agents1 hook1 MCP

Claude Code

$ npx -y skills add scaccogatto/okf-skills --skill validate --agent claude-code

SKILL.md

validate.SKILL.md
name: validate
description: >-
  Check that an Open Knowledge Format (OKF) bundle is conformant with the v0.2
  spec (§11). Use when asked to validate, lint, or check an OKF bundle, or before
  committing changes to one. Runs a deterministic Python checker — not an
  eyeball pass. Also migrates a v0.1 bundle to v0.2 in place with `--migrate`.
user-invocable: true
argument-hint: "[bundle-dir] [--strict | --max-warnings N] [--migrate]"
allowed-tools: Bash

Validate an OKF bundle

Run the deterministic conformance checker against the target bundle. Default to the project's `.okf/` directory when no path is given.

uv run "${CLAUDE_SKILL_DIR}/scripts/okf_validate.py" $ARGUMENTS

If `uv` is unavailable, fall back to:

python3 -m pip install --quiet pyyaml && \
python3 "${CLAUDE_SKILL_DIR}/scripts/okf_validate.py" $ARGUMENTS

`${CLAUDE_SKILL_DIR}` resolves whether this skill runs as part of the `okf` plugin or is installed standalone (e.g. via `npx skills add`), so the checker is always found alongside the skill.

Interpret the result:

  • **ERROR** → a hard §11 conformance failure (no parseable frontmatter, a

missing/empty `type`, or a file the checker cannot read as UTF-8). The bundle is non-conformant. Fix every one.

Only `index.md` and `log.md` are reserved: §11.1 makes *every* other `.md` in the tree a concept, convention files included. An `AGENTS.md` or `README.md` dropped next to a bundle is therefore an ERROR until it carries frontmatter with a `type` (`Document` reads well), which is the fix; a skip-list would put the checker out of conformance. Move the file above the bundle root if it is not knowledge.

  • **warn** → soft guidance (missing recommended field, non-ISO log date, broken

cross-link, a malformed v0.2 family, a footnote naming no source, an actor that misses the §7 shapes, an Attested Computation missing `runtime`, a computation path that resolves nowhere, frontmatter in a reserved file (§8, §9), a root `index.md` carrying extra keys or declaring a different `okf_version` (§12)). Never blocks; broken links in particular are explicitly tolerated by the spec (§6.1). Fix when cheap.

One warning is worth more than the others: a §7 near-miss such as `Human:dana` or `human/dana`. §5.3 keys trust tiers off the exact lowercase `human:` prefix, so the concept silently reads as machine-confirmed when a person did review it. Fix that one on sight.

v0.1 bundles validate too: a legacy `timestamp` or `# Citations` section is reported as a warning naming its v0.2 replacement (`generated.at`, `sources`), never as an error (§13.1). Under `--strict` those warnings do fail the run — that is the migration nudge, and `--migrate` is the door.

Migrating a v0.1 bundle

`--migrate` **rewrites the bundle in place** before validating — the one mode of this skill that is not read-only, so say what it will touch before running it on a bundle the user has not asked to migrate. It is textual (comments, key order and quoting survive) and idempotent.

uv run "${CLAUDE_SKILL_DIR}/scripts/okf_validate.py" .okf --migrate --strict

It hoists `timestamp` to `generated: { by: process:okf-migrate, at }`, lifts a `# Citations` list into `sources`, and bumps `okf_version`. Two limits worth repeating to the user: `generated.by` cannot be recovered for pre-v0.2 content (hence the `process:` actor — the concept stays correctly `unverified` under §5.3), and per-claim `[^id]` attribution was never encoded in v0.1, so only the source list moves up.

Exit codes

Non-zero if any error is present, or if warnings exceed the gate: `--strict` allows none, `--max-warnings N` allows N, the default allows any. Add `--json` for machine-readable output (useful in CI).

Read more
@scaccogatto
Ships withscaccogatto-okf

**Teach your coding agent to author, maintain, validate and visualize portable knowledge bundles: markdown your team and your agents both read.** Open the live demo: a real bundle as an interactive graph.

4304 skills2 agents1 MCP
Get the whole plugin

Stars on GitHub

Momentum

stars in total
430
Star history of scaccogatto/okf-skills on GitHub, a chart by star-history.com

Other skills on scaccogatto-okf.

backfill

backfill

Reconstruct an OKF bundle by event-sourcing a repository's history (git log and Claude session transcripts). Use when creating an…

okf

okf

Author, maintain, and consume Open Knowledge Format (OKF) knowledge bundles — portable markdown + YAML frontmatter that both…

visualize

visualize

Render an Open Knowledge Format (OKF) bundle as a single self-contained, interactive HTML graph (viz.html) — concepts as nodes…

More skills from other plugins.

context7-cli

context7-cli

Use the ctx7 CLI to fetch library documentation and configure Context7 MCP. Activate when the user mentions "ctx7" or "context7",…

context712d64k
@upstash@upstashInstall Skill
docs-components

docs-components

Comprehensive MDX component patterns (Note, Pitfall, DeepDive, Recipes, etc.) for all documentation types. Authoritative source…

@reactjs@reactjsInstall Skill
codebase-wiki

codebase-wiki

How to work in a Codebase Wiki project (the `codebase-wiki` starter pack): an agent-authored, source-grounded wiki of the…

@inkeep@inkeepInstall Skill

Questions about validate.

Which coding agents can use validate?
validate installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.