OKF Graph Init
Create a ready-to-use OKF bundle for graph engineering (validate, impact, ContextPack). Domain capture plugins add their own catalogs later.
When to use
- User wants a new OKF bundle or
.okf/tree - Empty repo → pack-ready structure in under two minutes
Steps
- Confirm or create the target directory (default:
.okf/at repo root; acceptknowledge/if the user prefers). - Create this structure:
.okf/
├── index.md # type: Catalog
├── log.md
├── catalogs/
│ └── index.md # type: Catalog
├── knowledge/
│ └── index.md # type: Catalog
└── packs/
└── index.md # type: Catalog (ContextPack outputs land here)
- Write root
index.mdwithokf_version: "0.2",type: Catalog, and a one-line description of the bundle. - Do not seed
AgentNode,Workflow,DecisionRecord, orTicketLink. Those nouns are owned by AGER and PKC. - Optionally seed one Catalog page and one empty ContextPack stub. Do not seed unknown types —
--strictrejects them. BaseConcept fallback is read-only. - Initialize
log.mdwith today’s date (ISO) and “Bundle created for OKF graph engine”. - Prefer absolute Markdown links:
[Label](/knowledge/example.md). - Run validation:
- Prefer
okf validate <bundle>orokfcli validate <bundle> - Fallback:
python3 ${CLAUDE_PLUGIN_ROOT}/scripts/okf-graph.py validate <bundle>
- Prefer
- Report created paths and any validation issues.
Rules
- Do not invent domain content beyond scaffolding.
- Every concept file needs YAML frontmatter with at least
type,title. - Keep subdirectory
index.mdfiles astype: Catalog. - If the target already has OKF content, merge carefully—do not overwrite existing concepts without confirmation.
Templates
Copy and fill from:
templates/index-root.mdtemplates/knowledge-concept.mdtemplates/log-entry.md
Agent/workflow/ticket templates were removed in 0.8.0. Use AGER (ager-init) or PKC (pkc-init) for those nouns.
Done when
- Bundle tree exists with root
index.md+log.md - Validation reports zero broken-link errors