DEV.co
Vector Databases · philippgille

chromem-go

chromem-go is an embeddable vector database for Go applications that enables retrieval-augmented generation (RAG) and semantic search without requiring a separate database server. It operates in-memory with optional persistence, supports multiple embedding providers (OpenAI, Cohere, Ollama, etc.), and has zero third-party dependencies.

Source: GitHub — github.com/philippgille/chromem-go
1k
GitHub stars
70
Forks
Go
Primary language
MPL-2.0
License (OSI-approved)

Key facts

Objective fields from the source. Values we can't verify are shown as “Unknown” rather than guessed.

FieldValue
Repositoryphilippgille/chromem-go
Ownerphilippgille
Primary languageGo
LicenseMPL-2.0 — OSI-approved
Stars1k
Forks70
Open issues17
Latest releasev0.7.0 (2024-09-01)
Last updated2026-05-17
Sourcehttps://github.com/philippgille/chromem-go

What chromem-go is

A pure-Go vector database using exhaustive cosine-similarity nearest-neighbor search, offering concurrent document processing, optional gob-based persistence with gzip/AES-GCM compression, and pluggable embedding functions. Achieves ~0.3ms query latency for 1,000 documents and ~40ms for 100,000 documents on mid-range Intel hardware.

Quickstart

Get the chromem-go source

Clone the repository and explore it locally.

terminalbash
git clone https://github.com/philippgille/chromem-go.gitcd chromem-go# follow the project's README for install & configuration

Need it deployed, integrated, or customized instead? DEV.co ships production installs.

Best use cases

Embedded RAG in Go Applications

Add retrieval-augmented generation directly into Go services without deploying a separate vector database. Ideal for knowledge-base-backed chatbots, question-answering systems, and semantic search features in internal tools.

Prototyping and Development

Rapidly prototype vector-search workflows with zero infrastructure overhead. Chroma-compatible interface reduces cognitive load when migrating to production databases later.

Edge and Embedded Deployments

Bundle vector search into standalone Go binaries, edge services, or offline-first applications where running a separate database is impractical. Includes WebAssembly bindings for browser-based embedding.

Implementation considerations

  • Persistence model writes one file per collection-document pair (gob format); understand write amplification and file-system overhead for high-throughput ingestion scenarios.
  • Multithreaded AddConcurrently() method available but no details provided on concurrent query behavior or locking strategy—review source or contact maintainer for thread-safety guarantees during mixed read-write workloads.
  • Embedding creation is automatic but requires network calls to hosted providers (OpenAI, Cohere, etc.) or local services (Ollama); plan for latency, rate limits, and cost in high-volume scenarios.
  • Memory consumption grows linearly with document and embedding count; pre-size Go heap and monitor for OOM in long-running services with unbounded data growth.
  • Cosine similarity only; if your use case requires different distance metrics (Euclidean, dot product, Hamming), custom similarity may require forking or waiting for roadmap updates.

When to avoid it — and what to weigh

  • Large-Scale Deployments (millions of documents) — Project explicitly targets simplicity over scale. Exhaustive search and in-memory design are not suited for datasets requiring distributed indexing or sub-millisecond queries at production scale.
  • Multi-Tenant or Multi-Service Architecture — Embeddable design means each application instance has its own database copy. No client-server separation complicates shared data access across services or tenants.
  • Advanced Indexing or Filtering Requirements — Supports only basic metadata exact-match and document substring filters. Lacks sophisticated filtering, range queries, or approximate nearest-neighbor indices (HNSW, IVF) needed for complex retrieval pipelines.
  • Mission-Critical Systems Without Extensive Testing — Project is in beta (pre-v1.0.0) with potential breaking changes. 17 open issues and recent heavy construction indicate ongoing stability work; not recommended for production without thorough evaluation.

License & commercial use

Licensed under Mozilla Public License 2.0 (MPL-2.0), a weak copyleft license requiring source disclosure of modifications to chromem-go itself but not derivative works that link it. Suitable for proprietary applications with proper attribution.

MPL-2.0 permits commercial use, but requires that any modifications to the library code be made available under the same license. Linking a proprietary Go application to unmodified chromem-go is allowed. Review the full MPL-2.0 text or consult legal counsel if you plan to modify the library itself; no explicit commercial support or indemnification is documented in the project.

DEV.co evaluation signals

Editorial assessment — not user reviews. Directional, with an explicit confidence level.

SignalAssessment
MaintenanceActive
DocumentationAdequate
License clarityClear
Deployment complexityLow
DEV.co fitStrong
Assessment confidenceHigh
Security considerations

No security audit or threat model provided in public data. AES-GCM encryption available for backup exports (not runtime queries). Persistence relies on gob encoding without explicit authentication or access control; ensure files are protected by OS-level file permissions. Dependency on external embedding services (OpenAI, Cohere) introduces supply-chain and API-key management considerations. No rate-limiting or query validation built in; malformed queries or memory exhaustion attacks possible in untrusted input scenarios.

Alternatives to consider

Chroma (Python)

Production-grade vector database with client-server model, broader feature set, and mature ecosystem. Better for multi-service architectures or when Python is the primary language; more complex to embed in Go.

Milvus

Distributed vector database with approximate nearest-neighbor indexing (HNSW), SQL filtering, and cloud-native deployment. Suitable for millions of documents and multi-tenant scenarios; requires separate infrastructure.

Qdrant

Rust-based vector database with API support for Go, approximate search, filtering, and payload storage. Offers better scalability than chromem-go with modular deployment; adds operational complexity.

Software development agency

Build on chromem-go with DEV.co software developers

chromem-go lets you embed vector search directly into your codebase. Evaluate whether its in-memory architecture and pre-v1.0 stability align with your production requirements. For complex, multi-tenant, or large-scale retrieval pipelines, contact our team to discuss alternatives like Qdrant or Milvus.

Talk to DEV.co

Related open-source tools

Surfaced by semantic similarity across the DEV.co open-source index.

Related on DEV.co

Explore the category and the services that help you build with it.

chromem-go FAQ

Can I use chromem-go in production?
The project is in beta (pre-v1.0.0) and may introduce breaking changes. Suitable for low-to-medium volume workloads (<100K documents) and non-critical systems. For mission-critical deployments, plan for version pinning, testing, and contingency migration paths.
Does chromem-go support distributed or clustered deployments?
No. Embeddable design means each application instance has its own isolated database. For multi-service architectures, consider external vector databases (Qdrant, Milvus, Chroma) that support client-server models.
What embedding models does chromem-go support?
Out-of-the-box: OpenAI, Azure OpenAI, GCP Vertex AI, Cohere, Mistral, Jina, mixedbread.ai, Ollama, and LocalAI. Custom embeddings via EmbeddingFunc interface or pre-computed embeddings passed during document add.
How much memory does chromem-go use?
Linear in document and embedding count. No public profiling data per document provided, but exhaustive search and in-memory storage imply ~1-2 KB+ per document with embeddings. Monitor heap in production and pre-size accordingly.

Work with a software development agency

Adopting chromem-go is usually one piece of a larger software development effort. As a software development agency, DEV.co provides software development services and web development expertise — pairing senior software developers and web developers with your team to design, build, and operate vector databases software in production.

Ready to Add Semantic Search to Your Go Application?

chromem-go lets you embed vector search directly into your codebase. Evaluate whether its in-memory architecture and pre-v1.0 stability align with your production requirements. For complex, multi-tenant, or large-scale retrieval pipelines, contact our team to discuss alternatives like Qdrant or Milvus.