{"id":48943621,"url":"https://github.com/aouicher/graphmind","last_synced_at":"2026-05-30T08:03:01.432Z","repository":{"id":352013995,"uuid":"1213474820","full_name":"aouicher/graphmind","owner":"aouicher","description":"Local-first code intelligence for AI assistants. Turns your codebase into a knowledge graph your AI can query, navigate, and remember. 25 MCP tools.","archived":false,"fork":false,"pushed_at":"2026-05-28T14:44:39.000Z","size":90370,"stargazers_count":33,"open_issues_count":1,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-28T15:07:35.978Z","etag":null,"topics":["ai","ai-agent","ai-assistant","chatgpt","claude","claude-code","code-intelligence","cursor","embeddings","graph","graphmind","knowledge-graph","llm","mcp","memory","rust","token","tree-sitter"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aouicher.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-17T12:22:46.000Z","updated_at":"2026-05-28T14:43:52.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/aouicher/graphmind","commit_stats":null,"previous_names":["aouicher/graphmind"],"tags_count":230,"template":false,"template_full_name":null,"purl":"pkg:github/aouicher/graphmind","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aouicher%2Fgraphmind","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aouicher%2Fgraphmind/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aouicher%2Fgraphmind/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aouicher%2Fgraphmind/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aouicher","download_url":"https://codeload.github.com/aouicher/graphmind/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aouicher%2Fgraphmind/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33684419,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-30T02:00:06.278Z","response_time":92,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","ai-agent","ai-assistant","chatgpt","claude","claude-code","code-intelligence","cursor","embeddings","graph","graphmind","knowledge-graph","llm","mcp","memory","rust","token","tree-sitter"],"created_at":"2026-04-17T15:03:07.094Z","updated_at":"2026-05-30T08:03:01.426Z","avatar_url":"https://github.com/aouicher.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# graphmind\n\n[![CI](https://github.com/aouicher/graphmind/actions/workflows/ci.yml/badge.svg)](https://github.com/aouicher/graphmind/actions/workflows/ci.yml)\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n\n\u003e Your codebase has a shape. Now your AI can see it. And remember it.\n\nGraphMind turns your codebase into a knowledge graph your AI can query, navigate, and remember. Ask about dead code, dependencies, or blast radius — and get answers grounded in your actual architecture.\n\nUp to **5,700× fewer tokens** than raw search (~10M tokens saved per session). Works with Claude Code, Cursor, Windsurf, Cline, Zed, Continue, and any MCP-compatible AI assistant.\n\n\u003ctable\u003e\u003ctr\u003e\n\u003ctd\u003e\u003cimg src=\"graphmind-demo-cli.gif\" width=\"400\" alt=\"GraphMind CLI demo\" /\u003e\u003c/td\u003e\n\u003ctd\u003e\u003cimg src=\"graphmind-demo-desktop.gif\" width=\"400\" alt=\"GraphMind Desktop app\" /\u003e\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd align=\"center\"\u003e\u003csub\u003eCLI + Claude MCP integration\u003c/sub\u003e\u003c/td\u003e\n\u003ctd align=\"center\"\u003e\u003csub\u003eDesktop app — Mac \u0026amp; Windows\u003c/sub\u003e\u003c/td\u003e\n\u003c/tr\u003e\u003c/table\u003e\n\n## Why GraphMind\n\nEvery new AI session starts from zero. Your assistant re-reads the entire codebase, re-discovers architecture, and forgets every decision you explained last time. Across multiple projects, there's zero visibility into shared dependencies.\n\n**graphmind** fixes this with four layers:\n1. **Structural graph** — function-level knowledge graph per repo (AST-based, tree-sitter, 30+ languages)\n2. **Semantic embeddings** — vector search over symbols (local ONNX, OpenAI, or Voyage AI)\n3. **Persistent memory** — declarative store for decisions, patterns, conventions — survives across sessions\n4. **Cross-project links** — dependencies and relationships between registered repos\n\nEverything runs locally. No cloud. No open ports by default. No telemetry.\n\n## Benchmark\n\n![grep vs graphmind](assets/benchmark.png)\n\nComparison of token usage: `grep -r` (raw file search) vs `graphmind search` for the same query on a ~100k LOC codebase. graphmind returns ranked, structured results in under 300 tokens vs 1.5M+ for raw grep output.\n\n## Install\n\n### Desktop app (macOS) — recommended\n\nDownload the `.dmg` from [Releases](https://github.com/aouicher/graphmind/releases). The app installs the CLI for you and runs a guided onboarding that configures MCP, hooks, skill, and embeddings — no terminal needed.\n\n![GraphMind desktop app](assets/screenshot-desktop.png)\n\n| Platform | Asset |\n|----------|-------|\n| macOS (Apple Silicon) | `GraphMind-macos-arm64.dmg` |\n| macOS (Intel) | `GraphMind-macos-x64.dmg` |\n\n\u003e **Linux / Windows**: CLI only — use the shell script or direct download below.\n\n### CLI — shell script (macOS/Linux)\n\n```bash\ncurl -fsSL https://raw.githubusercontent.com/aouicher/graphmind/main/scripts/install.sh | bash\n```\n\nThen run `graphmind setup` once to configure Claude Code, hooks, and skill.\n\n### CLI — Homebrew (macOS/Linux)\n\n```bash\nbrew install aouicher/graphmind/graphmind\n```\n\n### CLI — Linux (direct download)\n\n```bash\ncurl -fsSL https://github.com/aouicher/graphmind/releases/latest/download/graphmind-cli-linux-x64 -o ~/.local/bin/graphmind\nchmod +x ~/.local/bin/graphmind\n```\n\n### From source\n\n```bash\ngit clone https://github.com/aouicher/graphmind\ncd graphmind\ncargo build --release -p graphmind-cli\ncp target/release/graphmind ~/.local/bin/\n```\n\n## Quick Start\n\n```bash\ngraphmind setup          # once — configures Claude Code, Claude Desktop, hooks, skill\ncd ~/projects/myapp\ngraphmind init           # per project — registers, installs git hooks, builds graph\n```\n\nThat's it. Claude Code and Claude Desktop will use graphmind automatically.\n\n### `graphmind setup` (once, global)\n\nConfigures your machine so all AI tools can use graphmind:\n1. Claude Code hooks (rewrites grep/find, injects session context, pre-fetches on prompts)\n2. Claude Code skill (3-layer rule: graph → memory → raw files)\n3. Claude Desktop MCP (`~/Library/Application Support/Claude/claude_desktop_config.json`)\n4. Claude Code MCP (`~/.claude/settings.json`)\n\n### `graphmind init` (per project)\n\nRegisters and indexes a project:\n1. Registers current directory\n2. Installs git hooks (auto-rebuild on commit, impact check on push)\n3. Builds the code graph\n\n```bash\ncd ~/projects/api \u0026\u0026 graphmind init\ncd ~/projects/web \u0026\u0026 graphmind init\ncd ~/projects/lib \u0026\u0026 graphmind init\n```\n\nBoth commands are idempotent — safe to re-run.\n\n### Manual setup (if you prefer granular control)\n\n\u003cdetails\u003e\n\u003csummary\u003eClick to expand\u003c/summary\u003e\n\n#### MCP server for Claude Code\n\n```bash\nclaude mcp add graphmind -- graphmind mcp\n```\n\nOr manually in `~/.claude/settings.json`:\n```json\n{\n  \"mcpServers\": {\n    \"graphmind\": {\n      \"command\": \"graphmind\",\n      \"args\": [\"mcp\"]\n    }\n  }\n}\n```\n\n#### MCP server for Claude Desktop\n\nClaude Desktop does not inherit your shell PATH. Use the full path:\n\n```json\n{\n  \"mcpServers\": {\n    \"graphmind\": {\n      \"command\": \"/opt/homebrew/bin/graphmind\",\n      \"args\": [\"mcp\"]\n    }\n  }\n}\n```\n\nConfig file location:\n- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`\n- **Windows**: `%APPDATA%\\Claude\\claude_desktop_config.json`\n\n\u003e **Tip**: Run `which graphmind` to find the correct path on your system.\n\n#### Per-project `.mcp.json` (optional)\n\n```json\n{\n  \"mcpServers\": {\n    \"graphmind\": {\n      \"command\": \"graphmind\",\n      \"args\": [\"mcp\"]\n    }\n  }\n}\n```\n\nPicked up automatically by Claude Code when you open the project.\n\n#### Claude Code search hook\n\n```bash\ngraphmind install hook-claude\n```\n\nRegisters hooks in `~/.claude/settings.json` for:\n- **PreToolUse** — rewrites grep/find/rg to `graphmind search`, provides graph results for Grep/Glob/LS tools\n- **SessionStart** — loads project context (stats, structure) at session start\n- **UserPromptSubmit** — pre-fetches relevant graph context based on the user's prompt\n- **PostToolUse** — enriches results with graph-aware suggestions\n\nBuilt-in intelligence:\n- **Exhaustive search bypass** — detects \"find all occurrences\", `grep -c`, pipes to `wc`/`sort` and lets them through\n- **Cache deduplication** — identical searches within 5 minutes are skipped (0 tokens cost)\n- **Pattern extraction** — extracts meaningful search terms from grep, find, fd, rg commands and Agent prompts\n\n#### Claude Code skill\n\n```bash\ngraphmind install skill\n```\n\n#### CLAUDE.md sync\n\n```bash\ngraphmind sync                # updates CLAUDE.md in current project\ngraphmind sync --all          # updates CLAUDE.md for all registered projects\n```\n\n#### Git hooks\n\n```bash\ngraphmind install hook-git\n```\n\n\u003c/details\u003e\n\n## Architecture\n\n```\n┌─────────────────────────────────────────────┐\n│  Claude Code / MCP Client                    │\n├─────────────────────────────────────────────┤\n│  MCP Server (rmcp SDK, stdio) — 27 tools     │\n│  gm_query · gm_fn · gm_file · gm_deps      │\n│  gm_outline · gm_who_calls_chain · gm_dead  │\n│  gm_export · gm_similar · gm_listeners      │\n│  gm_memory_search · gm_cross_query          │\n│  gm_status · gm_context · gm_diff_impact    │\n├─────────────────────────────────────────────┤\n│  Layer 1: Structural Graph (SQLite + FTS5)   │\n│  Symbols · Edges · Call sites                │\n├─────────────────────────────────────────────┤\n│  Layer 2: Semantic Embeddings (SQLite)       │\n│  Cosine search · Graph expansion · RRF      │\n├─────────────────────────────────────────────┤\n│  Layer 3: Semantic Memory (JSONL)            │\n│  Decisions · Patterns · Conventions          │\n├─────────────────────────────────────────────┤\n│  Layer 4: Cross-Project Links (JSONL)        │\n│  Shared symbols · Inferred relationships     │\n├─────────────────────────────────────────────┤\n│  Rust Core (tree-sitter + napi-rs)           │\n│  Multi-language parsing · Symbol extraction  │\n└─────────────────────────────────────────────┘\n```\n\n## Search \u0026 Embeddings\n\ngraphmind search combines three retrieval strategies into a single ranked result:\n\n```bash\ngraphmind search \"\u003cquery\u003e\"          # hybrid search (FTS + semantic + graph)\ngraphmind search \"\u003cq1\u003e; \u003cq2\u003e\"       # multi-query with RRF ranking\ngraphmind search \"\u003cquery\u003e\" --kind function\n```\n\n### How search works\n\n1. **FTS5** — exact text matching on symbol names, signatures, docs\n2. **Semantic embeddings** — cosine similarity finds conceptually related symbols (e.g. \"money transfer\" → `payment_service`)\n3. **Graph expansion** — top results are expanded with 1-hop callers/callees from the structural graph\n\nResults are fused via Reciprocal Rank Fusion (RRF, k=60). Each result shows its source: `[FTS]`, `[SEM]`, `[GRAPH]`, or combinations like `[FTS+SEM+G]`.\n\n### Embedding providers\n\nConfigured in `~/.graphmind/config.json`:\n\n```json\n{\n  \"embedding\": {\n    \"mode\": \"voyage\",\n    \"model\": \"voyage-code-3\",\n    \"api_keys\": {\n      \"voyage\": \"pa-...\"\n    }\n  }\n}\n```\n\n| Mode | Model (default) | Notes |\n|------|----------------|-------|\n| `local` | `nomic-embed-text-v1.5` (768d) | ONNX, no API key needed |\n| `openai` | `text-embedding-3-small` (1536d) | Supports custom `openai_base_url` |\n| `voyage` | `voyage-code-3` (1024d) | Code-specialized, recommended |\n| `disabled` | — | No embeddings — **default for new installs** |\n\nEmbeddings are computed automatically during `graphmind build` when a provider is configured. If the model changes, the embedding index is rebuilt automatically.\n\nOpenAI-compatible providers (Azure, proxies) can set a custom base URL:\n```json\n{\n  \"embedding\": {\n    \"mode\": \"openai\",\n    \"model\": \"text-embedding-3-large\",\n    \"openai_base_url\": \"https://your-proxy.example.com/v1\",\n    \"api_keys\": { \"openai\": \"sk-...\" }\n  }\n}\n```\n\n## Persistent Memory\n\ngraphmind gives Claude persistent memory across sessions — not just code, but decisions, patterns, conventions, and context.\n\n### How it works\n\nMemory is **fully automatic**:\n- **Auto-recall** — at each prompt, the hook searches memory for relevant context and injects it into the conversation. No action needed.\n- **Auto-save** — Claude proactively saves important facts (decisions, patterns, conventions, bugs, context) without asking. You'll see a brief mention of what was saved.\n\nThis works for both **Claude Code** (via hooks) and **Claude Desktop** (via MCP instructions).\n\n### What gets saved\n\n| Type | Examples |\n|------|----------|\n| `decision` | Architecture choices, tech decisions, trade-off resolutions |\n| `pattern` | Recurring approaches, solutions, code patterns |\n| `convention` | Naming rules, workflow conventions, style guides |\n| `bug` | Known issues, workarounds, gotchas |\n| `context` | Business context, project goals, user preferences |\n\n### Storage\n\nMemories are stored as JSONL files in `~/.graphmind/memory/`:\n- `global.jsonl` — cross-project knowledge (user preferences, team conventions)\n- `\u003cproject-slug\u003e.jsonl` — project-specific facts\n\n### Manual control\n\n```bash\ngraphmind memory add \"\u003cfact\u003e\" [--project \u003cslug\u003e] [--global]\ngraphmind memory search \"\u003cquery\u003e\"\ngraphmind memory list\ngraphmind memory delete \u003cid\u003e\n```\n\nMemories persist indefinitely until explicitly deleted. They are recalled automatically — you never need to ask \"do you remember X?\".\n\n## Commands\n\n### Setup \u0026 Init\n```bash\ngraphmind setup                   # global one-time (hooks, MCP, skill)\ngraphmind init [path]             # per-project (register, git hooks, build)\ngraphmind init --skip-build       # per-project without building\n```\n\n### Registry\n```bash\ngraphmind register [path]     # register current dir\ngraphmind unregister \u003cslug\u003e   # remove project\ngraphmind list                # all projects\ngraphmind status              # health check\n```\n\n### Build\n```bash\ngraphmind build [slug]        # incremental build\ngraphmind build --all         # all projects\ngraphmind build --full        # force full rebuild\ngraphmind build --watch       # watch mode (debounced 2s)\ngraphmind clean [slug]        # remove graph cache (forces full rebuild)\ngraphmind clean --all         # clean all projects\n```\n\n### Query\n```bash\ngraphmind query \u003csymbol\u003e                          # find symbol + connections\ngraphmind query \u003csymbol\u003e --file \u003cpath\u003e            # filter to a specific file\ngraphmind query \u003csymbol\u003e --kind function          # filter by kind\ngraphmind query \u003csymbol\u003e --limit 20 --offset 0   # paginate callers/callees\ngraphmind fn \u003csymbol\u003e                             # full detail with source + callers/callees\ngraphmind fn \u003csymbol\u003e --file \u003cpath\u003e               # disambiguate by file\ngraphmind fn \u003csymbol\u003e --kind function             # filter by kind\ngraphmind fn \u003csymbol\u003e --limit 20 --offset 0      # paginate callers/callees\ngraphmind fn \u003csymbol\u003e --include-content           # include source code in output\ngraphmind fn \u003csymbol\u003e --no-tests                  # skip test files\ngraphmind deps \u003cfile\u003e                             # file dependency map\ngraphmind impact \u003cfile\u003e                           # transitive reverse deps\ngraphmind fn-impact \u003csymbol\u003e                      # blast radius\ngraphmind diff-impact                             # impact of current git changes\ngraphmind diff-impact --staged\ngraphmind map [slug]                              # most-connected files\ngraphmind cycles [slug]                           # circular dependencies\ngraphmind outline \u003cfile\u003e                          # hierarchical symbol tree for a file\ngraphmind file \u003cfile\u003e                             # raw file content from project root\ngraphmind who-calls \u003csymbol\u003e                      # transitive caller chain (BFS)\ngraphmind who-calls \u003csymbol\u003e --depth 5            # limit traversal depth\ngraphmind dead-code                               # symbols with no incoming edges\ngraphmind dead-code --kind function               # filter by kind\ngraphmind dead-code --limit 50                    # cap results\ngraphmind similar \u003csymbol\u003e                        # structurally similar symbols\ngraphmind similar \u003csymbol\u003e --limit 10             # cap results\ngraphmind listeners \u003cevent\u003e                       # find listeners for an event name\n```\n\n### Search\n```bash\ngraphmind search \"\u003cquery\u003e\"                        # hybrid FTS + semantic + graph\ngraphmind search \"\u003cq1\u003e; \u003cq2\u003e\"                     # multi-query\ngraphmind search \"\u003cquery\u003e\" --kind class\ngraphmind search \"\u003cquery\u003e\" --offset 10            # paginate results\ngraphmind search \"\u003cquery\u003e\" --include-content      # include source code in output\n```\n\n### Embeddings\n```bash\ngraphmind embed                     # show embedding index status\ngraphmind embed --run               # generate embeddings for current project\ngraphmind embed --run --all         # generate embeddings for all projects\n```\n\n### Memory\n```bash\ngraphmind memory add \"\u003cfact\u003e\" [--project \u003cslug\u003e] [--global]\ngraphmind memory search \"\u003cquery\u003e\"\ngraphmind memory list\ngraphmind memory delete \u003cid\u003e\n```\n\n### Cross-Project\n```bash\ngraphmind cross query \u003csymbol\u003e      # search across ALL projects\ngraphmind cross deps \u003cslug\u003e         # who depends on this project\ngraphmind cross links               # all cross-project relationships\ngraphmind cross link add \u003ca\u003e \u003cb\u003e    # manual link\ngraphmind cross link infer          # auto-detect shared symbols\n```\n\n### Export\n```bash\ngraphmind export [slug] -f dot            # Graphviz dot format\ngraphmind export [slug] -f mermaid        # Mermaid diagram\ngraphmind export [slug] -f json           # JSON graph\ngraphmind export --cross -f mermaid       # cross-project diagram\ngraphmind export --obsidian ~/vault/      # Obsidian vault with [[wikilinks]]\n```\n\n### Exclude\n```bash\ngraphmind exclude list                    # show all patterns\ngraphmind exclude add grafana-data        # exclude from current project\ngraphmind exclude add grafana-data --global\ngraphmind exclude remove grafana-data\n```\n\n### Team Sync *(Pro/Team tiers)*\n\nShare your code graph and architectural memories across your team. Every member gets the same structural understanding without re-indexing.\n\n```bash\ngraphmind team init [--team-id \u003cid\u003e]   # connect to a team\ngraphmind team push [slug]             # push graph + shared memories\ngraphmind team push --memories-only    # push memories only\ngraphmind team push --graph-only       # push graph only\ngraphmind team push --all              # push all projects\ngraphmind team pull [slug]             # pull latest from team\ngraphmind team status                  # sync status per project\n```\n\n- **Auto-sync** (Team tier): graph is pushed automatically after each `graphmind build`\n- **Memory privacy**: memories marked private (`is_shared: false`) never leave the machine\n- **MCP tools**: `gm_team_memories` (shared context) · `gm_team_who_knows` (who documented a symbol)\n\n### Sessions\n```bash\ngraphmind session start [slug]      # log session start\ngraphmind session save [\"message\"]  # save session summary\ngraphmind session history [slug]    # recent sessions\n```\n\n### Install / Uninstall\n```bash\ngraphmind install hook-claude     # Claude Code search hook\ngraphmind install hook-git        # git hooks (post-commit + pre-push)\ngraphmind install skill           # Claude Code skill\ngraphmind uninstall hook-claude   # remove Claude Code hook\ngraphmind uninstall hook-git      # remove git hooks\ngraphmind sync [slug]             # inject graph context into CLAUDE.md\ngraphmind sync --all              # update CLAUDE.md for all projects\n```\n\n### Update\n```bash\ngraphmind update                  # download and install latest version\ngraphmind update --check          # check for updates without installing\n```\n\nIf installed via Homebrew, use `brew upgrade graphmind` instead. The desktop app also checks for CLI updates at startup and offers one-click update.\n\n## Token Optimization\n\nMCP responses are optimized for LLM consumption — minimal tokens, maximum signal.\n\n**Compact format (default):** One-line-per-symbol text output instead of verbose JSON. Example:\n```\n\u003e\u003e 5 result(s) for \"auth\" [FTS+semantic+graph]:\n\n  AuthService [Class] src/services/auth.ts:3 (0.95) [FTS+SEM]\n    implements Service\n  validate_token [Function] src/services/auth.ts:15 (0.82) [FTS+G]\n    (token: string, scope?: string) -\u003e TokenResult\n```\n\n**Field pruning:** No `id`, no null signature/doc/content, no redundant `total_found`/`projects_searched` fields. Only useful information is returned.\n\n**Smart limits:** Default 15 results (not 50). Truncation indicators (`+N more...`) shown only when results are capped.\n\n**Content opt-in:** Symbol source code is omitted by default. Pass `include_content: true` to any tool to get it.\n\n**JSON mode:** Pass `format: \"json\"` to any tool to get structured JSON output instead of compact text.\n\n**Hook cache deduplication:** The Claude Code hook skips duplicate searches within a 5-minute window. Same query → instant skip (0 tokens). Cache is per-session at `/tmp/graphmind-hook-cache.txt`.\n\n## MCP Tools Reference\n\ngraphmind exposes 25 tools via MCP (Model Context Protocol):\n\n| Tool | Description |\n|------|-------------|\n| `gm_query` | Find symbol and its connections |\n| `gm_fn` | Function detail with source + callers/callees |\n| `gm_deps` | File-level dependency map |\n| `gm_impact` | Transitive reverse dependencies |\n| `gm_fn_impact` | Blast radius for a symbol |\n| `gm_diff_impact` | Impact of current git changes |\n| `gm_map` | Most-connected files |\n| `gm_cycles` | Circular dependency detection |\n| `gm_search` | Hybrid search (FTS + semantic + graph) |\n| `gm_listeners` | Find event listeners by event name |\n| `gm_outline` | Hierarchical file structure with qualified names |\n| `gm_file` | Raw source content of a file |\n| `gm_who_calls_chain` | Transitive caller chain (BFS) |\n| `gm_dead_code` | Find symbols with no incoming edges |\n| `gm_export` | Export subgraph as Mermaid/DOT |\n| `gm_similar` | Find structurally similar symbols |\n| `gm_memory_search` | Search stored decisions/patterns |\n| `gm_memory_add` | Store a fact (requires confirmation) |\n| `gm_memory_list` | List memory entries |\n| `gm_cross_query` | Symbol search across all projects |\n| `gm_cross_deps` | Cross-project dependency graph |\n| `gm_cross_links` | List all cross-project links |\n| `gm_status` | Project health and stats |\n| `gm_context` | Full project context for session start |\n| `gm_list_projects` | All registered projects |\n| `gm_team_memories` | Shared team memories and context *(Pro/Team)* |\n| `gm_team_who_knows` | Who documented a given symbol *(Pro/Team)* |\n\n## Security\n\n- **No open ports by default** — MCP uses stdio.\n- **Path traversal protection** — all file ops restricted to registered paths + `~/.graphmind/`.\n- **No network calls by default** — everything runs locally. Embedding API calls only when explicitly configured. Team sync (Pro/Team tiers) is opt-in and never runs automatically on Free.\n- **API keys stored locally** — in `~/.graphmind/config.json`, never sent anywhere except the configured provider.\n- **Atomic writes** — memory JSONL writes use tmp+rename to prevent corruption.\n- **MCP write confirmation** — `gm_memory_add` requires explicit confirmation.\n\n## Language Support\n\n| Language | Extensions | Status |\n|----------|-----------|--------|\n| TypeScript | `.ts`, `.tsx` | Stable |\n| JavaScript | `.js`, `.jsx`, `.mjs` | Stable |\n| Python | `.py` | Stable |\n| Go | `.go` | Stable |\n| Rust | `.rs` | Stable |\n| Ruby | `.rb` | Stable |\n| Terraform (HCL) | `.tf`, `.tfvars` | Stable |\n| YAML | `.yml`, `.yaml` | Stable |\n| Markdown | `.md` | Stable |\n| C | `.c`, `.h` | Stable |\n| Objective-C | `.m`, `.mm` | Stable |\n| Java | `.java` | Stable |\n| PHP | `.php` | Stable |\n| Swift | `.swift` | Stable |\n| Bash | `.sh`, `.bash`, `.zsh` | Stable |\n| Perl | `.pl`, `.pm` | Stable |\n| CSS | `.css` | Stable |\n| SCSS | `.scss`, `.sass` | Stable |\n| HTML | `.html`, `.htm` | Stable |\n| TOML | `.toml` | Stable |\n| Dockerfile | `Dockerfile` | Stable |\n| SQL | `.sql` | Stable |\n| C++ | `.cpp`, `.cc`, `.cxx`, `.hpp` | Stable |\n| C# | `.cs` | Stable |\n| Kotlin | `.kt`, `.kts` | Stable |\n| Dart | `.dart` | Stable |\n| Scala | `.scala`, `.sc` | Stable |\n| R | `.r`, `.R` | Stable |\n| GraphQL | `.graphql`, `.gql` | Stable |\n| PowerShell | `.ps1`, `.psm1` | Stable |\n\n## Data Storage\n\nAll data lives in `~/.graphmind/`:\n```\n~/.graphmind/\n├── config.json          # registered projects + embedding settings\n├── memory/              # JSONL memory files\n├── graphs/\u003cslug\u003e/\n│   ├── graph.db         # structural graph (SQLite + FTS5)\n│   ├── embeddings.db    # vector embeddings (SQLite)\n│   ├── meta.json        # build stats\n│   └── cache/           # incremental build cache\n├── cross-links/         # cross-project relationships\n└── sessions/            # daily session logs\n```\n\nEverything is plaintext or SQLite — fully inspectable with standard tools.\n\n## Contributing\n\nContributions are welcome. graphmind is MIT licensed.\n\n### Setup\n\n```bash\ngit clone https://github.com/aouicher/graphmind\ncd graphmind\ncargo build --release -p graphmind-cli\ncargo clippy --workspace -- -D warnings\ncargo test --workspace\n```\n\n### Branch model\n\n| Branch | Purpose |\n|--------|---------|\n| `main` | Stable, protected. Only maintainers merge here. |\n| `feat/\u003cname\u003e` | New features |\n| `fix/\u003cname\u003e` | Bug fixes |\n| `chore/\u003cname\u003e` | Tooling, deps, CI |\n\nAll changes go through a pull request targeting `main`. Direct pushes to `main` are blocked.\n\n### Opening a PR\n\n1. Fork the repo and create a branch from `main`\n2. Make your changes — keep commits atomic and descriptive\n3. Run `cargo clippy --workspace -- -D warnings` and `cargo test --workspace` — both must pass\n4. Open a PR against `main` with a clear description of what and why\n5. One maintainer review required before merge\n\n### Tagging and releases\n\nReleases are triggered by pushing a semver tag:\n\n```bash\ngit tag v0.3.0\ngit push origin v0.3.0\n```\n\nThe CI will build binaries for macOS (arm64, x64) and Linux (x64), create a GitHub release, update the Homebrew formula, and publish the Tauri auto-updater manifest — all automatically.\n\nUse `-rc` suffix for pre-releases: `v0.3.0-rc1` (published as pre-release, skipped by Homebrew).\n\n### Reporting issues\n\nOpen a [GitHub issue](https://github.com/aouicher/graphmind/issues) with steps to reproduce, your OS, and the output of `graphmind status`.\n\nFor security vulnerabilities, see [SECURITY.md](SECURITY.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faouicher%2Fgraphmind","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faouicher%2Fgraphmind","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faouicher%2Fgraphmind/lists"}