mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-14 05:43:51 +00:00
(improvement)(chat) Fix the collectionName issue in the memory agent level. (#1300)
This commit is contained in:
@@ -7,6 +7,10 @@ import org.springframework.context.annotation.Configuration;
|
||||
@Configuration
|
||||
@Data
|
||||
public class EmbeddingConfig {
|
||||
|
||||
@Value("${s2.embedding.memory.collection.prefix:memory_}")
|
||||
private String memoryCollectionPrefix;
|
||||
|
||||
@Value("${s2.embedding.preset.collection:preset_query_collection}")
|
||||
private String presetCollection;
|
||||
|
||||
@@ -25,4 +29,8 @@ public class EmbeddingConfig {
|
||||
@Value("${s2.embedding.metric.analyzeQuery.nResult:5}")
|
||||
private int metricAnalyzeQueryResultNum;
|
||||
|
||||
public String getMemoryCollectionName(Integer agentId) {
|
||||
return memoryCollectionPrefix + agentId;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user