A super light-weight embedded code search engine CLI (AST based) that just works - saves 70% token and improves speed for coding agent 🌟 Star if you like it!
2.5k
Stars
197
Forks
26
Open issues
17
Contributors
AI Analysis
CocoIndex Code is an AST-based semantic code search CLI tool designed to reduce token usage by 70% and improve performance for coding agents and LLM-assisted development workflows. It serves developers and AI agents working with large codebases who need efficient context retrieval without configuration. This is a specialized tool optimized for AI-agent integration (Claude, Cursor, Codex) and context-window optimization—not a general-purpose code search engine for typical IDE usage.
Inferred from signals mentioned in the README (tests, CI, type safety) — not a review of the actual code.
AI's overall editorial judgment — not an average of the bars above, can weigh other factors too.
AST-based embedded code search CLI that plugs into AI coding agents to reduce token usage
cocoindex-code is a lightweight CLI tool that indexes a local codebase using AST-aware semantic search, then exposes results to coding agents (Claude Code, Codex, Cursor) via a Skill or MCP server interface. Its primary value proposition is reducing the tokens an AI agent must consume to locate relevant code — claimed at 70% reduction — by returning precise, structurally-aware search results instead of feeding entire files. Built on top of CocoIndex, a Rust-based data transformation engine, it supports both local embeddings (no API key) and cloud providers via LiteLLM. Target users are developers using AI-assisted coding workflows who want faster, cheaper agent interactions on large codebases.
Created in February 2026, cocoindex-code is a very young project (~4.5 months old as of evaluation date), launched to capitalize on the rapid growth of AI coding agent tooling and the MCP ecosystem.
The project reached 2,180 stars in roughly 4.5 months, suggesting an initial burst driven by the AI developer tooling trend and cross-promotion from the parent CocoIndex project. The 46 stars in the last 7 days indicates continued but slowing organic interest rather than a viral spike. The fork count (174) is moderate and suggests some developers are actively experimenting with or extending the tool.
No independent case studies, blog posts, or third-party production usage reports are cited in the README. The PyPI monthly download badge is present but the count is obscured (commented out in the README source). Discord community presence and the Claude Code plugin marketplace listing suggest real users exist, but quantified production usage at scale is not verified.
Appears to be a Python CLI application (pipx/uv installable) layered on top of the CocoIndex Rust engine for performance-critical indexing. Likely uses tree-sitter or a similar AST parsing library to extract code structure. Embedding is handled either locally via sentence-transformers (Snowflake arctic-embed-xs by default) or remotely via LiteLLM. The MCP server mode and Skill integration suggest a thin adapter layer exposing the same search functionality over a protocol compatible with Claude Code and similar agents. Architecture appears modular: slim vs full install variants manage dependency footprint.
Not documented in README. CI badge is present and linked to a GitHub Actions workflow, which indicates some automated testing exists, but coverage level and scope are unknown.
Last push was 2026-06-19, one day before evaluation date — the project is actively maintained. CI and release workflows are both badged and appear active. Active Discord community is linked, suggesting ongoing developer engagement. Given the project's age (~4.5 months), the cadence appears healthy.
ADOPT IF: you are using Claude Code, Codex, or another MCP/Skill-compatible agent on a medium-to-large codebase and context window costs or latency are a real concern — setup is genuinely minimal. AVOID IF: you need production-grade reliability guarantees, enterprise support, or auditable search quality on mission-critical codebases; the project is too young for that confidence level. MONITOR IF: you are building tooling or workflows around AI coding agents and want to see whether the MCP ecosystem standardizes around solutions like this before committing.
Independent dimensions
Mainstream potential
5/10
Technical importance
6/10
Adoption evidence
3/10
- Project is only ~4.5 months old; API surface, configuration format, and index schema may change in breaking ways without a mature stability guarantee.
- The 70% token reduction claim is not independently verified in the README and may vary significantly depending on codebase size, language, and query type.
- Dependency on the parent CocoIndex Rust engine means issues or breaking changes there propagate downstream; the coupling is opaque from the README alone.
- The AI coding agent integration landscape (MCP, Skills, Cursor plugins) is evolving rapidly — tight coupling to current agent APIs creates a risk of compatibility rot if agent vendors change protocols.
- Local embedding quality (Snowflake arctic-embed-xs) for code search is a known tradeoff — small models may underperform on complex or domain-specific code, and this is not acknowledged in the README.
Likely to grow steadily as the MCP ecosystem matures and AI coding agent usage expands, but may face consolidation pressure if major agent platforms build native codebase indexing. A niche but durable tool if maintained consistently.
Newsletter
Get analyses like this every Monday
Free weekly digest of the most interesting open-source discoveries.
Languages
Information
- Website
- https://cocoindex.io/
- Language
- Python
- License
- Apache-2.0
- Last updated
- 1w ago
- Created
- 5mo ago
- Analyzed with
- anthropic/claude-haiku-4-5
Stars over time
Contributors over time
Top 100 contributors only — repos with more will plateau at 100.
Open issues
Search/index do not recover when target_sqlite.db is missing but state DB remains
Creation of multiple ccc projects for same codebase
support full text search in cocoindex-code
Feature: User supplied languages
Failed the setup in Cline
Top contributors
Similar repos
cocoindex-io/cocoindex
CocoIndex is an incremental indexing engine for AI agents that continuously...
giancarloerra/SocratiCode
SocratiCode is an open-source codebase intelligence engine that provides...
| Repository | Stars | Week Δ | Language | Score | Updated |
|---|---|---|---|---|---|
|
|
2.5k | +128 | Python | 8/10 | 1w ago |
|
|
10.7k | — | Rust | 7/10 | 1d ago |
|
|
3.1k | — | TypeScript | 8/10 | 2w ago |
|
|
96.9k | — | Rust | 8/10 | 3h ago |
|
|
59k | — | TypeScript | 8/10 | -8 min ago |
|
|
12.1k | — | TypeScript | 8/10 | 3w ago |
Zoekt is a mature, battle-tested trigram-based code search engine used at scale in production. cocoindex-code targets semantic/conceptual search via embeddings and AST rather than exact-match or regex, and is positioned as an embedded CLI rather than a hosted service. Different use cases with some overlap.
Aider has its own repo-map feature for summarizing codebase structure to reduce LLM context. cocoindex-code focuses specifically on semantic search as a pluggable component rather than being a full coding assistant, making it potentially complementary rather than directly competing.
Continue offers codebase indexing and context retrieval within an IDE extension. cocoindex-code is agent/CLI-first and integrates via MCP or Skill protocol, so it can work across multiple agent surfaces rather than being tied to a specific IDE.
Greptile is a hosted cloud service for semantic code search targeted at teams. cocoindex-code is fully local/embedded with no data leaving the machine by default, which is a meaningful differentiator for privacy-sensitive or offline scenarios.
Tools like ast-grep and semgrep use AST patterns for structural search but require writing explicit patterns. cocoindex-code uses embeddings for fuzzy/semantic queries without requiring the user to know exact syntax or patterns, lowering the usage barrier for exploratory search.