pi-codegraph
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| PI_CODEGRAPH_CONFIG | No | Path to the global configuration JSON file (overrides ~/.config/pi-codegraph/config.json). | |
| PI_CODEGRAPH_AUTO_GC | No | Automatically garbage-collect indexes for disappeared worktrees. | |
| PI_CODEGRAPH_AUTO_SYNC | No | Automatically sync the code graph index. | |
| PI_CODEGRAPH_EXECUTABLE | No | Path to the codegraph executable, overrides the optional dependency. | |
| PI_CODEGRAPH_INDEX_STORE | No | Central directory for storing code graph indexes. | |
| PI_CODEGRAPH_MAX_WORKERS | No | Maximum number of query workers for the shared daemon. | |
| PI_CODEGRAPH_ALLOWED_ROOTS | No | List of allowed project root paths, separated by the platform path delimiter. | |
| PI_CODEGRAPH_WORKER_IDLE_MS | No | Idle timeout in milliseconds before a worker is terminated. | |
| PI_CODEGRAPH_MAX_OUTPUT_CHARS | No | Maximum number of characters in tool output. | |
| PI_CODEGRAPH_PROMPT_INJECTION | No | Enable prompt injection protection. | |
| PI_CODEGRAPH_REQUEST_TIMEOUT_MS | No | Timeout in milliseconds for tool requests. | |
| PI_CODEGRAPH_SYNC_MIN_INTERVAL_MS | No | Minimum interval in milliseconds between automatic syncs. |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| codegraph_searchA | Search indexed declarations by symbol name. Returns locations only; use codegraph_explore when you need source and relationships. |
| codegraph_nodeA | Read an indexed file with line numbers and dependents, or inspect a named symbol with its source and relationships. |
| codegraph_filesB | Read the indexed project file tree. Paths are normalized to repo-relative POSIX prefixes. |
| codegraph_callersB | Find functions and methods that call a symbol, optionally selecting its definition by file. |
| codegraph_calleesA | Find functions and methods called by a symbol, optionally selecting its definition by file. |
| codegraph_impactB | Analyze the transitive impact radius of a symbol, optionally selecting its definition by file. |
| codegraph_exploreA | Explore related symbols and line-numbered source grouped by file. Best first tool for architecture, flows, and broad code questions. |
| codegraph_statusA | Report CodeGraph index health and pending synchronization state. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 8 tools
Most tools have distinct purposes: search returns locations, callers/callees handle direct relationships, impact handles transitive reach, and files/status serve different concerns. The main overlap is between codegraph_node and codegraph_explore, both of which can return source and relationships, but the descriptions clarify that node is for a single named symbol or file while explore is for broader code questions.
All tools share a consistent codegraph_ prefix and use readable lowercase names. The pattern is slightly mixed between noun-style names (node, files, status, callers, callees, impact) and verb-style names (search, explore), but the naming is still predictable and easy to navigate.
Eight tools is well-scoped for a code graph query server. Each tool covers a meaningful query mode without redundant bloat, and the count feels appropriate for both simple lookups and deeper dependency analysis.
The surface covers the core code graph workflow: locating symbols, reading source, viewing file trees, finding callers/callees, assessing transitive impact, exploring related code, and checking index health. No major lifecycle gaps are apparent for a read-only code indexing tool.