Allow truncating embeddings to specified dimensions. by Davidyz · Pull Request #265 · Davidyz/VectorCode
A lot of embedding models support truncating the embedding output to accelerate the query. However, not all chromadb embedding function adapters (Ollama) support this. This PR adds the option for the users to set a customised embedding dimension where appropriate.
Note: If you changed the dimension for an existing collection, you'd need to drop it and re-vectorise. Otherwise, the queries won't work because the embedding dimensions must align.