Skip to content

Commit 67b2bf4

Browse files
Auto-generated code for 8.12 (#2157)
1 parent 03eaf7a commit 67b2bf4

File tree

4 files changed

+24
-5
lines changed

4 files changed

+24
-5
lines changed

docs/reference.asciidoc

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3375,7 +3375,7 @@ client.indices.create({ index })
33753375
* *Request (object):*
33763376
** *`index` (string)*: Name of the index you wish to create.
33773377
** *`aliases` (Optional, Record<string, { filter, index_routing, is_hidden, is_write_index, routing, search_routing }>)*: Aliases for the index.
3378-
** *`mappings` (Optional, { all_field, date_detection, dynamic, dynamic_date_formats, dynamic_templates, _field_names, index_field, _meta, numeric_detection, properties, _routing, _size, _source, runtime, enabled, _data_stream_timestamp })*: Mapping for fields in the index. If specified, this mapping can include:
3378+
** *`mappings` (Optional, { all_field, date_detection, dynamic, dynamic_date_formats, dynamic_templates, _field_names, index_field, _meta, numeric_detection, properties, _routing, _size, _source, runtime, enabled, subobjects, _data_stream_timestamp })*: Mapping for fields in the index. If specified, this mapping can include:
33793379
- Field names
33803380
- Field data types
33813381
- Mapping parameters
@@ -4232,7 +4232,7 @@ a new date field is added instead of string.
42324232
not used at all by Elasticsearch, but can be used to store
42334233
application-specific metadata.
42344234
** *`numeric_detection` (Optional, boolean)*: Automatically map strings into numeric data types for all fields.
4235-
** *`properties` (Optional, Record<string, { type } | { boost, fielddata, index, null_value, type } | { type, enabled, null_value, boost, coerce, script, on_script_error, ignore_malformed, time_series_metric, analyzer, eager_global_ordinals, index, index_options, index_phrases, index_prefixes, norms, position_increment_gap, search_analyzer, search_quote_analyzer, term_vector, format, precision_step, locale } | { relations, eager_global_ordinals, type } | { boost, eager_global_ordinals, index, index_options, normalizer, norms, null_value, split_queries_on_whitespace, time_series_dimension, type } | { type, fields, meta, copy_to } | { type } | { positive_score_impact, type } | { type } | { analyzer, index, index_options, max_shingle_size, norms, search_analyzer, search_quote_analyzer, term_vector, type } | { analyzer, boost, eager_global_ordinals, fielddata, fielddata_frequency_filter, index, index_options, index_phrases, index_prefixes, norms, position_increment_gap, search_analyzer, search_quote_analyzer, term_vector, type } | { type } | { type, null_value } | { boost, format, ignore_malformed, index, null_value, precision_step, type } | { boost, fielddata, format, ignore_malformed, index, null_value, precision_step, locale, type } | { type, default_metric, metrics, time_series_metric } | { type, dims, similarity, index, index_options } | { type } | { boost, depth_limit, doc_values, eager_global_ordinals, index, index_options, null_value, similarity, split_queries_on_whitespace, type } | { enabled, include_in_parent, include_in_root, type } | { enabled, type } | { analyzer, contexts, max_input_length, preserve_position_increments, preserve_separators, search_analyzer, type } | { value, type } | { path, type } | { ignore_malformed, type } | { boost, index, ignore_malformed, null_value, on_script_error, script, time_series_dimension, type } | { type } | { analyzer, boost, index, null_value, enable_position_increments, type } | { ignore_malformed, ignore_z_value, null_value, type } | { coerce, ignore_malformed, ignore_z_value, orientation, strategy, type } | { ignore_malformed, ignore_z_value, null_value, type } | { coerce, ignore_malformed, ignore_z_value, orientation, type } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value, scaling_factor } | { type, null_value } | { type, null_value } | { format, type } | { type } | { type } | { type } | { type } | { type }>)*: Mapping for a field. For new fields, this mapping can include:
4235+
** *`properties` (Optional, Record<string, { type } | { boost, fielddata, index, null_value, type } | { type, enabled, null_value, boost, coerce, script, on_script_error, ignore_malformed, time_series_metric, analyzer, eager_global_ordinals, index, index_options, index_phrases, index_prefixes, norms, position_increment_gap, search_analyzer, search_quote_analyzer, term_vector, format, precision_step, locale } | { relations, eager_global_ordinals, type } | { boost, eager_global_ordinals, index, index_options, normalizer, norms, null_value, split_queries_on_whitespace, time_series_dimension, type } | { type, fields, meta, copy_to } | { type } | { positive_score_impact, type } | { type } | { analyzer, index, index_options, max_shingle_size, norms, search_analyzer, search_quote_analyzer, term_vector, type } | { analyzer, boost, eager_global_ordinals, fielddata, fielddata_frequency_filter, index, index_options, index_phrases, index_prefixes, norms, position_increment_gap, search_analyzer, search_quote_analyzer, term_vector, type } | { type } | { type, null_value } | { boost, format, ignore_malformed, index, null_value, precision_step, type } | { boost, fielddata, format, ignore_malformed, index, null_value, precision_step, locale, type } | { type, default_metric, metrics, time_series_metric } | { type, dims, similarity, index, index_options } | { type } | { boost, depth_limit, doc_values, eager_global_ordinals, index, index_options, null_value, similarity, split_queries_on_whitespace, type } | { enabled, include_in_parent, include_in_root, type } | { enabled, subobjects, type } | { analyzer, contexts, max_input_length, preserve_position_increments, preserve_separators, search_analyzer, type } | { value, type } | { path, type } | { ignore_malformed, type } | { boost, index, ignore_malformed, null_value, on_script_error, script, time_series_dimension, type } | { type } | { analyzer, boost, index, null_value, enable_position_increments, type } | { ignore_malformed, ignore_z_value, null_value, type } | { coerce, ignore_malformed, ignore_z_value, orientation, strategy, type } | { ignore_malformed, ignore_z_value, null_value, type } | { coerce, ignore_malformed, ignore_z_value, orientation, type } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value } | { type, null_value, scaling_factor } | { type, null_value } | { type, null_value } | { format, type } | { type } | { type } | { type } | { type } | { type }>)*: Mapping for a field. For new fields, this mapping can include:
42364236

42374237
- Field name
42384238
- Field data type
@@ -4307,7 +4307,7 @@ client.indices.putTemplate({ name })
43074307
** *`aliases` (Optional, Record<string, { filter, index_routing, is_hidden, is_write_index, routing, search_routing }>)*: Aliases for the index.
43084308
** *`index_patterns` (Optional, string | string[])*: Array of wildcard expressions used to match the names
43094309
of indices during creation.
4310-
** *`mappings` (Optional, { all_field, date_detection, dynamic, dynamic_date_formats, dynamic_templates, _field_names, index_field, _meta, numeric_detection, properties, _routing, _size, _source, runtime, enabled, _data_stream_timestamp })*: Mapping for fields in the index.
4310+
** *`mappings` (Optional, { all_field, date_detection, dynamic, dynamic_date_formats, dynamic_templates, _field_names, index_field, _meta, numeric_detection, properties, _routing, _size, _source, runtime, enabled, subobjects, _data_stream_timestamp })*: Mapping for fields in the index.
43114311
** *`order` (Optional, number)*: Order in which Elasticsearch applies this template if index
43124312
matches multiple templates.
43134313

@@ -4434,7 +4434,7 @@ If specified, Elasticsearch only performs the rollover if the current index sati
44344434
If this parameter is not specified, Elasticsearch performs the rollover unconditionally.
44354435
If conditions are specified, at least one of them must be a `max_*` condition.
44364436
The index will rollover if any `max_*` condition is satisfied and all `min_*` conditions are satisfied.
4437-
** *`mappings` (Optional, { all_field, date_detection, dynamic, dynamic_date_formats, dynamic_templates, _field_names, index_field, _meta, numeric_detection, properties, _routing, _size, _source, runtime, enabled, _data_stream_timestamp })*: Mapping for fields in the index.
4437+
** *`mappings` (Optional, { all_field, date_detection, dynamic, dynamic_date_formats, dynamic_templates, _field_names, index_field, _meta, numeric_detection, properties, _routing, _size, _source, runtime, enabled, subobjects, _data_stream_timestamp })*: Mapping for fields in the index.
44384438
If specified, this mapping can include field names, field data types, and mapping paramaters.
44394439
** *`settings` (Optional, Record<string, User-defined value>)*: Configuration options for the index.
44404440
Data streams do not support this parameter.
@@ -6408,6 +6408,7 @@ so one of, `linux-x86_64`, `linux-aarch64`, `darwin-x86_64`, `darwin-aarch64`,
64086408
or `windows-x86_64`. For portable models (those that work independent of processor
64096409
architecture or OS features), leave this field unset.
64106410
** *`tags` (Optional, string[])*: An array of tags to organize the model.
6411+
** *`prefix_strings` (Optional, { ingest, search })*: Optional prefix strings applied at inference
64116412
** *`defer_definition_decompression` (Optional, boolean)*: If set to `true` and a `compressed_definition` is provided, the request defers definition decompression and skips relevant validations.
64126413

64136414
[discrete]

src/api/api/ml.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1821,7 +1821,7 @@ export default class Ml {
18211821
async putTrainedModel (this: That, params: T.MlPutTrainedModelRequest | TB.MlPutTrainedModelRequest, options?: TransportRequestOptions): Promise<T.MlPutTrainedModelResponse>
18221822
async putTrainedModel (this: That, params: T.MlPutTrainedModelRequest | TB.MlPutTrainedModelRequest, options?: TransportRequestOptions): Promise<any> {
18231823
const acceptedPath: string[] = ['model_id']
1824-
const acceptedBody: string[] = ['compressed_definition', 'definition', 'description', 'inference_config', 'input', 'metadata', 'model_type', 'model_size_bytes', 'platform_architecture', 'tags']
1824+
const acceptedBody: string[] = ['compressed_definition', 'definition', 'description', 'inference_config', 'input', 'metadata', 'model_type', 'model_size_bytes', 'platform_architecture', 'tags', 'prefix_strings']
18251825
const querystring: Record<string, any> = {}
18261826
// @ts-expect-error
18271827
const userBody: any = params?.body

src/api/types.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5083,6 +5083,7 @@ export interface MappingNumberPropertyBase extends MappingDocValuesPropertyBase
50835083

50845084
export interface MappingObjectProperty extends MappingCorePropertyBase {
50855085
enabled?: boolean
5086+
subobjects?: boolean
50865087
type?: 'object'
50875088
}
50885089

@@ -5256,6 +5257,7 @@ export interface MappingTypeMapping {
52565257
_source?: MappingSourceField
52575258
runtime?: Record<string, MappingRuntimeField>
52585259
enabled?: boolean
5260+
subobjects?: boolean
52595261
_data_stream_timestamp?: MappingDataStreamTimestamp
52605262
}
52615263

@@ -13068,6 +13070,7 @@ export interface MlTrainedModelConfig {
1306813070
metadata?: MlTrainedModelConfigMetadata
1306913071
model_size_bytes?: ByteSize
1307013072
location?: MlTrainedModelLocation
13073+
prefix_strings?: MlTrainedModelPrefixStrings
1307113074
}
1307213075

1307313076
export interface MlTrainedModelConfigInput {
@@ -13155,6 +13158,11 @@ export interface MlTrainedModelLocationIndex {
1315513158
name: IndexName
1315613159
}
1315713160

13161+
export interface MlTrainedModelPrefixStrings {
13162+
ingest?: string
13163+
search?: string
13164+
}
13165+
1315813166
export interface MlTrainedModelSizeStats {
1315913167
model_size_bytes: ByteSize
1316013168
required_native_memory_bytes: integer
@@ -14089,6 +14097,7 @@ export interface MlPutTrainedModelRequest extends RequestBase {
1408914097
model_size_bytes?: long
1409014098
platform_architecture?: string
1409114099
tags?: string[]
14100+
prefix_strings?: MlTrainedModelPrefixStrings
1409214101
}
1409314102

1409414103
export type MlPutTrainedModelResponse = MlTrainedModelConfig

src/api/typesWithBodyKey.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5156,6 +5156,7 @@ export interface MappingNumberPropertyBase extends MappingDocValuesPropertyBase
51565156

51575157
export interface MappingObjectProperty extends MappingCorePropertyBase {
51585158
enabled?: boolean
5159+
subobjects?: boolean
51595160
type?: 'object'
51605161
}
51615162

@@ -5329,6 +5330,7 @@ export interface MappingTypeMapping {
53295330
_source?: MappingSourceField
53305331
runtime?: Record<string, MappingRuntimeField>
53315332
enabled?: boolean
5333+
subobjects?: boolean
53325334
_data_stream_timestamp?: MappingDataStreamTimestamp
53335335
}
53345336

@@ -13256,6 +13258,7 @@ export interface MlTrainedModelConfig {
1325613258
metadata?: MlTrainedModelConfigMetadata
1325713259
model_size_bytes?: ByteSize
1325813260
location?: MlTrainedModelLocation
13261+
prefix_strings?: MlTrainedModelPrefixStrings
1325913262
}
1326013263

1326113264
export interface MlTrainedModelConfigInput {
@@ -13343,6 +13346,11 @@ export interface MlTrainedModelLocationIndex {
1334313346
name: IndexName
1334413347
}
1334513348

13349+
export interface MlTrainedModelPrefixStrings {
13350+
ingest?: string
13351+
search?: string
13352+
}
13353+
1334613354
export interface MlTrainedModelSizeStats {
1334713355
model_size_bytes: ByteSize
1334813356
required_native_memory_bytes: integer
@@ -14352,6 +14360,7 @@ export interface MlPutTrainedModelRequest extends RequestBase {
1435214360
model_size_bytes?: long
1435314361
platform_architecture?: string
1435414362
tags?: string[]
14363+
prefix_strings?: MlTrainedModelPrefixStrings
1435514364
}
1435614365
}
1435714366

0 commit comments

Comments
 (0)