类 RetrieveConfig
java.lang.Object
io.agentscope.core.rag.model.RetrieveConfig
Configuration for document retrieval operations.
This class uses the builder pattern to configure retrieval parameters such as the maximum number of results, the minimum similarity score threshold, and optional conversation history for context-aware retrieval.
-
嵌套类概要
嵌套类 -
方法概要
修饰符和类型方法说明static RetrieveConfig.Builderbuilder()Creates a new builder instance.Gets the conversation history for context-aware retrieval.intgetLimit()Gets the maximum number of documents to retrieve.doubleGets the minimum similarity score threshold.Gets the vector name for retrieval.mutate()Mutate the current instance to a new builder.
-
方法详细资料
-
getLimit
public int getLimit()Gets the maximum number of documents to retrieve.- 返回:
- the limit
-
getScoreThreshold
public double getScoreThreshold()Gets the minimum similarity score threshold.- 返回:
- the score threshold
-
getVectorName
Gets the vector name for retrieval.- 返回:
- the vector name, or null if not set
-
getConversationHistory
Gets the conversation history for context-aware retrieval.This is an optional field used by knowledge bases that support multi-turn conversation context (e.g., Bailian Knowledge Base with query rewriting).
- 返回:
- the conversation history, or null if not set
-
mutate
Mutate the current instance to a new builder.- 返回:
- a new builder with the same values of this instance
-
builder
Creates a new builder instance.- 返回:
- a new builder
-