Guide · Agent skill
How to use the Graft Code Graph Navigator agent skill
Updated · written with AI from the project's own documentation and checked against our catalogue data
The graft skill is a set of instructions that tells an AI coding agent to look up a prebuilt index of your repository before it greps or reads source files. The index is a graft/ directory of markdown summaries plus a call and reference graph. This guide explains what the skill changes in the agent's behaviour, how to install it, how to phrase requests so it triggers, and what it needs to run.
Quick start
- 1Download and unzip the skill. Download the graft ZIP from this page and unzip it so SKILL.md sits in a graft folder.
- 2Place it in a skills folder. Move the graft folder into ~/.claude/skills/ for personal use, or into a repo's .claude/skills/ folder. Alternatively, upload the ZIP under Settings → Capabilities → Skills in the Claude apps.
- 3Install the graft CLI. Make sure the graft command runs from your terminal. The skill depends on it being available to the agent.
- 4Index the repository. Run graft build in the repo to create the graft/ directory the commands read from.
- 5Ask in plain language. Describe the task, such as where code lives or what a change would break. The agent should pick the matching graft command.
- 6Check the result. Use the returned file:line references and the source snippets to act. Run graft build again or graft check in CI if graft/ looks stale.
What the graft skill makes the agent do
Without the skill, an agent answering "where is rate limiting handled" typically searches text and reads several files. With the skill, it first queries graft/, a graph of the repo made of small markdown nodes. Each node explains one part in prose and names the exact file:line spans it covers, and a wiring graph records who calls what.
The source describes the goal as fewer tokens than rebuilding understanding from source, and catching edges a plain text search would miss. The skill sets six commands for the agent to choose between, and asks it to pick one that fits the task and act on the answer rather than chaining tools.
- ask: locate and understand code, with optional inline source
- grep: find every occurrence of a symbol or pattern
- skeleton: signatures-only view of one file
- callers: who calls a symbol, what it calls, and transitive impact
- map: an orientation tour of an unfamiliar repo
- build / check: refresh the LLM layer, or check that graft/ is not stale in CI
Install the graft skill from the ZIP
Download the ZIP for the skill from this page and unzip it. The package contains SKILL.md. Place the unzipped graft folder in one of these locations:
- Personal skills: ~/.claude/skills/
- Project skills: the .claude/skills/ folder inside a specific repository
- In the Claude apps: upload the ZIP under Settings → Capabilities → Skills
Install the graft CLI and index your repo
The skill assumes the graft CLI is already installed and available on the command line, and that the repository has an indexed graft/ directory. The source says that directory is created by graft build. Without it, the commands will not help.
The source does not give install instructions for the CLI itself, so check the graft project documentation for that step.
- Confirm graft runs from your terminal before starting the agent
- Make sure the repo has a graft/ directory; if not, run graft build from the repo
graft buildHow to trigger the skill with natural requests
The skill's description tells the agent to use graft for any task in an indexed repo: understanding how something works, finding where code lives, tracing what calls a symbol or what a change breaks, or scoping an edit. You do not need special syntax. Name the task in plain words and mention the repo's code.
Requests that map well to the commands:
- "How does authentication work in this repo?" leads to ask with source
- "Where is rate limiting handled?" leads to ask, then the agent acts on the hit
- "Rename ParseConfig, what will break?" leads to callers with depth 2 or depth all for a refactor
- "Give me the architecture of this codebase" leads to map
- "Find every call site of this constant" leads to grep
Examples of the commands in use
Each command is a single call in the typical case. The skill says most tasks need one call, and that a weak result from one tool should be followed by a different tool, not a reworded question.
For a question about where code lives, the agent runs ask with --source so the matching code comes back in the result. For a rename, it runs callers before editing so it knows every connected file. For an exhaustive search, it runs grep, which groups hits by enclosing symbol.
- ask: use -n N to cap results (default 8) and --in <path> to narrow to a subtree
- grep: use -i for case-insensitive matching and --fixed for a literal string
- callers: default direction in shows who references a symbol; --direction out shows what it depends on
- skeleton <file>: a compact API view of a single file
graft ask "where is rate-limiting handled" --source
graft grep "ParseConfig"
graft callers ParseConfig --depth 2
graft mapWhat it needs and safety notes
Requirements from the source: the graft CLI installed and on the command line, and an indexed graft/ directory created by graft build. The skill runs scripts. It does not use the network. The source says every command needs no API key.
Because the skill runs the graft CLI on your machine, review the CLI and the ZIP contents before installing, as you would any script-running extension. The source also notes that the index can lag behind uncommitted edits in one specific case: when you grep the markdown under graft/ directly, rather than using the graft commands.
- Runs scripts: yes
- Uses network: no
- Licence: MIT
- Limitations: commands depend on graft/; without it they return nothing useful
- Stale markdown: cards under graft/ are rebuilt at the end of a turn, so use the graft tools rather than grepping those files right after editing
Tips for getting good results
Ask for a specific behaviour or symbol name rather than a vague topic. When you already know the symbol, grep it directly and edit at the reported file:line. Before a rename or a multi-file change, have the agent run callers with --depth all to see sibling and downstream files.
If a grep misses, the source advises loosening the pattern to a bare symbol name and retrying graft grep, not falling back to raw grep -rn. In a monorepo, add --in with the sub-project path to ask, grep or callers.
- Use short symbol names in grep, not full signatures
- Narrow monorepo searches with --in <scope>/
- Treat the skill as a navigator: a single well-chosen call is usually enough
What people use it for
- Onboarding to an unfamiliar repo by starting with graft map and reading the hub cards it names
- Finding where a behaviour lives before adding a feature, using ask with --source
- Checking every caller of a function before renaming it or changing its signature with callers --depth 2
- Planning a multi-file refactor by running callers --depth all to find connected files
- Finding every call site of a constant or literal with grep
Frequently asked questions
How do I install the graft agent skill?
Download the ZIP from this page and unzip it. Put the graft folder in ~/.claude/skills/ for personal use or in a repo's .claude/skills/ folder for one project. In the Claude apps, you can upload the ZIP under Settings → Capabilities → Skills.
What does the graft skill require to work?
The graft CLI must be installed and available on the command line, and the repository needs an indexed graft/ directory created by graft build. The source says the commands will not help without that directory.
Is the graft skill free, and what is its licence?
The item is listed under the MIT licence. The source does not mention pricing, and it says the commands need no API key.
Does the graft skill use the internet?
No. The listing says it does not use the network, but it does run scripts, so review what you install.
Why does graft miss results that grep finds?
The ask command returns ranked top-N hits, so it can miss instances. Use graft grep for exhaustive search. If graft grep returns nothing, the source advises loosening the pattern to the bare symbol name rather than a full signature.
Can I use graft with a monorepo?
Yes. The source says graft ranks fairly across multiple repos in a workspace and labels hits with the sub-project name. Narrow a search with --in <scope>/ on ask, grep or callers.
New agent skills, repos and AI tools — every week
The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.
Our verdict
Use the graft skill if you work in a large indexed codebase and want an agent to answer where code lives, what calls what, or what a refactor will touch, with fewer tokens than reading files. Skip it if your repo has no graft/ index, if you need current markdown docs right after editing, or if you want an install with no CLI setup.
Download the skill