wh:compile

wh:compile is a command for Claude Code from maxwellsdm1867/wheeler. It costs 22 tokens per session (3,776 once invoked), scanned A, original, MIT.

A command for turning a Wheeler knowledge graph into a readable research document or evidence map. A knowledge graph is a linked store of findings, sources, and claims.

In plain words
What is it for?
Use it to compile topic summaries, status reports, or evidence maps from the graph, with provenance links and citations such as `[F-xxxx]`.
Why use it?
It turns connected research records into a coherent explanation while requiring every included claim to point to its source. It also stops when the Neo4j graph database is offline.

Command for Claude Code

Part of the wh plugin — 12 skills, 40 commands, 2 agents, 3 hooks, 5 MCP servers shipped together

Install

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.

agentmods
npx agentmods add commands/maxwellsdm1867/wheeler/compile
Clone the repo
git clone --depth 1 https://github.com/maxwellsdm1867/wheeler

Made for: Claude Code.

Or install wh, the plugin that ships this one along with the rest of its 12 skills, 40 commands, 2 agents, 3 hooks, 5 MCP servers.

Wrote 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.

agentmods badge for wh:compile

README.md
[![agentmods](https://agentmods.dev/badge/commands/maxwellsdm1867/wheeler/compile.svg)](https://agentmods.dev/commands/maxwellsdm1867/wheeler/compile)
Your own site
<a href="https://agentmods.dev/commands/maxwellsdm1867/wheeler/compile"><img src="https://agentmods.dev/badge/commands/maxwellsdm1867/wheeler/compile.svg" alt="Measured on agentmods" height="20"></a>
Per session 22 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,776 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00022 $0.03776
Opus 5 $0.00011 $0.01888
Sonnet 5 $0.00004 $0.00755
Haiku 4.5 $0.00002 $0.00378

Measured 3d ago against content hash bbd3b9e3a279, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

wh:compile 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 3d 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.

.claude/commands/wh/compile.md · 431 lines

How it starts

The opening of the file, as written. The whole thing — 431 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Connectivity Check

Before proceeding: call graph_health. If it returns "status": "offline", STOP. Tell the user Neo4j is not running and provide the remediation steps from the error response. Offer to retry after they start it. Do not continue with other work.

You are Wheeler, compiling the knowledge graph into a human-readable synthesis document. This is not a data dump. You are writing a research artifact that connects findings, traces provenance, and tells a coherent story about what is known, what is uncertain, and what remains open.

The Core Rule

Every claim in the compiled document MUST cite its source node: [F-xxxx], [H-yyyy], [P-zzzz]. If you cannot cite it, do not include it. The output is a wiki-style synthesis grounded entirely in the graph.

Style Rules

  • Never use em dashes. Use colons, commas, periods, parentheses.
  • All citations use [F-xxxx] format (bracket, node ID, bracket).
  • Write prose, not just lists. Connect the dots between findings.
  • Create .notes/ directory if it does not exist.
  • The compiled document is a research artifact for the scientist, not raw query output.

Mode Selection

Parse $ARGUMENTS to determine which mode to run:

  • Starts with evidence H- or evidence Evidence Map (Mode 3)
  • Equals statusStatus Report (Mode 2)
  • No argument → Status Report (Mode 2). Topic Summary needs a topic; with nothing specified, the most useful default is a survey of the whole graph.
  • Anything else (a topic string) → Topic Summary (Mode 1)

Nothing-to-compile fast exit: Before running any mode, call query_findings(limit=1). If it returns nothing, stop and say: "Graph has no findings yet, nothing to compile. Run /wh:start to begin an investigation." Do not proceed.


Mode 1: Topic Summary

Input: /wh:compile spike timing or /wh:compile "cell type differences"

Step 1: Gather Nodes

  1. Use search_findings with the topic string to find all related nodes (limit 50).
  2. For each matched node, call show_node to get full content and metadata.
  3. Also query for related hypotheses, open questions, papers, and datasets using the topic keyword:
    • query_hypotheses with the topic keyword
    • query_open_questions with the topic keyword
    • query_papers with the topic keyword
    • query_datasets with the topic keyword

Read the full file on GitHub · 431 lines

Changes

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.

  1. 3d ago First seen · 431 lines · 22 tokens per session scan A bbd3b9e3a279

Subscribe to this mod's changes

wh:compile is a command published in the GitHub repository maxwellsdm1867/wheeler (10 stars, last pushed 6d ago), licensed MIT. It adds 22 tokens to every session and 3,776 once invoked, about $0.0001 per session on Opus 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.