MCP server for querying cocoindex code embeddings database
Wellknown found it in public sources; nobody has proven control of it yet. Claiming takes one click if the repository is under your GitHub account, or a small file on your domain otherwise. Verified owners get the badge, 15-minute checks, status alerts, edits that outrank crawled data, and a ranking boost.
Agents can do it too: POST https://wellknown.network/api/v1/claims with {"agent":"cocoindex-mcp","method":"well_known_file"} — machine-readable steps at claim.json, guide at /docs/claim.
Everything here was measured by our prober or read from a registry. Nothing is self-reported.
Attributed to the source that supplied each field. Treated as claims, not facts.
# cocoindex-mcp Semantic code search for Model Context Protocol clients, powered by cocoindex flows and a Postgres + pgvector backend. --- ## At a glance - 🔍 **Semantic search** over the embeddings produced by the cocoindex `CodeEmbedding` flow. - 🤝 **MCP-native** stdio server that drops straight into Claude Desktop, Cursor, and other MCP hosts. - ⚙️ **Zero-surprise configuration** via a single `COCOINDEX_DATABASE_URL` environment variable (with `.env` support). - 🚀 **Packaged for uv** – run it instantly with `uvx --from yalattas/cocoindex-mcp cocoindex-mcp`. ## Table of contents - [At a glance](#at-a-glance) - [How it works](#how-it-works) - [Prerequisites](#prerequisites) - [Quick start](#quick-start) - [Configuration](#configuration) - [Running the server](#running-the-server) - [Available MCP tools](#available-mcp-tools) - [Troubleshooting](#troubleshooting) - [Local development](#local-development) - [Contributing](#contributing) - [License](#license) ## How it works The server wraps a cocoindex flow that embeds local source files into a Postgres table called `code_embeddings`. Every query is transformed with the same SentenceTransformer model and matched against the stored vectors using cosine similarity via `pgvector`. Results are streamed back to the MCP client with file paths, the matched snippet, score, and optional line numbers. Internally the server is built with: - [`mcp.server.fastmcp`](https://pypi.org/project/mcp/) to expose stdio-based MCP tools. - [`cocoindex`](https://pypi.org/project/cocoindex/) for defining and running the embedding flow. - [`psycopg_pool`](https://www.psycopg.org/psycopg3/docs/pool.html) and `pgvector` for high-throughput vector queries. - [`python-dotenv`](https://pypi.org/project/python-dotenv/) to honor environment files automatically. ## Prerequisites 1. **Python** ≥ 3.11 (only needed for local installs; `uvx` ships its own runtime). 2. **PostgreSQL** with the [`pgvector`](https://github.com/pgvector/pgvecto…
Mapped onto the structured taxonomy from declared text and observed tool names. Confidence shown for derived entries.
Every source is kept verbatim. Field changes are logged as events.