philippgille/chromem-go
Embeddable vector database for Go with Chroma-like interface and zero third-party dependencies. In-memory with optional persistence.
What it solves
chromem-go is an embeddable vector database for Go applications. It allows developers to integrate retrieval augmented generation (RAG), semantic search, and recommendation systems directly into their apps without the need to run a separate, standalone database server (similar to how SQLite is used instead of a full SQL server).
How it works
The database operates in-memory with optional persistence to disk. It uses cosine similarity for exhaustive nearest neighbor search (FLAT index) to find related content. It provides a Chroma-like interface for managing collections and querying documents.
To handle embeddings, the project supports multiple hosted providers (OpenAI, Azure OpenAI, GCP Vertex AI, Cohere, Mistral, Jina, mixedbread.ai) and local providers (Ollama, llmman, LocalAI), or allows users to provide their own embedding functions or pre-calculated embeddings.
Who it’s for
Go developers who need a lightweight, zero-dependency vector store for AI features like RAG or text search, and who prefer an embedded approach over a client-server architecture.
Highlights
- Zero Dependencies: No third-party libraries required.
- Embeddable: No client-server model; the database is integrated directly into the Go binary.
- Multithreaded: Leverages Go's native concurrency for adding and querying documents.
- Flexible Storage: Supports in-memory operation with optional persistence and encrypted backups (AES-GCM).
- Broad Embedding Support: Out-of-the-box integration with numerous local and cloud embedding models.
Related
- Project
- Project
- Project
- Project