Skip to content

Fix indices_boost type #4147

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 27, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions specification/_global/msearch/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { PointInTimeReference } from '@global/search/_types/PointInTimeReference
import { Rescore } from '@global/search/_types/rescoring'
import { SourceConfig } from '@global/search/_types/SourceFilter'
import { Suggester } from '@global/search/_types/suggester'
import { Dictionary } from '@spec_utils/Dictionary'
import { Dictionary, SingleKeyDictionary } from '@spec_utils/Dictionary'
import { UserDefinedValue } from '@spec_utils/UserDefinedValue'
import { AggregationContainer } from '@_types/aggregations/AggregationContainer'
import { ErrorResponseBase } from '@_types/Base'
Expand Down Expand Up @@ -116,7 +116,7 @@ export class MultisearchBody {
/**
* Boosts the _score of documents from specified indices.
*/
indices_boost?: Array<Dictionary<IndexName, double>>
indices_boost?: Array<SingleKeyDictionary<IndexName, double>>
/**
* Minimum _score for matching documents. Documents with a lower _score are
* not included in the search results.
Expand Down
4 changes: 2 additions & 2 deletions specification/_global/search/SearchRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
*/

import { TrackHits } from '@global/search/_types/hits'
import { Dictionary } from '@spec_utils/Dictionary'
import { Dictionary, SingleKeyDictionary } from '@spec_utils/Dictionary'
import { UserDefinedValue } from '@spec_utils/UserDefinedValue'
import { AggregationContainer } from '@_types/aggregations/AggregationContainer'
import { RequestBase } from '@_types/Base'
Expand Down Expand Up @@ -427,7 +427,7 @@ export interface Request extends RequestBase {
* A boost value between `0` and `1.0` decreases the score.
* @ext_doc_id relevance-scores
*/
indices_boost?: Array<Dictionary<IndexName, double>>
indices_boost?: Array<SingleKeyDictionary<IndexName, double>>
/**
* An array of wildcard (`*`) field patterns.
* The request returns doc values for field names matching these patterns in the `hits.fields` property of the response.
Expand Down
4 changes: 2 additions & 2 deletions specification/async_search/submit/AsyncSearchSubmitRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import {
SourceConfigParam
} from '@global/search/_types/SourceFilter'
import { Suggester } from '@global/search/_types/suggester'
import { Dictionary } from '@spec_utils/Dictionary'
import { Dictionary, SingleKeyDictionary } from '@spec_utils/Dictionary'
import { UserDefinedValue } from '@spec_utils/UserDefinedValue'
import { AggregationContainer } from '@_types/aggregations/AggregationContainer'
import { RequestBase } from '@_types/Base'
Expand Down Expand Up @@ -189,7 +189,7 @@ export interface Request extends RequestBase {
/**
* Boosts the _score of documents from specified indices.
*/
indices_boost?: Array<Dictionary<IndexName, double>>
indices_boost?: Array<SingleKeyDictionary<IndexName, double>>
/**
* Array of wildcard (*) patterns. The request returns doc values for field
* names matching these patterns in the hits.fields property of the response.
Expand Down
4 changes: 2 additions & 2 deletions specification/fleet/search/SearchRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import {
SourceConfigParam
} from '@global/search/_types/SourceFilter'
import { Suggester } from '@global/search/_types/suggester'
import { Dictionary } from '@spec_utils/Dictionary'
import { Dictionary, SingleKeyDictionary } from '@spec_utils/Dictionary'
import { UserDefinedValue } from '@spec_utils/UserDefinedValue'
import { AggregationContainer } from '@_types/aggregations/AggregationContainer'
import { RequestBase } from '@_types/Base'
Expand Down Expand Up @@ -167,7 +167,7 @@ export interface Request extends RequestBase {
/**
* Boosts the _score of documents from specified indices.
*/
indices_boost?: Array<Dictionary<IndexName, double>>
indices_boost?: Array<SingleKeyDictionary<IndexName, double>>
/**
* Array of wildcard (*) patterns. The request returns doc values for field
* names matching these patterns in the hits.fields property of the response.
Expand Down