Skip to main content

Multi-language code indexing with graph database, supports Python/JavaScript/TypeScript/Java/AutoIt, auto-ignores node_modules/.git, respects .gitignore, multi-keyword search, MCP for Claude Desktop, automated installation

Project description

Claude Code Indexer

PyPI version Python License: MIT

🚀 Quick Install with VS Code

Install with PIP in VS Code Install with PIP in VS Code Insiders

📖 Description

Multi-language code indexing with graph database, supports Python/JavaScript/TypeScript/Java/AutoIt, auto-ignores node_modules/.git, respects .gitignore, multi-keyword search, MCP for Claude Desktop, automated installation.

🎯 Features

  • Multi-language Support: Python, JavaScript, TypeScript, Java, AutoIt
  • Graph Database: Advanced code relationship mapping using Ensmallen
  • Smart Ignoring: Automatically respects .gitignore and skips node_modules/.git
  • Fast Search: Multi-keyword search with FTS5 full-text search
  • MCP Integration: Seamless integration with Claude Desktop/VS Code
  • Performance: ~50 files/sec with caching enabled
  • AI Enhancement: Optional AI-powered metadata generation

📦 Installation

Via pip (Recommended)

pip install claude-code-indexer

Via VS Code MCP

Click one of the badges above to automatically configure Claude Code Indexer as an MCP server in VS Code.

Manual MCP Setup

# Install the package
pip install claude-code-indexer

# Setup MCP integration
cci mcp install

🚀 Quick Start

# Initialize project
cci init

# Index codebase
cci index .

# Search code
cci search "authentication"

# Find important components
cci query --important

# Get insights
cci insights

🤖 LLM Guidance (MCP-first)

If MCP is not set up, do this once:

cci mcp install
cci mcp-daemon start

When answering code questions, LLMs should always prefer MCP tools over manual file scanning:

  1. index_codebase (if not indexed)
  2. search_code for keywords
  3. query_important_code for key components
  4. get_project_stats + get_codebase_insights for overview
  5. enhance_metadata only when needed

📊 Commands

Core Commands

  • cci init - Initialize project with CLAUDE.md and database
  • cci index [path] - Index source code into graph database
  • cci stats - Show project statistics

Query Commands

  • cci query [--important] [--type TYPE] [--limit N] - Query indexed entities
  • cci search <keywords> - Full-text search across codebase
  • cci critical [--limit N] - Find most critical components

Analysis Commands

  • cci insights - Architectural analysis and health check
  • cci enhanced [filters] - Query AI-enhanced metadata
  • cci enhance . [--limit N] - Add AI-powered metadata (requires API)

State Management

  • cci state capture - Save codebase snapshot
  • cci state diff - Show changes since last capture
  • cci state tasks - List development task history

MCP Integration

  • cci mcp install - Setup MCP server for Claude
  • cci mcp-daemon [start|stop|status] - Background service management

🔧 MCP Server Configuration

When installed via VS Code badges or manual MCP setup, the server provides these tools:

Available MCP Tools

  • index_codebase - Index project code
  • search_code - Search codebase with keywords
  • query_important_code - Find critical components
  • get_project_stats - Get project statistics
  • get_codebase_insights - Health and architecture analysis
  • enhance_metadata - Add AI-powered metadata
  • store_llm_memory - Store analysis insights
  • store_coding_pattern - Save reusable patterns
  • store_best_practice - Document best practices

📈 Performance

Operation First Run With Cache Notes
init 1-2s N/A One-time
index 5-10s 0.5-1s 95%+ cache hit
query 0.1-0.5s 0.05s Database query
search 0.2-1s 0.1s Full-text search

🆚 Competitor Comparison (high level)

Approach Strengths Tradeoffs
CCI (graph + MCP) Local-first, structured graph, MCP tools for LLMs Needs initial indexing and MCP setup
Sourcegraph/OpenGrok Large-scale code search UI Heavier setup, less LLM-native workflows
LSP/ctags Fast editor navigation Limited cross-file graph insights
Vector search only Strong semantic matching Weaker structural/relationship precision

📊 Benchmarks (required for real comparisons)

We do not claim superiority without measurable data. Use the scripts below to capture real numbers on your machine and publish them.

# Cold run (no cache)
cci index . --force

# Warm run (cache)
cci index .

# Database benchmark
cci benchmark --records 1000

Document your results in docs/benchmarks.md.

⚠️ Security

  • Never index sensitive data (API keys, tokens, credentials)
  • Check for .env files: find . -name "*.env"
  • Add sensitive files to .gitignore

🤝 Contributing

Issues and pull requests are welcome at GitHub.

📄 License

MIT License - see LICENSE file for details.

🔗 Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

claude_code_indexer-1.29.1.tar.gz (248.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

claude_code_indexer-1.29.1-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file claude_code_indexer-1.29.1.tar.gz.

File metadata

  • Download URL: claude_code_indexer-1.29.1.tar.gz
  • Upload date:
  • Size: 248.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for claude_code_indexer-1.29.1.tar.gz
Algorithm Hash digest
SHA256 286e89c7aaa7fe5e3b91a9d47021c5d75dfac80202cee52e4ef307112dae37e9
MD5 0a3c733b8a211dc488f94c8b75232036
BLAKE2b-256 bacf8fc479663bf7e7181a51b48647c03423656e109d388d0bb2f9a82c82c02e

See more details on using hashes here.

File details

Details for the file claude_code_indexer-1.29.1-py3-none-any.whl.

File metadata

File hashes

Hashes for claude_code_indexer-1.29.1-py3-none-any.whl
Algorithm Hash digest
SHA256 603ef87f75481abcdab0055984c30063a369d0cc083d6d8a68c5468d69ee787a
MD5 3acf50be62496ca415c9d99d9c63f199
BLAKE2b-256 de34c8ee5bacfa2b0ec4153c8ae4c5dc7e6f6547722b20ae6caf537aff4f93c2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page