Method Rerank
Rerank<TResult>(IAggregateFluent<TResult>, RerankQuery, FieldDefinition<TResult>, int, string)
Appends a $rerank stage.
public static IAggregateFluent<TResult> Rerank<TResult>(this IAggregateFluent<TResult> aggregate, RerankQuery query, FieldDefinition<TResult> path, int numDocsToRerank, string model)
Parameters
aggregateIAggregateFluent<TResult>The aggregate.
queryRerankQueryThe rerank query.
pathFieldDefinition<TResult>The field to send to the reranker.
numDocsToRerankintThe maximum number of documents to rerank.
modelstringThe reranking model name.
Returns
- IAggregateFluent<TResult>
The fluent aggregate interface.
Type Parameters
TResultThe type of the result.
Rerank<TResult, TField>(IAggregateFluent<TResult>, RerankQuery, Expression<Func<TResult, TField>>, int, string)
Appends a $rerank stage.
public static IAggregateFluent<TResult> Rerank<TResult, TField>(this IAggregateFluent<TResult> aggregate, RerankQuery query, Expression<Func<TResult, TField>> path, int numDocsToRerank, string model)
Parameters
aggregateIAggregateFluent<TResult>The aggregate.
queryRerankQueryThe rerank query.
pathExpression<Func<TResult, TField>>The field to send to the reranker.
numDocsToRerankintThe maximum number of documents to rerank.
modelstringThe reranking model name.
Returns
- IAggregateFluent<TResult>
The fluent aggregate interface.
Type Parameters
TResultThe type of the result.
TFieldThe type of the field.
Rerank<TResult>(IAggregateFluent<TResult>, RerankQuery, IEnumerable<FieldDefinition<TResult>>, int, string)
Appends a $rerank stage.
public static IAggregateFluent<TResult> Rerank<TResult>(this IAggregateFluent<TResult> aggregate, RerankQuery query, IEnumerable<FieldDefinition<TResult>> paths, int numDocsToRerank, string model)
Parameters
aggregateIAggregateFluent<TResult>The aggregate.
queryRerankQueryThe rerank query.
pathsIEnumerable<FieldDefinition<TResult>>The fields to send to the reranker.
numDocsToRerankintThe maximum number of documents to rerank.
modelstringThe reranking model name.
Returns
- IAggregateFluent<TResult>
The fluent aggregate interface.
Type Parameters
TResultThe type of the result.