개요
CodeGraph는 코드베이스에 대한 사전 인덱싱된 지식 그래프를 구축하여, Claude Code의 탐색 에이전트가 파일을 스캔하지 않고도 심볼 관계를 빠르게 쿼리할 수 있도록 합니다. 19개 이상의 언어와 프레임워크 라우팅 인식을 지원하며, 완전히 로컬에서 실행되므로 도구 호출을 최대 96% 줄이고 탐색 속도를 70% 이상 향상시킬 수 있습니다.
README 미리보기
\n\n# CodeGraph\n\n### Supercharge Claude Code with Semantic Code Intelligence\n\n**94% fewer tool calls · 77% faster exploration · 100% local**\n\n[](https://www.npmjs.com/package/@colbymchenry/codegraph)\n[](https://opensource.org/licenses/MIT)\n[](https://nodejs.org/)\n\n[](#)\n[](#)\n[](#)\n\n\n\n### Get Started\n\n```bash\nnpx @colbymchenry/codegraph\n```\n\nInteractive installer configures Claude Code automatically\n\n#### Initialize Projects\n\n```bash\ncd your-project\ncodegraph init -i\n```\n\n\n\n\n\n---\n\n## Why CodeGraph?\n\nWhen Claude Code explores a codebase, it spawns **Explore agents** that scan files with grep, glob, and Read — consuming tokens on every tool call.\n\n**CodeGraph gives those agents a pre-indexed knowledge graph** — symbol relationships, call graphs, and code structure. Agents query the graph instantly instead of scanning files.\n\n### Benchmark Results\n\nTested across 6 real-world codebases comparing Claude Code's Explore agent **with** and **without** CodeGraph:\n\n> **Average: 92% fewer tool calls · 71% faster**\n\n| Codebase | With CG | Without CG | Improvement |\n|----------|---------|------------|-------------|\n| **VS Code** · TypeScript | 3 calls, 17s | 52 calls, 1m 37s | **94% fewer · 82% faster** |\n| **Excalidraw** · TypeScript | 3 calls, 29s | 47 calls, 1m 45s | **94% fewer · 72% faster** |\n| **Claude Code** · Python + Rust | 3 calls, 39s | 40 calls, 1m 8s | **93% fewer · 43% faster** |\n| **Claude Code** · Java | 1 call, 19s | 26 calls, 1m 22s | **96% fewer · 77% faster** |\n| **Alamofire** · Swift | 3 calls, 22s | 32 calls, 1m 39s | **91% fewer · 78% faster** |\n| **Swift Compiler** · Swift/C++ | 6 calls, 35s | 37 calls, 2m 8s | **84% fewer · 73% faster** |\n\n\nFull benchmark details\n\nAll tests used Claude Opus 4.6 (1M context) with Claude Code v2.1.91. Each test spawned a single Explore agent with the same question.\n\n**Queries used:**\n| Codebase | Query |\n|----------|-------|\n| VS Code | "How does the extens
FAQ (5)
feature_inquiryCodegraph가 코드 변경 후 자동으로 동기화되나요?
네, Codegraph는 MCP 서버가 실행 중일 때 버전 0.9.4부터 모든 파일 변경 시 자동으로 동기화됩니다. 내장된 FileWatcher를 사용하여 약 3초 이내에 심볼과 엣지를 증분 재인덱싱하며, 수동으로 codegraph sync 또는 codegraph index 명령을 실행할 필요가 없습니다. 이전 버전에서는 코드 변경 후 수동으로 codegraph index를 실행하여 업데이트해야 했습니다.
문제 해결코드그래프가 배럴 재내보내기를 통해 가져온 컴포넌트에 대해 호출자 0명을 표시하는 이유는 무엇인가요?
이것은 codegraph v0.9.8 및 이전 버전에서 특정 배럴 형식이 해결되지 않아 라이브 컴포넌트에 대해 누락된 엣지와 잘못된 0 callers/impact를 초래하는 알려진 버그입니다. 영향을 받는 형식: export { default as X } from './X.svelte', 베어 import from './' 또는 from '.', 그리고 워크스페이스 패키지-서브패스 임포트(@scope/pkg/sub). 수정(PRs #657, #659)은 이미 병합되었으며 v0.9.8 이후 다음 릴리스에 포함됩니다. 해결하려면 최신 버전(v0.9.9+)으로 업그레이드하세요. 임시 확인 방법으로 codegraph callees <file>를 사용하여 임포트가 원시/미해결 노드로 나타나는지 확인하세요.
문제 해결Windows에서 codegraph daemon을 시작하거나 브랜치를 전환할 때 콘솔 창이 깜빡이는 이유는 무엇인가요?
코드그래프 v0.9.7 이상으로 업그레이드하세요. v0.9.6의 이 버그로 인해 git.exe 스폰(예: git ls-files, git rev-parse)이 windowsHide: true 없이 실행되어 cmd 창이 보였습니다. v0.9.7의 수정에서는 모든 git/npm 자식 프로세스에 windowsHide를 추가하여 깜빡임을 제거했습니다.
문제 해결Windows에서 codegraph MCP server를 실행할 때 콘솔 창이 1초마다 깜빡이는 이유는 무엇인가요?
Windows에서 codegraph v1.6.1의 기본 파일 감시자는 git ls-files를 약 1초에 한 번씩 실행합니다. MCP 호스트가 CREATE_NO_WINDOW를 사용하는 GUI 프로세스에 의해 시작되면, Node.js가 windowsHide: true 없이 git.exe를 spawn하게 되어 Windows가 매번 보이는 conhost 창을 생성합니다. 이에 대한 해결 방법으로 감시자를 비활성화하세요:
codegraph serve --mcp --no-watch
그런 다음 필요할 때 수동으로 인덱스를 새로 고치세요:
codegraph sync
영구적인 수정 방법은 감시자/git spawn 호출이 Node.js spawn/exec에 windowsHide: true를 전달하도록 하는 것이며, 해당 수정이 포함된 릴리스가 있다면 업그레이드하세요.
문제 해결codegraph가 Delphi/Object Pascal에서 체인된 메서드 호출의 호출자와 피호출자를 놓치는 이유는 무엇인가요?
이는 codegraph 1.6.2의 알려진 버그입니다: Delphi 추출기가 MD5FileSized(TMeta.ExtendedPath(APath)).IsSame(AKey) 같은 체인 호출에서 가장 바깥쪽 메서드만 기록하고, 리시버 호출(MD5FileSized)과 그 인수 안의 호출(ExtendedPath)은 누락합니다. PR #2787(main에 병합됨)에서 수정되었으며, 이 PR은 표현식 형태와 괄호 없는 문 형태 모두에 대해 리시버 호출과 그 인수 호출을 인덱싱하고, TButton(Sender).Caption 같은 타입 캐스트 리시버도 처리합니다. 1.6.2 이후 릴리스로 업그레이드하세요. 임시 해결 방법으로 lib/dist/extraction/tree-sitter.js를 패치하세요: extractPascalCall에서 리시버 이름 처리 부분 뒤(~7317번 줄)에 this.extractPascalCall(innerCall);을 추가하고, extractPascalParenlessCall에서 클래스가 아닌 리시버 분기(~7411번 줄)에 if (receiver.type === 'exprCall') this.extractPascalCall(receiver);를 추가하세요.