List all collections with pagination support
Create a new collection with optional HNSW configuration
View a sample of documents in a collection
Get detailed information about a collection
Get the number of documents in a collection
Update a collection's name or metadata
Delete a collection
Add documents with optional metadata and custom IDs
Query documents using semantic search with advanced filtering
Retrieve documents by IDs or filters with pagination
Update existing documents' content, metadata, or embeddings
Delete specific documents from a collection
Chroma MCP provides a powerful vector database implementation for AI applications, enabling efficient storage and retrieval of embeddings. It allows models to create collections over generated data and user inputs, and retrieve that data using vector search, full text search, and metadata filtering. With support for multiple client types (ephemeral, persistent, HTTP, and Cloud), Chroma MCP offers flexible deployment options for different use cases. The server implements the Model Context Protocol (MCP) to seamlessly integrate with LLM applications, providing the context they require through standardized interfaces.
Chroma MCP is a Model Context Protocol server implementation that provides vector database capabilities powered by Chroma. It enables AI models to store, organize, and retrieve data using vector search, full text search, and metadata filtering.
To add Chroma MCP to Claude Desktop, add the following to your claude_desktop_config.json
file:
"mcpServers": {
"chroma": {
"url": "https://smithery.ai/server/@chroma-core/chroma-mcp"
}
}
To self-host Chroma MCP:
Clone the repository:
git clone https://github.com/chroma-core/chroma-mcp.git
cd chroma-mcp
Install dependencies:
pip install -e .
Run the server:
python -m chroma_mcp.server
Configure your LLM client to connect to the server at http://localhost:8000
You can also run Chroma MCP using Docker:
docker pull ghcr.io/chroma-core/chroma-mcp:latest
docker run -p 8000:8000 ghcr.io/chroma-core/chroma-mcp:latest
Chroma MCP supports several client types:
For embedding functions that use external APIs, set the appropriate environment variables:
OPENAI_API_KEY
: For OpenAI embeddingsCOHERE_API_KEY
: For Cohere embeddingsJINA_API_KEY
: For Jina embeddingsVOYAGE_API_KEY
: For VoyageAI embeddingsROBOFLOW_API_KEY
: For Roboflow embeddings# Create a new collection with OpenAI embeddings
chroma_create_collection(
name="my_documents",
metadata={"description": "My important documents"},
embedding_function="openai"
)
# Add documents to a collection
chroma_add_documents(
collection_name="my_documents",
documents=["Document 1 content", "Document 2 content"],
metadatas=[{"source": "file1"}, {"source": "file2"}],
ids=["doc1", "doc2"]
)
# Query documents using semantic search
results = chroma_query_documents(
collection_name="my_documents",
query_texts=["Find similar content to this"],
n_results=5,
where={"source": "file1"}
)
# Get documents by IDs
documents = chroma_get_documents(
collection_name="my_documents",
ids=["doc1", "doc2"],
include=["documents", "metadatas", "embeddings"]
)
For more detailed information, refer to the Chroma documentation.