elasticsearch 8.13.1__py3-none-any.whl → 8.13.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5043,6 +5043,62 @@ class MlClient(NamespacedClient):
5043
5043
  path_parts=__path_parts,
5044
5044
  )
5045
5045
 
5046
+ @_rewrite_parameters(
5047
+ body_fields=("number_of_allocations",),
5048
+ )
5049
+ async def update_trained_model_deployment(
5050
+ self,
5051
+ *,
5052
+ model_id: str,
5053
+ error_trace: t.Optional[bool] = None,
5054
+ filter_path: t.Optional[t.Union[str, t.Sequence[str]]] = None,
5055
+ human: t.Optional[bool] = None,
5056
+ number_of_allocations: t.Optional[int] = None,
5057
+ pretty: t.Optional[bool] = None,
5058
+ body: t.Optional[t.Dict[str, t.Any]] = None,
5059
+ ) -> ObjectApiResponse[t.Any]:
5060
+ """
5061
+ Updates certain properties of trained model deployment.
5062
+
5063
+ `<https://www.elastic.co/guide/en/elasticsearch/reference/8.13/update-trained-model-deployment.html>`_
5064
+
5065
+ :param model_id: The unique identifier of the trained model. Currently, only
5066
+ PyTorch models are supported.
5067
+ :param number_of_allocations: The number of model allocations on each node where
5068
+ the model is deployed. All allocations on a node share the same copy of the
5069
+ model in memory but use a separate set of threads to evaluate the model.
5070
+ Increasing this value generally increases the throughput. If this setting
5071
+ is greater than the number of hardware threads it will automatically be changed
5072
+ to a value less than the number of hardware threads.
5073
+ """
5074
+ if model_id in SKIP_IN_PATH:
5075
+ raise ValueError("Empty value passed for parameter 'model_id'")
5076
+ __path_parts: t.Dict[str, str] = {"model_id": _quote(model_id)}
5077
+ __path = f'/_ml/trained_models/{__path_parts["model_id"]}/deployment/_update'
5078
+ __query: t.Dict[str, t.Any] = {}
5079
+ __body: t.Dict[str, t.Any] = body if body is not None else {}
5080
+ if error_trace is not None:
5081
+ __query["error_trace"] = error_trace
5082
+ if filter_path is not None:
5083
+ __query["filter_path"] = filter_path
5084
+ if human is not None:
5085
+ __query["human"] = human
5086
+ if pretty is not None:
5087
+ __query["pretty"] = pretty
5088
+ if not __body:
5089
+ if number_of_allocations is not None:
5090
+ __body["number_of_allocations"] = number_of_allocations
5091
+ __headers = {"accept": "application/json", "content-type": "application/json"}
5092
+ return await self.perform_request( # type: ignore[return-value]
5093
+ "POST",
5094
+ __path,
5095
+ params=__query,
5096
+ headers=__headers,
5097
+ body=__body,
5098
+ endpoint_id="ml.update_trained_model_deployment",
5099
+ path_parts=__path_parts,
5100
+ )
5101
+
5046
5102
  @_rewrite_parameters()
5047
5103
  async def upgrade_job_snapshot(
5048
5104
  self,
@@ -5043,6 +5043,62 @@ class MlClient(NamespacedClient):
5043
5043
  path_parts=__path_parts,
5044
5044
  )
5045
5045
 
5046
+ @_rewrite_parameters(
5047
+ body_fields=("number_of_allocations",),
5048
+ )
5049
+ def update_trained_model_deployment(
5050
+ self,
5051
+ *,
5052
+ model_id: str,
5053
+ error_trace: t.Optional[bool] = None,
5054
+ filter_path: t.Optional[t.Union[str, t.Sequence[str]]] = None,
5055
+ human: t.Optional[bool] = None,
5056
+ number_of_allocations: t.Optional[int] = None,
5057
+ pretty: t.Optional[bool] = None,
5058
+ body: t.Optional[t.Dict[str, t.Any]] = None,
5059
+ ) -> ObjectApiResponse[t.Any]:
5060
+ """
5061
+ Updates certain properties of trained model deployment.
5062
+
5063
+ `<https://www.elastic.co/guide/en/elasticsearch/reference/8.13/update-trained-model-deployment.html>`_
5064
+
5065
+ :param model_id: The unique identifier of the trained model. Currently, only
5066
+ PyTorch models are supported.
5067
+ :param number_of_allocations: The number of model allocations on each node where
5068
+ the model is deployed. All allocations on a node share the same copy of the
5069
+ model in memory but use a separate set of threads to evaluate the model.
5070
+ Increasing this value generally increases the throughput. If this setting
5071
+ is greater than the number of hardware threads it will automatically be changed
5072
+ to a value less than the number of hardware threads.
5073
+ """
5074
+ if model_id in SKIP_IN_PATH:
5075
+ raise ValueError("Empty value passed for parameter 'model_id'")
5076
+ __path_parts: t.Dict[str, str] = {"model_id": _quote(model_id)}
5077
+ __path = f'/_ml/trained_models/{__path_parts["model_id"]}/deployment/_update'
5078
+ __query: t.Dict[str, t.Any] = {}
5079
+ __body: t.Dict[str, t.Any] = body if body is not None else {}
5080
+ if error_trace is not None:
5081
+ __query["error_trace"] = error_trace
5082
+ if filter_path is not None:
5083
+ __query["filter_path"] = filter_path
5084
+ if human is not None:
5085
+ __query["human"] = human
5086
+ if pretty is not None:
5087
+ __query["pretty"] = pretty
5088
+ if not __body:
5089
+ if number_of_allocations is not None:
5090
+ __body["number_of_allocations"] = number_of_allocations
5091
+ __headers = {"accept": "application/json", "content-type": "application/json"}
5092
+ return self.perform_request( # type: ignore[return-value]
5093
+ "POST",
5094
+ __path,
5095
+ params=__query,
5096
+ headers=__headers,
5097
+ body=__body,
5098
+ endpoint_id="ml.update_trained_model_deployment",
5099
+ path_parts=__path_parts,
5100
+ )
5101
+
5046
5102
  @_rewrite_parameters()
5047
5103
  def upgrade_job_snapshot(
5048
5104
  self,
elasticsearch/_version.py CHANGED
@@ -15,4 +15,4 @@
15
15
  # specific language governing permissions and limitations
16
16
  # under the License.
17
17
 
18
- __versionstr__ = "8.13.1"
18
+ __versionstr__ = "8.13.2"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: elasticsearch
3
- Version: 8.13.1
3
+ Version: 8.13.2
4
4
  Summary: Python client for Elasticsearch
5
5
  Home-page: https://github.com/elastic/elasticsearch-py
6
6
  Author: Elastic Client Library Maintainers
@@ -33,7 +33,7 @@ Requires-Dist: aiohttp <4,>=3 ; extra == 'async'
33
33
  Provides-Extra: orjson
34
34
  Requires-Dist: orjson >=3 ; extra == 'orjson'
35
35
  Provides-Extra: requests
36
- Requires-Dist: requests <3.0.0,>=2.4.0 ; extra == 'requests'
36
+ Requires-Dist: requests !=2.32.2,<3.0.0,>=2.4.0 ; extra == 'requests'
37
37
  Provides-Extra: vectorstore_mmr
38
38
  Requires-Dist: numpy >=1 ; extra == 'vectorstore_mmr'
39
39
  Requires-Dist: simsimd >=3 ; extra == 'vectorstore_mmr'
@@ -1,7 +1,7 @@
1
1
  elasticsearch/__init__.py,sha256=w5YnO16zjOi6loGJ8caUgSXsj3b-Y8OfF0BIddP2BiE,3289
2
2
  elasticsearch/_otel.py,sha256=9nMvDwSz_BephEQmkETCmEdA_6YNtj_CJQyxIwOzEGo,3406
3
3
  elasticsearch/_utils.py,sha256=Vr_aNG5ddxInE1PgDpCXMYpXBTNUFM9nYrgbw-cjeCc,1419
4
- elasticsearch/_version.py,sha256=DXfrNbuYRJqhJULnvIrY294V7ZIHYCd3oa4diFaiFbk,814
4
+ elasticsearch/_version.py,sha256=0P-o-HdbMQa0vGhTZYE8ZkuZ9v7zXoV3M6M0wUoqfrs,814
5
5
  elasticsearch/client.py,sha256=p4naAgAPs_B9laux-aC-bpZNvbu9fvrpicBvLRlp_yw,5120
6
6
  elasticsearch/compat.py,sha256=hL3mtqVxWwxeiFbNGADva5XruAwK-A6xcu-vrpnDXFs,2657
7
7
  elasticsearch/exceptions.py,sha256=HHqidMTlLXRcNbo4gjsbhHsLfiV4JGg7tx1lXQndG98,4025
@@ -31,7 +31,7 @@ elasticsearch/_async/client/ingest.py,sha256=5V8fur9z4Vkv4p-3geOfc1ek5N8qJ6CvWbd
31
31
  elasticsearch/_async/client/license.py,sha256=kuqW-yfOVdsDHh5puu7_tD_LN7JU0Axt0AtE5ttx8jc,12100
32
32
  elasticsearch/_async/client/logstash.py,sha256=JrvbrTi9sCO-GzOe3lBWcaIOPkYFqzenCkYw_B6JW7Q,6127
33
33
  elasticsearch/_async/client/migration.py,sha256=It0NTjXaN-UW8keaNURglL4rYbOmAvTbHD7QlFBOJg4,5331
34
- elasticsearch/_async/client/ml.py,sha256=fklo9AmgLQjtzvjXy5PgVBL9vQgdA_z-N3DM5tMJRA8,238505
34
+ elasticsearch/_async/client/ml.py,sha256=tckls24jxPSOb_OA3f6plc0DDLfKhwddhpAoVfyr0gU,241082
35
35
  elasticsearch/_async/client/monitoring.py,sha256=ZQSiQ8AXfu_8_--cHOpfhjpsQkQZekmBlPiOLAYotpw,3822
36
36
  elasticsearch/_async/client/nodes.py,sha256=xmLfm0cPsQSjH_WKyzGKHI6IhgT9gKhj3XrsJdTXL5w,23723
37
37
  elasticsearch/_async/client/query_ruleset.py,sha256=vBgpKRYL0X7giU05Vw6-pXre10W81zGoALWL_XAnkRM,7606
@@ -73,7 +73,7 @@ elasticsearch/_sync/client/ingest.py,sha256=UY-x1MXjnD2LkbX8O2qa5Ag6eD4lzf4LeZO8
73
73
  elasticsearch/_sync/client/license.py,sha256=tEc366OvzPh9OFbgCMAo8dyw7wjajIcNQyfAX-uin3I,12016
74
74
  elasticsearch/_sync/client/logstash.py,sha256=2Mpd3y-wNR3H7wsFW2riiB6bbobctNoMW22VOvDbN2s,6091
75
75
  elasticsearch/_sync/client/migration.py,sha256=dJ27K1SLcJn4XyBvyPFVocjxHtsAyf2vuOQl52uxK64,5295
76
- elasticsearch/_sync/client/ml.py,sha256=inanWjUHJK25cEjpo_bZ0bdbw8tZGgmCkqmK-Z7P3AE,237641
76
+ elasticsearch/_sync/client/ml.py,sha256=7YgW9g5MQ4KUhI05X_mp7zDHwmRhDAXc0UahK_7qmwM,240206
77
77
  elasticsearch/_sync/client/monitoring.py,sha256=Wh2RTfFOOm5ssbdGv0_gSDS2og1L8ATJamLuUuNrBYU,3810
78
78
  elasticsearch/_sync/client/nodes.py,sha256=YloTg5V90lyGeoY_XU_2X2aeLHOpPss1g7Kp0hR2EF4,23639
79
79
  elasticsearch/_sync/client/query_ruleset.py,sha256=dRzaVZVYLtlRi6PJVGQTPXCKCJuuf6fkU6wug-zmmXs,7558
@@ -108,9 +108,9 @@ elasticsearch/helpers/vectorstore/_sync/_utils.py,sha256=5pdvNS5XC3wqShjliW9Njl9
108
108
  elasticsearch/helpers/vectorstore/_sync/embedding_service.py,sha256=sAw_WKUcmyqOOJRqnNesZCzn7ZyA91v4NvvQszHIWJ8,3582
109
109
  elasticsearch/helpers/vectorstore/_sync/strategies.py,sha256=0Q1zoOrO51S6HXjXwkAePPVtCUGQz5lKN9NyRCso-GU,15220
110
110
  elasticsearch/helpers/vectorstore/_sync/vectorstore.py,sha256=MqTDeHyG4NS9gInxwljh4J0QVvS499SajQ22fe1UpLs,14970
111
- elasticsearch-8.13.1.dist-info/LICENSE,sha256=XfKg2H1sVi8OoRxoisUlMqoo10TKvHmU_wU39ks7MyA,10143
112
- elasticsearch-8.13.1.dist-info/METADATA,sha256=duPLn_1q7QvVNyqQp65ChUjtccEl_NHYT8gyA_Q-CqQ,6455
113
- elasticsearch-8.13.1.dist-info/NOTICE,sha256=t4IjKAJ_G-0hYaL4AH16CVS_xDel8UXrJVK6x7JDaGA,61
114
- elasticsearch-8.13.1.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
115
- elasticsearch-8.13.1.dist-info/top_level.txt,sha256=Jp2bLWq49skvCN4YCZsg1Hfn_NDLgleC-x-Bn01_HgM,14
116
- elasticsearch-8.13.1.dist-info/RECORD,,
111
+ elasticsearch-8.13.2.dist-info/LICENSE,sha256=XfKg2H1sVi8OoRxoisUlMqoo10TKvHmU_wU39ks7MyA,10143
112
+ elasticsearch-8.13.2.dist-info/METADATA,sha256=Eex24ZRMP8r810PL3irLjbwO0c_KeWgszymGV2Q6k8M,6464
113
+ elasticsearch-8.13.2.dist-info/NOTICE,sha256=t4IjKAJ_G-0hYaL4AH16CVS_xDel8UXrJVK6x7JDaGA,61
114
+ elasticsearch-8.13.2.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
115
+ elasticsearch-8.13.2.dist-info/top_level.txt,sha256=Jp2bLWq49skvCN4YCZsg1Hfn_NDLgleC-x-Bn01_HgM,14
116
+ elasticsearch-8.13.2.dist-info/RECORD,,