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 alexei-led/architect --skill tools-codegraphgit clone --depth 1 https://github.com/alexei-led/architectWrote 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/alexei-led/architect/tools-codegraph)<a href="https://agentmods.dev/skills/alexei-led/architect/tools-codegraph"><img src="https://agentmods.dev/badge/skills/alexei-led/architect/tools-codegraph/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/alexei-led/architect/tools-codegraph"><img src="https://agentmods.dev/badge/skills/alexei-led/architect/tools-codegraph.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.00107 | $0.00979 |
| Opus 5.5 | $0.00043 | $0.00392 |
| Sonnet 5.5 | $0.00021 | $0.00196 |
| Haiku 4.5 | $0.00011 | $0.00098 |
Grade A, and why
tools-codegraph 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 3mo 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 — 99 lines — stays where its author put it; the contents beside it link to each section on GitHub.
codegraph
codegraph builds a persistent graph of the codebase — symbols, references, and
call edges — that you query without re-parsing each time. It answers
graph-shaped questions ast-grep can't: what depends on this, what does a change
affect, where are the hubs and cycles.
Evidence dimensions: dependency and semantic.
When to use
Use to map observed module structure against declared modules, to find import or call cycles, high-fan-in hubs, wrong-way dependencies, and to size the blast radius of a proposed change. Build the graph during the system-map step; query it during evidence gathering.
Commands
codegraph init # set up graph store; prefer an external cache/store if supported
codegraph index # full parse → build the graph
codegraph sync # incremental update after changes
codegraph status # index health + commit it was built at
codegraph query "<expr>" # query symbols / edges
codegraph context <symbol> # neighbors of a symbol (callers, callees, refs)
codegraph affected <path> # what a change to <path> reaches (blast radius)
codegraph files <symbol> # files defining/referencing a symbol
Typical flow: init once, index, then status to confirm freshness, then
query / context / affected for evidence.
Stale-index handling
Run codegraph status before each scoring query batch. If the index commit does
not match the working tree, the graph describes an old repo:
- Run
codegraph sync(incremental) orcodegraph index(full) to refresh. - If you cannot refresh (read-only target, time budget, or no approved writable
cache), the stale graph is not evidence — record the dependency dimension
tools_failedwith reason "stale index," and do not score dependency health from it.
Evidence output
Record:
dimension: dependency or semantic.source:codegraph statusfreshness, query/context/affected command, and scope.facts: cycles, hubs, fan-in/out, callers/callees, affected paths, or confirmed absence.limits: stale index, partial language coverage, unsupported files, or failed indexing.
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.
- 3mo ago First seen · 99 lines · 107 tokens per session scan A c812e536f15c
tools-codegraph is a skill published in the GitHub repository alexei-led/architect (2 stars, last pushed 13d ago), licensed MIT. It adds 107 tokens to every session and 979 once invoked, about $0.0004 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.
tools-codegraph compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| tools-codegraphalexei-led/architect | Skill | 2 | 13d ago | MIT | A | 107 | Claude Code, Codex |
| bug-fix-protocolCodeAlive-AI/ai-driven-development | Skill | 195 | today | MIT | A | 94 | Claude Code |
| kirby-debugging-and-tracingbnomei/kirby-mcp | Skill | 74 | 5d ago | MIT | A | 45 | Claude Code, Codex |
| systematic-debugginghuangwb8/skills | Skill | 51 | 5d ago | MIT | A | 43 | Claude Code, Codex |
| bensz-collect-bugshuangwb8/skills | Skill | 51 | 5d ago | MIT | A | 68 | Claude Code, Codex |
| challenge-resolveBorda/AI-Rig | Skill | 31 | today | Apache-2.0 | A | 90 | Claude Code, Codex |
| code-remediateBorda/AI-Rig | Skill | 31 | today | Apache-2.0 | A | 39 | Claude Code, Codex |