Skip to content
GitHub

okf commands list

Command pages are generated from the command tree by okf-docgen. This page lists every visible command and every ctx verb, grouped as in okf --help. Open a command to see its usage and options.

The text of okf --help still describes the Python script [l2j0]. The option lists are correct.

Global options

--root and --global belong to okf itself and go before the command.

Option Meaning
--root ROOT Catalogue root. Default: the nearest catalogue above the current directory.
--global Use the root in ~/.config/okf/config.toml, even when a catalogue lies above. Not allowed together with --root (exit 2).

--json is not global [oyw7]. Each command declares it and it goes after the command: okf find git --json. Every command except okf registry accepts it; each ctx verb accepts it, okf ctx alone does not. okf --json list fails with unrecognized arguments: --json. See JSON output and exit codes.

For the ctx workflow, see Context bundles.

Commands by purpose

  • okf ctx: context bundles: curated, ordered reading lists per topic (ctx lists them, ctx <slug> shows one)
  • okf index: catalogue TOC (bundle names + one-line descriptions), or one bundle’s index.md
  • okf info: print catalogue schema docs (TYPES.md + PROPERTIES.md)
  • okf list: list the complete, unranked set of concepts a required –where expression selects
  • okf prime: one-shot agent onboarding: usage guide, command directory, catalogue state and bundle TOC
  • okf read: print one concept page
  • okf recent: list the most recently created concepts, newest first
  • okf sync-export: print a canonical block’s payload for materialisation elsewhere
  • okf toc: print a concept’s headings (default: h2 only)
  • okf visualize: write a viz.html concept graph for a bundle (embeds every concept body; needs network for cytoscape/marked)
  • okf build-index: (re)build the FTS5 lexical search index at /.fts/fts.sqlite (local only, no network)
  • okf build-semantic-index: fill /.tagvec/tag_vectors.sqlite’s concept_emb table for every concept still missing a voyage-3-large embedding (NETWORK, requires VOYAGE_API_KEY)
  • okf find: hybrid ranked search: lexical FTS5/BM25 arm plus semantic arm
  • okf refs: list inbound and outbound markdown links of a file
  • okf tui: keyboard-first terminal UI: search the catalogue, screen hits

tags

  • okf merge-tags: merge/rename one or more tags into a target tag across concept frontmatter
  • okf normalize-tags: convert inline tags: [...] fields to YAML block-list form (local convention)
  • okf remove-tags: remove one or more tags from concept frontmatter (no merge target)
  • okf tags: list all tags with usage counts, or fuzzy-search candidate tags

maintenance

  • okf archive: move a concept into _archive//, or back with –restore (dry-run default)
  • okf check: conformance scan: §9 hard rules + local invariants
  • okf fix-crosslinks: rewrite links to catalogue-root-absolute form (/bundle/subdir/concept.md)
  • okf fix-xml-tags: wrap <tag>/<tag>.<tag2> placeholders in inline code
  • okf install: register okf, its agent skill, MCP server and shell completion with this machine’s agents and shells (dry-run default; needs no catalogue)
  • okf migrate: migrate frontmatter to OKF 0.2: timestamp to generated (git), status per D37 (dry-run default)
  • okf registry: reformat registry entries of TAGS.md or TYPES.md (table or block form); prose stays
  • okf reindex: (re)generate marker-bounded index listings: index.md one level, index-map.md the whole subtree
  • okf rename: move a concept + rewrite every inbound/outbound link + reindex (dry-run default)
  • okf rewrite-path: literal path-string rewrite across text files
  • okf sync-insert: materialise a canonical block inside a consumer concept (dry-run default)
  • okf sync-status: drift report for every materialised canon block
  • okf sync-update: re-materialise outdated consumer blocks from their canon owner (dry-run default)
  • okf verify: record that a concept was checked against its sources
  • okf wikilinks: report Obsidian wikilinks ([[…]]) and whether each resolves to a concept