spring-bootdockerchromadbspring-ai

unable to change default chroma collection name [SpringAiCollection]


Problem with Changing Default Chroma Collection Name in Spring AI

I am unable to change the default Chroma collection name in my Spring AI application.

I am trying to use the following property:

spring.ai.vectorstore.chroma.collection-name=embeddings_db

However, it doesn't seem to be working as expected. The application still uses the default collection name: SpringAiCollection.

What I've Tried

Expected Behavior

The application should use the custom collection name embeddings_db, but it continues to use the default name.

Environment

Question

How can I successfully change the default Chroma collection name to embeddings_db?

Any help would be appreciated!


Solution

  • The property key changed between 1.0.0-M1 and 1.0.0-SNAPSHOT

    You need to insert "store" between "chroma" and "collection-name"

    Find details here: https://docs.spring.io/spring-ai/reference/1.0/api/vectordbs/chroma.html