通过yml开关控制使用哪些模型和向量库

This commit is contained in:
thinkgem
2025-06-18 10:59:44 +08:00
parent 28293383dd
commit 5fc096ab0a
4 changed files with 46 additions and 9 deletions

View File

@@ -3,6 +3,13 @@
spring:
ai:
# 模型选择openai、ollama
model:
chat: ollama
embedding: ${spring.ai.model.chat}
image: ${spring.ai.model.chat}
audio: ${spring.ai.model.chat}
# 在线大模型【请在 pom.xml 中打开 openai 的注释,并注释上其它模型】
openai:
@@ -83,6 +90,9 @@ spring:
# 向量数据库配置
vectorstore:
# 向量库类型chroma、pgvector、elasticsearch、milvus
type: chroma
# Chroma 向量数据库【请在 pom.xml 中打开 chroma 的注释,并注释上其它向量库】
chroma:
client: