Skip to content

Commit eb761fa

Browse files
Auto-generated API code
1 parent 48b012e commit eb761fa

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

elasticsearch/_async/client/ml.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3303,6 +3303,7 @@ async def put_trained_model_vocabulary(
33033303
human: t.Optional[bool] = None,
33043304
merges: t.Optional[t.Sequence[str]] = None,
33053305
pretty: t.Optional[bool] = None,
3306+
scores: t.Optional[t.Sequence[float]] = None,
33063307
) -> ObjectApiResponse[t.Any]:
33073308
"""
33083309
Creates a trained model vocabulary
@@ -3312,6 +3313,7 @@ async def put_trained_model_vocabulary(
33123313
:param model_id: The unique identifier of the trained model.
33133314
:param vocabulary: The model vocabulary, which must not be empty.
33143315
:param merges: The optional model merges if required by the tokenizer.
3316+
:param scores: The optional vocabulary value scores if required by the tokenizer.
33153317
"""
33163318
if model_id in SKIP_IN_PATH:
33173319
raise ValueError("Empty value passed for parameter 'model_id'")
@@ -3332,6 +3334,8 @@ async def put_trained_model_vocabulary(
33323334
__body["merges"] = merges
33333335
if pretty is not None:
33343336
__query["pretty"] = pretty
3337+
if scores is not None:
3338+
__body["scores"] = scores
33353339
__headers = {"accept": "application/json", "content-type": "application/json"}
33363340
return await self.perform_request( # type: ignore[return-value]
33373341
"PUT", __path, params=__query, headers=__headers, body=__body

elasticsearch/_sync/client/ml.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3303,6 +3303,7 @@ def put_trained_model_vocabulary(
33033303
human: t.Optional[bool] = None,
33043304
merges: t.Optional[t.Sequence[str]] = None,
33053305
pretty: t.Optional[bool] = None,
3306+
scores: t.Optional[t.Sequence[float]] = None,
33063307
) -> ObjectApiResponse[t.Any]:
33073308
"""
33083309
Creates a trained model vocabulary
@@ -3312,6 +3313,7 @@ def put_trained_model_vocabulary(
33123313
:param model_id: The unique identifier of the trained model.
33133314
:param vocabulary: The model vocabulary, which must not be empty.
33143315
:param merges: The optional model merges if required by the tokenizer.
3316+
:param scores: The optional vocabulary value scores if required by the tokenizer.
33153317
"""
33163318
if model_id in SKIP_IN_PATH:
33173319
raise ValueError("Empty value passed for parameter 'model_id'")
@@ -3332,6 +3334,8 @@ def put_trained_model_vocabulary(
33323334
__body["merges"] = merges
33333335
if pretty is not None:
33343336
__query["pretty"] = pretty
3337+
if scores is not None:
3338+
__body["scores"] = scores
33353339
__headers = {"accept": "application/json", "content-type": "application/json"}
33363340
return self.perform_request( # type: ignore[return-value]
33373341
"PUT", __path, params=__query, headers=__headers, body=__body

0 commit comments

Comments
 (0)