voyage-code-2 itself does not index anything; it produces embeddings, which are then indexed by a vector database. This design actually makes it well-suited for large codebases, because embedding generation and indexing are separate concerns. You can embed code incrementally—file by file, commit by commit—without reprocessing the entire repository every time something changes. This is critical for large organizations with fast-moving codebases.
Efficiency comes from how you structure the ingestion pipeline. Instead of embedding entire repositories, developers typically embed small, meaningful units like functions or classes. This keeps each embedding focused and reduces token usage. Embeddings are generated once and stored, so search performance does not degrade as the codebase grows; only storage and indexing scale. voyage-code-2’s role ends after vector generation, which keeps its usage predictable.
Scalability is achieved by storing embeddings in a vector database such as Milvus or Zilliz Cloud. These databases are designed to handle large collections of vectors efficiently, using indexing strategies optimized for similarity search. With proper metadata filtering and indexing, developers can search across very large codebases with low latency, even as the number of embedded units grows into the millions.
For more information, click here: https://zilliz.com/ai-models/voyage-code-2