Package com.tnsai.rag
Class SearchSettings
java.lang.Object
com.tnsai.rag.SearchSettings
The search settings one knowledge entry contributes to its scope: a partial,
immutable value holding only the
Search members that were given.
An entry's settings merge member by member with the other SEARCH entries
of its scope, so a member that is not given here leaves the scope's value,
or the default, in place. Build one with builder() or read one
from a Search declaration with of(Search).
- Since:
- 0.18.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuildsSearchSettings; a member not set is not given. -
Method Summary
Modifier and TypeMethodDescriptionstatic SearchSettings.Builderbuilder()Starts settings that give no member.cache()cacheTTL()booleaninthashCode()layer(SearchSettings over) These settings with every memberovergives replacing the one given here.members()minScore()static SearchSettingsThe members aSearchdeclaration gives.rerank()strategy()topK()topN()toString()
-
Method Details
-
builder
Starts settings that give no member.- Returns:
- a new builder
-
of
The members aSearchdeclaration gives.- Parameters:
search- the declaration- Returns:
- settings holding each member the declaration gives one value for
- Throws:
IllegalArgumentException- when a member holds more than one value
-
members
- Returns:
- the names of the members these settings give, in name order
-
layer
These settings with every memberovergives replacing the one given here.- Parameters:
over- the settings that win- Returns:
- the layered settings
-
strategy
-
queryParam
-
rerank
-
rerankerModel
-
contextWindow
-
topK
-
topN
-
minScore
-
deduplicate
-
dedupeThreshold
-
queryExpansion
-
queryExpansionModel
-
expandedQueries
-
includeSpec
-
contextFormat
-
cache
-
cacheTTL
-
maxStaleness
-
onFailure
-
equals
-
hashCode
public int hashCode() -
toString
-