searchHybridWithContext method
Future<RagSearchResult>
searchHybridWithContext(
- String query, {
- int topK = 10,
- int tokenBudget = 2000,
- ContextStrategy strategy = ContextStrategy.relevanceFirst,
- int adjacentChunks = 0,
- double vectorWeight = kDefaultVectorWeight,
- double bm25Weight = kDefaultBm25Weight,
- bool singleSourceMode = false,
- List<
int> ? sourceIds, - SearchHydrationMode hydrationMode = SearchHydrationMode.full,
- int previewMaxBytes = 512,
Implementation
Future<RagSearchResult> searchHybridWithContext(
String query, {
int topK = 10,
int tokenBudget = 2000,
ContextStrategy strategy = ContextStrategy.relevanceFirst,
int adjacentChunks = 0,
double vectorWeight = kDefaultVectorWeight,
double bm25Weight = kDefaultBm25Weight,
bool singleSourceMode = false,
List<int>? sourceIds,
SearchHydrationMode hydrationMode = SearchHydrationMode.full,
int previewMaxBytes = 512,
}) =>
_engine.searchHybridWithContext(
query,
topK: topK,
tokenBudget: tokenBudget,
strategy: strategy,
adjacentChunks: adjacentChunks,
vectorWeight: vectorWeight,
bm25Weight: bm25Weight,
singleSourceMode: singleSourceMode,
sourceIds: sourceIds,
hydrationMode: hydrationMode,
previewMaxBytes: previewMaxBytes,
collectionId: _collectionId,
);