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.
npx skills add kouroshez/coding-os --skill graph-os-authoringgit clone --depth 1 https://github.com/kouroshez/coding-osWrote 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/skills/kouroshez/coding-os/graph-os-authoring)<a href="https://agentmods.dev/skills/kouroshez/coding-os/graph-os-authoring"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/graph-os-authoring/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/skills/kouroshez/coding-os/graph-os-authoring"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/graph-os-authoring.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.00122 | $0.03450 |
| Opus 5.5 | $0.00049 | $0.01380 |
| Sonnet 5.5 | $0.00024 | $0.00690 |
| Haiku 4.5 | $0.00012 | $0.00345 |
Grade A, and why
graph-os-authoring 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 — 281 lines — stays where its author put it; the contents beside it link to each section on GitHub.
graph-os-authoring
Purpose: The graph is the third retrieval layer. Authoring it correctly — idempotent extraction, backend-neutral query layer, honest confidence scores — is what makes cos_graph_* tools faster + more accurate than grep. Getting any one of those wrong corrupts the graph silently, and the agent starts trusting hallucinations.
Read when: editing files matching:
src/core/graph_os/backends/*.py— SQLite (single backend today; Kuzu retired 2026-05-18 after benchmark showed SQLite p99 < 30 ms on 5-hop @ 1M nodes).src/core/graph_os/extractors/*.py— Python AST / doc / config extractors.src/core/graph_os/tools/*.py— thecos_graph_*MCP tools (also see mcp-tool-authoring).src/core/graph_os/tools/reindex_dispatch.py— incremental reindex orchestration.src/core/graph_os/types.py— node + edge type definitions (the contract).
Skip when: only querying the graph (use graph-explorer for that).
The Five Hard Contracts
1. UID scheme (immutable across rebuilds)
Every node has a uid that survives reindex. Scheme:
code:file:<path>
code:function:<path>::<name>
code:class:<path>::<name>
code:module:<dotted-name>
doc:file:<path>
doc:heading:<path>#<slug>:<level>
folder:<path>
config:<path>::<key>
Path is repo-relative, POSIX, no leading slash. Never include line numbers in uids — line numbers shift; uids must be stable.
When adding a new node type, extend the registry in src/core/graph_os/types.py and document the uid grammar there. The grammar IS the contract — agents reference uids in saved memories.
2. Idempotent extraction (keyed on uid)
Every extractor MUST be re-runnable. The contract: extracting the same file twice produces the same nodes + edges. Implementation:
def extract(file_path: Path) -> ExtractionResult:
nodes = []
edges = []
for symbol in _walk_ast(file_path):
nodes.append(GraphNode(
uid=_make_uid(symbol), # deterministic from file + symbol name
kind="function",
label=symbol.name,
file_path=str(file_path),
start_line=symbol.start,
end_line=symbol.end,
confidence=1.0, # AST gives certainty
))
for callee in symbol.callees:
edges.append(GraphEdge(
source_uid=nodes[-1].uid,
target_uid=_resolve_callee_uid(callee, file_path),
kind="calls",
confidence=_calc_confidence(callee), # see §3
))
return ExtractionResult(nodes=nodes, edges=edges)
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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 Changed · +2 lines 433c611adc51
- 3mo ago First seen · 279 lines · 122 tokens per session scan A 4e320583f3ff
graph-os-authoring is a skill published in the GitHub repository kouroshez/coding-os (7 stars, last pushed 4d ago), licensed Apache-2.0. It adds 122 tokens to every session and 3,450 once invoked, about $0.0005 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-09-03.
graph-os-authoring compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| graph-os-authoringkouroshez/coding-os | Skill | 7 | 4d ago | Apache-2.0 | A | 122 | Claude Code |
| omnigraphModernRelay/omnigraph | Skill | 3.4k | today | MIT | A | 107 | Claude Code, Codex |
| sql-root-cause-analysiszj-unicom-ai/UniEmployee | Skill | 920 | yesterday | MIT | A | 47 | Claude Code, Codex |
| fetch-dataagentscope-ai/QwenPaw-Data | Skill | 212 | yesterday | Apache-2.0 | A | 286 | Claude Code, Codex |
| dkg-importerOriginTrail/dkg | Skill | 135 | yesterday | Apache-2.0 | A | 87 | Claude Code, Codex |
| hugegraph-regression-testerapache/hugegraph-ai | Skill | 150 | 4d ago | Apache-2.0 | A | 54 | Codex |
| hugegraph-data-importerapache/hugegraph-ai | Skill | 150 | 4d ago | Apache-2.0 | A | 62 | Codex |