Language

InferenceClient.SemanticRerankAsync Method

Definition

Overloads

Name Description
SemanticRerankAsync(RequestContent, RequestContext)

[Protocol Method] Reranks documents by their relevance to a query.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
SemanticRerankAsync(SemanticRerankingInferenceContent, CancellationToken)

Reranks documents by their relevance to a query.

SemanticRerankAsync(RequestContent, RequestContext)

Source:
InferenceClient.cs

[Protocol Method] Reranks documents by their relevance to a query.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual System.Threading.Tasks.Task<Azure.Response> SemanticRerankAsync(Azure.Core.RequestContent content, Azure.RequestContext context = default);
abstract member SemanticRerankAsync : Azure.Core.RequestContent * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
override this.SemanticRerankAsync : Azure.Core.RequestContent * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function SemanticRerankAsync (content As RequestContent, Optional context As RequestContext = Nothing) As Task(Of Response)

Parameters

content
RequestContent

The content to send as the body of the request.

context
RequestContext

The request options, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The response returned from the service.

Exceptions

content is null.

Service returned a non-success status code.

Applies to

SemanticRerankAsync(SemanticRerankingInferenceContent, CancellationToken)

Source:
InferenceClient.cs

Reranks documents by their relevance to a query.

public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Data.AI.SemanticRerankingInferenceResult>> SemanticRerankAsync(Azure.Data.AI.SemanticRerankingInferenceContent request, System.Threading.CancellationToken cancellationToken = default);
abstract member SemanticRerankAsync : Azure.Data.AI.SemanticRerankingInferenceContent * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Data.AI.SemanticRerankingInferenceResult>>
override this.SemanticRerankAsync : Azure.Data.AI.SemanticRerankingInferenceContent * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Data.AI.SemanticRerankingInferenceResult>>
Public Overridable Function SemanticRerankAsync (request As SemanticRerankingInferenceContent, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of SemanticRerankingInferenceResult))

Parameters

request
SemanticRerankingInferenceContent

The semantic reranking request.

cancellationToken
CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Exceptions

request is null.

Service returned a non-success status code.

Applies to