SemanticSearchOptions interface

Defines options for semantic search queries

Properties

answers

If set, the query returns answers extracted from key passages in the highest ranked documents.

captions

If set, the query returns captions extracted from key passages in the highest ranked documents. When Captions is set to 'extractive', highlighting is enabled by default. Defaults to 'None'.

configurationName

The name of a semantic configuration that will be used when processing documents for queries of type semantic.

errorMode

Allows the user to choose whether a semantic call should fail completely, or to return partial results (default).

maxWaitInMilliseconds

Allows the user to set an upper bound on the amount of time it takes for semantic enrichment to finish processing before the request fails.

semanticQuery

Allows setting a separate search query that will be solely used for semantic reranking, semantic captions and semantic answers. Is useful for scenarios where there is a need to use different queries between the base retrieval and ranking phase, and the L2 semantic phase.

Property Details

answers

If set, the query returns answers extracted from key passages in the highest ranked documents.

answers?: ExtractiveQueryAnswer

Property Value

captions

If set, the query returns captions extracted from key passages in the highest ranked documents. When Captions is set to 'extractive', highlighting is enabled by default. Defaults to 'None'.

captions?: ExtractiveQueryCaption

Property Value

configurationName

The name of a semantic configuration that will be used when processing documents for queries of type semantic.

configurationName?: string

Property Value

string

errorMode

Allows the user to choose whether a semantic call should fail completely, or to return partial results (default).

errorMode?: "partial" | "fail"

Property Value

"partial" | "fail"

maxWaitInMilliseconds

Allows the user to set an upper bound on the amount of time it takes for semantic enrichment to finish processing before the request fails.

maxWaitInMilliseconds?: number

Property Value

number

semanticQuery

Allows setting a separate search query that will be solely used for semantic reranking, semantic captions and semantic answers. Is useful for scenarios where there is a need to use different queries between the base retrieval and ranking phase, and the L2 semantic phase.

semanticQuery?: string

Property Value

string