DocGraph
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| DOCGRAPH_MAX_WATCHES | No | Override the maximum number of file watches (default 8192). Override with the flag --max-watches or the environment variable DOCGRAPH_MAX_WATCHES. | 8192 |
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| docgraph_contextA | PRIMARY TOOL. Build relevant documentation context for a task or topic. Composes governance-aware search + node details + cross-references + bounded source content in one call. For a single known document, use docgraph_node instead. For broad queries, set includeContent=false or reduce maxContentBytes (default 2000, hard cap 6000) to avoid large responses; a 10-node query with default settings can produce 20–50 KB of output. |
| docgraph_exploreA | Survey several related documents and their cross-references in one call. More efficient than multiple docgraph_node calls. For a single known document, use docgraph_node instead. For governance filters or structured context, use docgraph_context instead. |
| docgraph_filesB | List all indexed files (.md, .docx, .html, .pdf). Use path filter to narrow scope (bare directory name, e.g. path=docs). For a single known doc, use docgraph_node instead. |
| docgraph_graphA | Document graph traversal facade. Operations: incoming — documents that cite/reference this document outgoing — documents this document links to impact — transitive incoming references (who depends on this) trace — shortest forward path from document A to document B over reference edges (markdown links, wikilinks, embeds); one-directional, ignores similarity/tag edges; "no path" ≠ "unrelated" |
| docgraph_historyA | Show git commit history for a document: how many times it was amended, by how many authors, first/last change dates, and the most recent commit message. Returns empty for files not tracked by git (gitignored or untracked). |
| docgraph_nodeA | Get a single document or heading's full details: metadata, structure, and cross-references. Use 'section' to read the full content of a specific heading section from the source file. For multiple documents, use docgraph_explore instead. |
| docgraph_searchA | Full-text search across all indexed Markdown documents. Returns matching documents and headings with snippets. For topic-level context, prefer docgraph_context which combines search with structure. Use governance and research filters to constrain retrieval without adding separate tools. Result paths carry a '#heading:line' suffix and (in workspace mode) a '[project/]' prefix — strip these to the bare file path before passing a path to docgraph_node / docgraph_graph / docgraph_context (a heading result also prints its bare 'parent document:' path for this). |
| docgraph_similarA | Find documents topically similar to a given document using TF-IDF term overlap + shared references + tag overlap (engine=auto/tfidf — the default, always on, no flags). Returns 0 results for a topically unique document (a broad README or changelog commonly has no similar_to edges even when the index is fully built and the engine is working): 0 does NOT mean the engine is off, embeddings are disabled, or the index is broken. Neural similarity is an OPTIONAL add-on layered on top — only if embeddings were stored via docgraph_embeddings action=store (engine=neural) are neural scores added; embeddings being disabled never causes a TF-IDF 0-result. For explicit link tracking use docgraph_graph. Accepts document paths only — heading anchors (doc.md#heading) return empty. The score is a 0-to-1 weighted blend (TF-IDF cosine 50% + shared-reference Jaccard 30% + tag Jaccard 20%); it is NOT a percentage. Each result shows the three signal components that drove its score. No per-vocabulary-term breakdown is available — the engine does not retain individual term contributions, so you cannot identify which specific terms, phrases, or mentions made a score high OR low; any per-term explanation of the TF-IDF component is fabricated. Scores are corpus-relative; 0.4-0.5 can mean near-identical in a corpus with high shared vocabulary. |
| docgraph_statusA | Index health: file count, node count, edge count, unresolved references, DB size. Use to verify the index is ready before other operations, or to inspect embedding model state, LLM callout tool state (docgraph_embeddings/docgraph_enrichment enabled/disabled + required flags), domain packs, and drift findings. Metadata quality scores (0–100) reflect frontmatter completeness; deductions for missing status, owner, or review_due are the most common and do not affect content reliability. |
| docgraph_tagsB | List all tags across indexed documents with document counts, or find all documents with a specific tag. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Detective-XH/DocGraph'
If you have feedback or need assistance with the MCP directory API, please join our Discord server