Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/shenchangmin/cairnkitWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/shenchangmin/cairnkit/flow-import)<a href="https://agentmods.dev/commands/shenchangmin/cairnkit/flow-import"><img src="https://agentmods.dev/badge/commands/shenchangmin/cairnkit/flow-import/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/shenchangmin/cairnkit/flow-import"><img src="https://agentmods.dev/badge/commands/shenchangmin/cairnkit/flow-import.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00019 | $0.00782 |
| Opus 5.5 | $0.00008 | $0.00313 |
| Sonnet 5.5 | $0.00004 | $0.00156 |
| Haiku 4.5 | $0.00002 | $0.00078 |
Grade A, and why
flow-import scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 58 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/flow-import
Make an existing project's implicit knowledge explicit as baseline draft entries.
Start or resume
Run cairn --root . import show. Resume when it succeeds. Run
cairn --root . import init only when exit 2 specifically reports that no import is in
progress; for any other error, surface it and stop.
The engine's current step is the source of truth:
| step | role mandate | required output |
|---|---|---|
doc-collect |
doc-collector |
docs/knowledge-import/01-sources.md |
codebase-profile |
codebase-profiler |
docs/knowledge-import/02-profile.md |
knowledge-build |
knowledge-builder |
docs/knowledge-import/knowledge-candidates.json and docs/knowledge-import/03-summary.md |
Isolated dispatch for every step
Before each dispatch, resolve the plugin root exactly as the router did. Read the complete role
mandate from resources/agents/<role>.md when resources/agents/ exists; otherwise read
agents/<role>.md. Never use .codex/agents, ~/.codex/agents, a copied global mandate, or a
same-named project or global profile.
Use a named role only when the host explicitly exposes that role as part of this cairnkit plugin.
Installed Codex always uses a fresh generic worker with fork_turns="none". Supply only the full
mandate, the original user request, current import step, exact allowed write scope from the
mandate, and required output paths. Tell the worker not to edit
docs/knowledge-import/import-state.json; the parent advances through cairn.
Confirm the worker inherits the required write access before dispatch. If not, stop; do not elevate permissions, never substitute the parent for the role, and never advance a failed dispatch.
After the worker returns, run the check for the current step:
test -f "docs/knowledge-import/01-sources.md" && test ! -L "docs/knowledge-import/01-sources.md" && test -s "docs/knowledge-import/01-sources.md"
test -f "docs/knowledge-import/02-profile.md" && test ! -L "docs/knowledge-import/02-profile.md" && test -s "docs/knowledge-import/02-profile.md"
test -f "docs/knowledge-import/knowledge-candidates.json" && test ! -L "docs/knowledge-import/knowledge-candidates.json" && test -s "docs/knowledge-import/knowledge-candidates.json"
test -f "docs/knowledge-import/03-summary.md" && test ! -L "docs/knowledge-import/03-summary.md" && test -s "docs/knowledge-import/03-summary.md"
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 58 lines · 19 tokens per session scan A d424336b1121
flow-import is a command published in the GitHub repository shenchangmin/cairnkit (1 stars, last pushed 3mo ago), licensed MIT. It adds 19 tokens to every session and 782 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other commands, from other repositories
genesis
Initialize cortex vault — set up config, vault structure, and rebuild index.
save
Manually save current context as a memo to the memex vault.
status
Show memex statistics and status including projects, memos, and pending items.
broadcast
Run broadcast on a distilled Raw — update related existing pages conversationally.
evolve
Save knowledge to the cortex vault (Notes or Projects) and update index.
distill
Distill raw session records into refined Notes and Projects.