truefoundry 0.3.3__py3-none-any.whl → 0.4.0.dev0__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.

Potentially problematic release.


This version of truefoundry might be problematic. Click here for more details.

Files changed (224) hide show
  1. truefoundry/cli/__main__.py +3 -17
  2. truefoundry/common/__init__.py +0 -0
  3. truefoundry/common/request_utils.py +56 -0
  4. truefoundry/deploy/cli/cli.py +1 -1
  5. truefoundry/deploy/lib/auth/credential_provider.py +2 -12
  6. truefoundry/deploy/lib/clients/servicefoundry_client.py +0 -9
  7. truefoundry/deploy/lib/exceptions.py +1 -6
  8. truefoundry/deploy/lib/session.py +1 -16
  9. truefoundry/langchain/truefoundry_chat.py +1 -1
  10. truefoundry/langchain/truefoundry_embeddings.py +1 -1
  11. truefoundry/langchain/truefoundry_llm.py +1 -1
  12. truefoundry/langchain/utils.py +0 -41
  13. truefoundry/ml/__init__.py +46 -6
  14. truefoundry/ml/artifact/__init__.py +0 -0
  15. truefoundry/ml/artifact/truefoundry_artifact_repo.py +1120 -0
  16. truefoundry/ml/autogen/__init__.py +0 -0
  17. truefoundry/ml/autogen/client/__init__.py +373 -0
  18. truefoundry/ml/autogen/client/api/__init__.py +16 -0
  19. truefoundry/ml/autogen/client/api/auth_api.py +184 -0
  20. truefoundry/ml/autogen/client/api/deprecated_api.py +605 -0
  21. truefoundry/ml/autogen/client/api/experiments_api.py +2109 -0
  22. truefoundry/ml/autogen/client/api/health_api.py +299 -0
  23. truefoundry/ml/autogen/client/api/metrics_api.py +371 -0
  24. truefoundry/ml/autogen/client/api/mlfoundry_artifacts_api.py +7213 -0
  25. truefoundry/ml/autogen/client/api/python_deployment_config_api.py +201 -0
  26. truefoundry/ml/autogen/client/api/run_artifacts_api.py +231 -0
  27. truefoundry/ml/autogen/client/api/runs_api.py +2919 -0
  28. truefoundry/ml/autogen/client/api_client.py +822 -0
  29. truefoundry/ml/autogen/client/api_response.py +30 -0
  30. truefoundry/ml/autogen/client/configuration.py +489 -0
  31. truefoundry/ml/autogen/client/exceptions.py +161 -0
  32. truefoundry/ml/autogen/client/models/__init__.py +344 -0
  33. truefoundry/ml/autogen/client/models/add_custom_metrics_to_model_version_request_dto.py +69 -0
  34. truefoundry/ml/autogen/client/models/add_features_to_model_version_request_dto.py +83 -0
  35. truefoundry/ml/autogen/client/models/agent.py +125 -0
  36. truefoundry/ml/autogen/client/models/agent_app.py +118 -0
  37. truefoundry/ml/autogen/client/models/agent_open_api_tool.py +143 -0
  38. truefoundry/ml/autogen/client/models/agent_open_api_tool_with_fqn.py +144 -0
  39. truefoundry/ml/autogen/client/models/agent_with_fqn.py +127 -0
  40. truefoundry/ml/autogen/client/models/artifact_dto.py +115 -0
  41. truefoundry/ml/autogen/client/models/artifact_response_dto.py +75 -0
  42. truefoundry/ml/autogen/client/models/artifact_type.py +39 -0
  43. truefoundry/ml/autogen/client/models/artifact_version_dto.py +141 -0
  44. truefoundry/ml/autogen/client/models/artifact_version_response_dto.py +77 -0
  45. truefoundry/ml/autogen/client/models/artifact_version_status.py +35 -0
  46. truefoundry/ml/autogen/client/models/assistant_message.py +89 -0
  47. truefoundry/ml/autogen/client/models/authorize_user_for_model_request_dto.py +69 -0
  48. truefoundry/ml/autogen/client/models/authorize_user_for_model_version_request_dto.py +69 -0
  49. truefoundry/ml/autogen/client/models/backfill_default_storage_integration_id_request_dto.py +67 -0
  50. truefoundry/ml/autogen/client/models/blob_storage_reference.py +93 -0
  51. truefoundry/ml/autogen/client/models/body_get_search_runs_get.py +72 -0
  52. truefoundry/ml/autogen/client/models/chat_prompt.py +156 -0
  53. truefoundry/ml/autogen/client/models/chat_prompt_messages_inner.py +171 -0
  54. truefoundry/ml/autogen/client/models/columns_dto.py +73 -0
  55. truefoundry/ml/autogen/client/models/content.py +153 -0
  56. truefoundry/ml/autogen/client/models/content1.py +153 -0
  57. truefoundry/ml/autogen/client/models/content2.py +174 -0
  58. truefoundry/ml/autogen/client/models/content2_any_of_inner.py +150 -0
  59. truefoundry/ml/autogen/client/models/create_artifact_request_dto.py +74 -0
  60. truefoundry/ml/autogen/client/models/create_artifact_response_dto.py +66 -0
  61. truefoundry/ml/autogen/client/models/create_artifact_version_request_dto.py +74 -0
  62. truefoundry/ml/autogen/client/models/create_artifact_version_response_dto.py +66 -0
  63. truefoundry/ml/autogen/client/models/create_dataset_request_dto.py +76 -0
  64. truefoundry/ml/autogen/client/models/create_experiment_request_dto.py +94 -0
  65. truefoundry/ml/autogen/client/models/create_experiment_response_dto.py +67 -0
  66. truefoundry/ml/autogen/client/models/create_model_version_request_dto.py +95 -0
  67. truefoundry/ml/autogen/client/models/create_multi_part_upload_for_dataset_request_dto.py +73 -0
  68. truefoundry/ml/autogen/client/models/create_multi_part_upload_for_dataset_response_dto.py +79 -0
  69. truefoundry/ml/autogen/client/models/create_multi_part_upload_request_dto.py +73 -0
  70. truefoundry/ml/autogen/client/models/create_python_deployment_config_request_dto.py +72 -0
  71. truefoundry/ml/autogen/client/models/create_python_deployment_config_response_dto.py +68 -0
  72. truefoundry/ml/autogen/client/models/create_run_request_dto.py +97 -0
  73. truefoundry/ml/autogen/client/models/create_run_response_dto.py +76 -0
  74. truefoundry/ml/autogen/client/models/dataset_dto.py +112 -0
  75. truefoundry/ml/autogen/client/models/dataset_response_dto.py +75 -0
  76. truefoundry/ml/autogen/client/models/delete_artifact_versions_request_dto.py +65 -0
  77. truefoundry/ml/autogen/client/models/delete_dataset_request_dto.py +74 -0
  78. truefoundry/ml/autogen/client/models/delete_model_version_request_dto.py +65 -0
  79. truefoundry/ml/autogen/client/models/delete_run_request.py +65 -0
  80. truefoundry/ml/autogen/client/models/delete_tag_request_dto.py +68 -0
  81. truefoundry/ml/autogen/client/models/experiment_dto.py +127 -0
  82. truefoundry/ml/autogen/client/models/experiment_id_request_dto.py +67 -0
  83. truefoundry/ml/autogen/client/models/experiment_response_dto.py +75 -0
  84. truefoundry/ml/autogen/client/models/experiment_tag_dto.py +69 -0
  85. truefoundry/ml/autogen/client/models/feature_dto.py +68 -0
  86. truefoundry/ml/autogen/client/models/feature_value_type.py +35 -0
  87. truefoundry/ml/autogen/client/models/file_info_dto.py +76 -0
  88. truefoundry/ml/autogen/client/models/finalize_artifact_version_request_dto.py +101 -0
  89. truefoundry/ml/autogen/client/models/get_experiment_response_dto.py +88 -0
  90. truefoundry/ml/autogen/client/models/get_latest_run_log_response_dto.py +76 -0
  91. truefoundry/ml/autogen/client/models/get_metric_history_response.py +79 -0
  92. truefoundry/ml/autogen/client/models/get_signed_url_for_dataset_write_request_dto.py +68 -0
  93. truefoundry/ml/autogen/client/models/get_signed_urls_for_artifact_version_read_request_dto.py +68 -0
  94. truefoundry/ml/autogen/client/models/get_signed_urls_for_artifact_version_read_response_dto.py +81 -0
  95. truefoundry/ml/autogen/client/models/get_signed_urls_for_artifact_version_write_request_dto.py +69 -0
  96. truefoundry/ml/autogen/client/models/get_signed_urls_for_artifact_version_write_response_dto.py +83 -0
  97. truefoundry/ml/autogen/client/models/get_signed_urls_for_dataset_read_request_dto.py +68 -0
  98. truefoundry/ml/autogen/client/models/get_signed_urls_for_dataset_read_response_dto.py +81 -0
  99. truefoundry/ml/autogen/client/models/get_signed_urls_for_dataset_write_response_dto.py +81 -0
  100. truefoundry/ml/autogen/client/models/get_tenant_id_response_dto.py +74 -0
  101. truefoundry/ml/autogen/client/models/http_validation_error.py +82 -0
  102. truefoundry/ml/autogen/client/models/image_content_part.py +87 -0
  103. truefoundry/ml/autogen/client/models/image_url.py +75 -0
  104. truefoundry/ml/autogen/client/models/internal_metadata.py +180 -0
  105. truefoundry/ml/autogen/client/models/latest_run_log_dto.py +78 -0
  106. truefoundry/ml/autogen/client/models/list_artifact_versions_request_dto.py +107 -0
  107. truefoundry/ml/autogen/client/models/list_artifact_versions_response_dto.py +87 -0
  108. truefoundry/ml/autogen/client/models/list_artifacts_request_dto.py +96 -0
  109. truefoundry/ml/autogen/client/models/list_artifacts_response_dto.py +86 -0
  110. truefoundry/ml/autogen/client/models/list_colums_response_dto.py +75 -0
  111. truefoundry/ml/autogen/client/models/list_datasets_request_dto.py +78 -0
  112. truefoundry/ml/autogen/client/models/list_datasets_response_dto.py +86 -0
  113. truefoundry/ml/autogen/client/models/list_experiments_response_dto.py +86 -0
  114. truefoundry/ml/autogen/client/models/list_files_for_artifact_version_request_dto.py +76 -0
  115. truefoundry/ml/autogen/client/models/list_files_for_artifact_versions_response_dto.py +82 -0
  116. truefoundry/ml/autogen/client/models/list_files_for_dataset_request_dto.py +76 -0
  117. truefoundry/ml/autogen/client/models/list_files_for_dataset_response_dto.py +82 -0
  118. truefoundry/ml/autogen/client/models/list_latest_run_logs_response_dto.py +82 -0
  119. truefoundry/ml/autogen/client/models/list_metric_history_request_dto.py +69 -0
  120. truefoundry/ml/autogen/client/models/list_metric_history_response_dto.py +84 -0
  121. truefoundry/ml/autogen/client/models/list_model_version_response_dto.py +87 -0
  122. truefoundry/ml/autogen/client/models/list_model_versions_request_dto.py +93 -0
  123. truefoundry/ml/autogen/client/models/list_models_request_dto.py +89 -0
  124. truefoundry/ml/autogen/client/models/list_models_response_dto.py +84 -0
  125. truefoundry/ml/autogen/client/models/list_run_artifacts_response_dto.py +84 -0
  126. truefoundry/ml/autogen/client/models/list_run_logs_response_dto.py +82 -0
  127. truefoundry/ml/autogen/client/models/list_seed_experiments_response_dto.py +81 -0
  128. truefoundry/ml/autogen/client/models/log_batch_request_dto.py +106 -0
  129. truefoundry/ml/autogen/client/models/log_metric_request_dto.py +80 -0
  130. truefoundry/ml/autogen/client/models/log_param_request_dto.py +76 -0
  131. truefoundry/ml/autogen/client/models/method.py +37 -0
  132. truefoundry/ml/autogen/client/models/metric_collection_dto.py +82 -0
  133. truefoundry/ml/autogen/client/models/metric_dto.py +76 -0
  134. truefoundry/ml/autogen/client/models/mime_type.py +37 -0
  135. truefoundry/ml/autogen/client/models/model_configuration.py +103 -0
  136. truefoundry/ml/autogen/client/models/model_dto.py +122 -0
  137. truefoundry/ml/autogen/client/models/model_response_dto.py +75 -0
  138. truefoundry/ml/autogen/client/models/model_schema_dto.py +85 -0
  139. truefoundry/ml/autogen/client/models/model_version_dto.py +163 -0
  140. truefoundry/ml/autogen/client/models/model_version_response_dto.py +75 -0
  141. truefoundry/ml/autogen/client/models/multi_part_upload_dto.py +107 -0
  142. truefoundry/ml/autogen/client/models/multi_part_upload_response_dto.py +79 -0
  143. truefoundry/ml/autogen/client/models/multi_part_upload_storage_provider.py +34 -0
  144. truefoundry/ml/autogen/client/models/notify_artifact_version_failure_dto.py +65 -0
  145. truefoundry/ml/autogen/client/models/openapi_spec.py +152 -0
  146. truefoundry/ml/autogen/client/models/param_dto.py +66 -0
  147. truefoundry/ml/autogen/client/models/parameters.py +84 -0
  148. truefoundry/ml/autogen/client/models/prediction_type.py +34 -0
  149. truefoundry/ml/autogen/client/models/resolve_agent_app_response_dto.py +75 -0
  150. truefoundry/ml/autogen/client/models/restore_run_request_dto.py +65 -0
  151. truefoundry/ml/autogen/client/models/run_data_dto.py +104 -0
  152. truefoundry/ml/autogen/client/models/run_dto.py +84 -0
  153. truefoundry/ml/autogen/client/models/run_info_dto.py +105 -0
  154. truefoundry/ml/autogen/client/models/run_log_dto.py +90 -0
  155. truefoundry/ml/autogen/client/models/run_log_input_dto.py +80 -0
  156. truefoundry/ml/autogen/client/models/run_response_dto.py +75 -0
  157. truefoundry/ml/autogen/client/models/run_tag_dto.py +66 -0
  158. truefoundry/ml/autogen/client/models/search_runs_request_dto.py +94 -0
  159. truefoundry/ml/autogen/client/models/search_runs_response_dto.py +84 -0
  160. truefoundry/ml/autogen/client/models/set_experiment_tag_request_dto.py +73 -0
  161. truefoundry/ml/autogen/client/models/set_tag_request_dto.py +76 -0
  162. truefoundry/ml/autogen/client/models/signed_url_dto.py +69 -0
  163. truefoundry/ml/autogen/client/models/stop.py +152 -0
  164. truefoundry/ml/autogen/client/models/store_run_logs_request_dto.py +83 -0
  165. truefoundry/ml/autogen/client/models/system_message.py +89 -0
  166. truefoundry/ml/autogen/client/models/text.py +153 -0
  167. truefoundry/ml/autogen/client/models/text_content_part.py +84 -0
  168. truefoundry/ml/autogen/client/models/update_artifact_version_request_dto.py +74 -0
  169. truefoundry/ml/autogen/client/models/update_dataset_request_dto.py +74 -0
  170. truefoundry/ml/autogen/client/models/update_experiment_request_dto.py +74 -0
  171. truefoundry/ml/autogen/client/models/update_model_version_request_dto.py +93 -0
  172. truefoundry/ml/autogen/client/models/update_run_request_dto.py +78 -0
  173. truefoundry/ml/autogen/client/models/update_run_response_dto.py +76 -0
  174. truefoundry/ml/autogen/client/models/url.py +153 -0
  175. truefoundry/ml/autogen/client/models/user_message.py +89 -0
  176. truefoundry/ml/autogen/client/models/validation_error.py +87 -0
  177. truefoundry/ml/autogen/client/models/validation_error_loc_inner.py +154 -0
  178. truefoundry/ml/autogen/client/rest.py +426 -0
  179. truefoundry/ml/autogen/client_README.md +322 -0
  180. truefoundry/ml/cli/__init__.py +0 -0
  181. truefoundry/ml/cli/cli.py +18 -0
  182. truefoundry/ml/cli/commands/__init__.py +3 -0
  183. truefoundry/ml/cli/commands/download.py +87 -0
  184. truefoundry/ml/constants.py +84 -0
  185. truefoundry/ml/enums.py +70 -0
  186. truefoundry/ml/env_vars.py +13 -0
  187. truefoundry/ml/exceptions.py +8 -0
  188. truefoundry/ml/git_info.py +60 -0
  189. truefoundry/ml/internal_namespace.py +52 -0
  190. truefoundry/ml/log_types/__init__.py +4 -0
  191. truefoundry/ml/log_types/artifacts/artifact.py +427 -0
  192. truefoundry/ml/log_types/artifacts/constants.py +33 -0
  193. truefoundry/ml/log_types/artifacts/dataset.py +383 -0
  194. truefoundry/ml/log_types/artifacts/general_artifact.py +110 -0
  195. truefoundry/ml/log_types/artifacts/model.py +628 -0
  196. truefoundry/ml/log_types/artifacts/model_extras.py +48 -0
  197. truefoundry/ml/log_types/artifacts/utils.py +161 -0
  198. truefoundry/ml/log_types/image/__init__.py +3 -0
  199. truefoundry/ml/log_types/image/constants.py +8 -0
  200. truefoundry/ml/log_types/image/image.py +358 -0
  201. truefoundry/ml/log_types/image/image_normalizer.py +101 -0
  202. truefoundry/ml/log_types/image/types.py +68 -0
  203. truefoundry/ml/log_types/plot.py +281 -0
  204. truefoundry/ml/log_types/pydantic_base.py +10 -0
  205. truefoundry/ml/log_types/utils.py +12 -0
  206. truefoundry/ml/logger.py +17 -0
  207. truefoundry/ml/login.py +241 -0
  208. truefoundry/ml/mlfoundry_api.py +1620 -0
  209. truefoundry/ml/mlfoundry_run.py +1238 -0
  210. truefoundry/ml/run_utils.py +102 -0
  211. truefoundry/ml/services/__init__.py +0 -0
  212. truefoundry/ml/services/auth_service.py +109 -0
  213. truefoundry/ml/services/entities.py +108 -0
  214. truefoundry/ml/services/servicefoundry_service.py +35 -0
  215. truefoundry/ml/services/utils.py +122 -0
  216. truefoundry/ml/session.py +271 -0
  217. truefoundry/ml/validation_utils.py +346 -0
  218. truefoundry/pydantic_v1.py +5 -1
  219. {truefoundry-0.3.3.dist-info → truefoundry-0.4.0.dev0.dist-info}/METADATA +19 -12
  220. truefoundry-0.4.0.dev0.dist-info/RECORD +342 -0
  221. truefoundry-0.3.3.dist-info/RECORD +0 -136
  222. /truefoundry/{python_deploy_codegen.py → deploy/python_deploy_codegen.py} +0 -0
  223. {truefoundry-0.3.3.dist-info → truefoundry-0.4.0.dev0.dist-info}/WHEEL +0 -0
  224. {truefoundry-0.3.3.dist-info → truefoundry-0.4.0.dev0.dist-info}/entry_points.txt +0 -0
@@ -0,0 +1,2919 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ FastAPI
5
+
6
+ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
7
+
8
+ The version of the OpenAPI document: 0.1.0
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """ # noqa: E501
13
+
14
+ import re # noqa: F401
15
+ from typing import Optional
16
+
17
+ from truefoundry.ml.autogen.client.api_client import ApiClient
18
+ from truefoundry.ml.autogen.client.api_response import ApiResponse
19
+ from truefoundry.ml.autogen.client.exceptions import ( # noqa: F401
20
+ ApiTypeError,
21
+ ApiValueError,
22
+ )
23
+ from truefoundry.ml.autogen.client.models.create_run_request_dto import (
24
+ CreateRunRequestDto,
25
+ )
26
+ from truefoundry.ml.autogen.client.models.create_run_response_dto import (
27
+ CreateRunResponseDto,
28
+ )
29
+ from truefoundry.ml.autogen.client.models.delete_run_request import DeleteRunRequest
30
+ from truefoundry.ml.autogen.client.models.delete_tag_request_dto import (
31
+ DeleteTagRequestDto,
32
+ )
33
+ from truefoundry.ml.autogen.client.models.get_latest_run_log_response_dto import (
34
+ GetLatestRunLogResponseDto,
35
+ )
36
+ from truefoundry.ml.autogen.client.models.list_latest_run_logs_response_dto import (
37
+ ListLatestRunLogsResponseDto,
38
+ )
39
+ from truefoundry.ml.autogen.client.models.list_run_logs_response_dto import (
40
+ ListRunLogsResponseDto,
41
+ )
42
+ from truefoundry.ml.autogen.client.models.log_batch_request_dto import (
43
+ LogBatchRequestDto,
44
+ )
45
+ from truefoundry.ml.autogen.client.models.log_metric_request_dto import (
46
+ LogMetricRequestDto,
47
+ )
48
+ from truefoundry.ml.autogen.client.models.log_param_request_dto import (
49
+ LogParamRequestDto,
50
+ )
51
+ from truefoundry.ml.autogen.client.models.restore_run_request_dto import (
52
+ RestoreRunRequestDto,
53
+ )
54
+ from truefoundry.ml.autogen.client.models.run_response_dto import RunResponseDto
55
+ from truefoundry.ml.autogen.client.models.search_runs_request_dto import (
56
+ SearchRunsRequestDto,
57
+ )
58
+ from truefoundry.ml.autogen.client.models.search_runs_response_dto import (
59
+ SearchRunsResponseDto,
60
+ )
61
+ from truefoundry.ml.autogen.client.models.set_tag_request_dto import SetTagRequestDto
62
+ from truefoundry.ml.autogen.client.models.store_run_logs_request_dto import (
63
+ StoreRunLogsRequestDto,
64
+ )
65
+ from truefoundry.ml.autogen.client.models.update_run_request_dto import (
66
+ UpdateRunRequestDto,
67
+ )
68
+ from truefoundry.ml.autogen.client.models.update_run_response_dto import (
69
+ UpdateRunResponseDto,
70
+ )
71
+ from truefoundry.pydantic_v1 import (
72
+ StrictInt,
73
+ StrictStr,
74
+ conlist,
75
+ validate_arguments,
76
+ )
77
+
78
+
79
+ class RunsApi:
80
+ """NOTE: This class is auto generated by OpenAPI Generator
81
+ Ref: https://openapi-generator.tech
82
+
83
+ Do not edit the class manually.
84
+ """
85
+
86
+ def __init__(self, api_client=None) -> None:
87
+ if api_client is None:
88
+ api_client = ApiClient.get_default()
89
+ self.api_client = api_client
90
+
91
+ @validate_arguments
92
+ def create_run_post(
93
+ self, create_run_request_dto: CreateRunRequestDto, **kwargs
94
+ ) -> CreateRunResponseDto: # noqa: E501
95
+ """Create Run # noqa: E501
96
+
97
+ Create Run # noqa: E501
98
+ This method makes a synchronous HTTP request by default. To make an
99
+ asynchronous HTTP request, please pass async_req=True
100
+
101
+ >>> thread = api.create_run_post(create_run_request_dto, async_req=True)
102
+ >>> result = thread.get()
103
+
104
+ :param create_run_request_dto: (required)
105
+ :type create_run_request_dto: CreateRunRequestDto
106
+ :param async_req: Whether to execute the request asynchronously.
107
+ :type async_req: bool, optional
108
+ :param _request_timeout: timeout setting for this request.
109
+ If one number provided, it will be total request
110
+ timeout. It can also be a pair (tuple) of
111
+ (connection, read) timeouts.
112
+ :return: Returns the result object.
113
+ If the method is called asynchronously,
114
+ returns the request thread.
115
+ :rtype: CreateRunResponseDto
116
+ """
117
+ kwargs["_return_http_data_only"] = True
118
+ if "_preload_content" in kwargs:
119
+ message = "Error! Please call the create_run_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
120
+ raise ValueError(message)
121
+ return self.create_run_post_with_http_info(create_run_request_dto, **kwargs) # noqa: E501
122
+
123
+ @validate_arguments
124
+ def create_run_post_with_http_info(
125
+ self, create_run_request_dto: CreateRunRequestDto, **kwargs
126
+ ) -> ApiResponse: # noqa: E501
127
+ """Create Run # noqa: E501
128
+
129
+ Create Run # noqa: E501
130
+ This method makes a synchronous HTTP request by default. To make an
131
+ asynchronous HTTP request, please pass async_req=True
132
+
133
+ >>> thread = api.create_run_post_with_http_info(create_run_request_dto, async_req=True)
134
+ >>> result = thread.get()
135
+
136
+ :param create_run_request_dto: (required)
137
+ :type create_run_request_dto: CreateRunRequestDto
138
+ :param async_req: Whether to execute the request asynchronously.
139
+ :type async_req: bool, optional
140
+ :param _preload_content: if False, the ApiResponse.data will
141
+ be set to none and raw_data will store the
142
+ HTTP response body without reading/decoding.
143
+ Default is True.
144
+ :type _preload_content: bool, optional
145
+ :param _return_http_data_only: response data instead of ApiResponse
146
+ object with status code, headers, etc
147
+ :type _return_http_data_only: bool, optional
148
+ :param _request_timeout: timeout setting for this request. If one
149
+ number provided, it will be total request
150
+ timeout. It can also be a pair (tuple) of
151
+ (connection, read) timeouts.
152
+ :param _request_auth: set to override the auth_settings for an a single
153
+ request; this effectively ignores the authentication
154
+ in the spec for a single request.
155
+ :type _request_auth: dict, optional
156
+ :type _content_type: string, optional: force content-type for the request
157
+ :return: Returns the result object.
158
+ If the method is called asynchronously,
159
+ returns the request thread.
160
+ :rtype: tuple(CreateRunResponseDto, status_code(int), headers(HTTPHeaderDict))
161
+ """
162
+
163
+ _params = locals()
164
+
165
+ _all_params = ["create_run_request_dto"]
166
+ _all_params.extend(
167
+ [
168
+ "async_req",
169
+ "_return_http_data_only",
170
+ "_preload_content",
171
+ "_request_timeout",
172
+ "_request_auth",
173
+ "_content_type",
174
+ "_headers",
175
+ ]
176
+ )
177
+
178
+ # validate the arguments
179
+ for _key, _val in _params["kwargs"].items():
180
+ if _key not in _all_params:
181
+ raise ApiTypeError(
182
+ "Got an unexpected keyword argument '%s'"
183
+ " to method create_run_post" % _key
184
+ )
185
+ _params[_key] = _val
186
+ del _params["kwargs"]
187
+
188
+ _collection_formats = {}
189
+
190
+ # process the path parameters
191
+ _path_params = {}
192
+
193
+ # process the query parameters
194
+ _query_params = []
195
+ # process the header parameters
196
+ _header_params = dict(_params.get("_headers", {}))
197
+ # process the form parameters
198
+ _form_params = []
199
+ _files = {}
200
+ # process the body parameter
201
+ _body_params = None
202
+ if _params["create_run_request_dto"] is not None:
203
+ _body_params = _params["create_run_request_dto"]
204
+
205
+ # set the HTTP header `Accept`
206
+ _header_params["Accept"] = self.api_client.select_header_accept(
207
+ ["application/json"]
208
+ ) # noqa: E501
209
+
210
+ # set the HTTP header `Content-Type`
211
+ _content_types_list = _params.get(
212
+ "_content_type",
213
+ self.api_client.select_header_content_type(["application/json"]),
214
+ )
215
+ if _content_types_list:
216
+ _header_params["Content-Type"] = _content_types_list
217
+
218
+ # authentication setting
219
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
220
+
221
+ _response_types_map = {
222
+ "200": "CreateRunResponseDto",
223
+ "422": "HTTPValidationError",
224
+ }
225
+
226
+ return self.api_client.call_api(
227
+ "/api/2.0/mlflow/runs/create",
228
+ "POST",
229
+ _path_params,
230
+ _query_params,
231
+ _header_params,
232
+ body=_body_params,
233
+ post_params=_form_params,
234
+ files=_files,
235
+ response_types_map=_response_types_map,
236
+ auth_settings=_auth_settings,
237
+ async_req=_params.get("async_req"),
238
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
239
+ _preload_content=_params.get("_preload_content", True),
240
+ _request_timeout=_params.get("_request_timeout"),
241
+ collection_formats=_collection_formats,
242
+ _request_auth=_params.get("_request_auth"),
243
+ )
244
+
245
+ @validate_arguments
246
+ def delete_run_post(self, delete_run_request: DeleteRunRequest, **kwargs) -> object: # noqa: E501
247
+ """Delete Run # noqa: E501
248
+
249
+ Delete Run # noqa: E501
250
+ This method makes a synchronous HTTP request by default. To make an
251
+ asynchronous HTTP request, please pass async_req=True
252
+
253
+ >>> thread = api.delete_run_post(delete_run_request, async_req=True)
254
+ >>> result = thread.get()
255
+
256
+ :param delete_run_request: (required)
257
+ :type delete_run_request: DeleteRunRequest
258
+ :param async_req: Whether to execute the request asynchronously.
259
+ :type async_req: bool, optional
260
+ :param _request_timeout: timeout setting for this request.
261
+ If one number provided, it will be total request
262
+ timeout. It can also be a pair (tuple) of
263
+ (connection, read) timeouts.
264
+ :return: Returns the result object.
265
+ If the method is called asynchronously,
266
+ returns the request thread.
267
+ :rtype: object
268
+ """
269
+ kwargs["_return_http_data_only"] = True
270
+ if "_preload_content" in kwargs:
271
+ message = "Error! Please call the delete_run_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
272
+ raise ValueError(message)
273
+ return self.delete_run_post_with_http_info(delete_run_request, **kwargs) # noqa: E501
274
+
275
+ @validate_arguments
276
+ def delete_run_post_with_http_info(
277
+ self, delete_run_request: DeleteRunRequest, **kwargs
278
+ ) -> ApiResponse: # noqa: E501
279
+ """Delete Run # noqa: E501
280
+
281
+ Delete Run # noqa: E501
282
+ This method makes a synchronous HTTP request by default. To make an
283
+ asynchronous HTTP request, please pass async_req=True
284
+
285
+ >>> thread = api.delete_run_post_with_http_info(delete_run_request, async_req=True)
286
+ >>> result = thread.get()
287
+
288
+ :param delete_run_request: (required)
289
+ :type delete_run_request: DeleteRunRequest
290
+ :param async_req: Whether to execute the request asynchronously.
291
+ :type async_req: bool, optional
292
+ :param _preload_content: if False, the ApiResponse.data will
293
+ be set to none and raw_data will store the
294
+ HTTP response body without reading/decoding.
295
+ Default is True.
296
+ :type _preload_content: bool, optional
297
+ :param _return_http_data_only: response data instead of ApiResponse
298
+ object with status code, headers, etc
299
+ :type _return_http_data_only: bool, optional
300
+ :param _request_timeout: timeout setting for this request. If one
301
+ number provided, it will be total request
302
+ timeout. It can also be a pair (tuple) of
303
+ (connection, read) timeouts.
304
+ :param _request_auth: set to override the auth_settings for an a single
305
+ request; this effectively ignores the authentication
306
+ in the spec for a single request.
307
+ :type _request_auth: dict, optional
308
+ :type _content_type: string, optional: force content-type for the request
309
+ :return: Returns the result object.
310
+ If the method is called asynchronously,
311
+ returns the request thread.
312
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
313
+ """
314
+
315
+ _params = locals()
316
+
317
+ _all_params = ["delete_run_request"]
318
+ _all_params.extend(
319
+ [
320
+ "async_req",
321
+ "_return_http_data_only",
322
+ "_preload_content",
323
+ "_request_timeout",
324
+ "_request_auth",
325
+ "_content_type",
326
+ "_headers",
327
+ ]
328
+ )
329
+
330
+ # validate the arguments
331
+ for _key, _val in _params["kwargs"].items():
332
+ if _key not in _all_params:
333
+ raise ApiTypeError(
334
+ "Got an unexpected keyword argument '%s'"
335
+ " to method delete_run_post" % _key
336
+ )
337
+ _params[_key] = _val
338
+ del _params["kwargs"]
339
+
340
+ _collection_formats = {}
341
+
342
+ # process the path parameters
343
+ _path_params = {}
344
+
345
+ # process the query parameters
346
+ _query_params = []
347
+ # process the header parameters
348
+ _header_params = dict(_params.get("_headers", {}))
349
+ # process the form parameters
350
+ _form_params = []
351
+ _files = {}
352
+ # process the body parameter
353
+ _body_params = None
354
+ if _params["delete_run_request"] is not None:
355
+ _body_params = _params["delete_run_request"]
356
+
357
+ # set the HTTP header `Accept`
358
+ _header_params["Accept"] = self.api_client.select_header_accept(
359
+ ["application/json"]
360
+ ) # noqa: E501
361
+
362
+ # set the HTTP header `Content-Type`
363
+ _content_types_list = _params.get(
364
+ "_content_type",
365
+ self.api_client.select_header_content_type(["application/json"]),
366
+ )
367
+ if _content_types_list:
368
+ _header_params["Content-Type"] = _content_types_list
369
+
370
+ # authentication setting
371
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
372
+
373
+ _response_types_map = {
374
+ "200": "object",
375
+ "422": "HTTPValidationError",
376
+ }
377
+
378
+ return self.api_client.call_api(
379
+ "/api/2.0/mlflow/runs/delete",
380
+ "POST",
381
+ _path_params,
382
+ _query_params,
383
+ _header_params,
384
+ body=_body_params,
385
+ post_params=_form_params,
386
+ files=_files,
387
+ response_types_map=_response_types_map,
388
+ auth_settings=_auth_settings,
389
+ async_req=_params.get("async_req"),
390
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
391
+ _preload_content=_params.get("_preload_content", True),
392
+ _request_timeout=_params.get("_request_timeout"),
393
+ collection_formats=_collection_formats,
394
+ _request_auth=_params.get("_request_auth"),
395
+ )
396
+
397
+ @validate_arguments
398
+ def delete_tag_post(
399
+ self, delete_tag_request_dto: DeleteTagRequestDto, **kwargs
400
+ ) -> object: # noqa: E501
401
+ """Delete Tag # noqa: E501
402
+
403
+ Delete Tag # noqa: E501
404
+ This method makes a synchronous HTTP request by default. To make an
405
+ asynchronous HTTP request, please pass async_req=True
406
+
407
+ >>> thread = api.delete_tag_post(delete_tag_request_dto, async_req=True)
408
+ >>> result = thread.get()
409
+
410
+ :param delete_tag_request_dto: (required)
411
+ :type delete_tag_request_dto: DeleteTagRequestDto
412
+ :param async_req: Whether to execute the request asynchronously.
413
+ :type async_req: bool, optional
414
+ :param _request_timeout: timeout setting for this request.
415
+ If one number provided, it will be total request
416
+ timeout. It can also be a pair (tuple) of
417
+ (connection, read) timeouts.
418
+ :return: Returns the result object.
419
+ If the method is called asynchronously,
420
+ returns the request thread.
421
+ :rtype: object
422
+ """
423
+ kwargs["_return_http_data_only"] = True
424
+ if "_preload_content" in kwargs:
425
+ message = "Error! Please call the delete_tag_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
426
+ raise ValueError(message)
427
+ return self.delete_tag_post_with_http_info(delete_tag_request_dto, **kwargs) # noqa: E501
428
+
429
+ @validate_arguments
430
+ def delete_tag_post_with_http_info(
431
+ self, delete_tag_request_dto: DeleteTagRequestDto, **kwargs
432
+ ) -> ApiResponse: # noqa: E501
433
+ """Delete Tag # noqa: E501
434
+
435
+ Delete Tag # noqa: E501
436
+ This method makes a synchronous HTTP request by default. To make an
437
+ asynchronous HTTP request, please pass async_req=True
438
+
439
+ >>> thread = api.delete_tag_post_with_http_info(delete_tag_request_dto, async_req=True)
440
+ >>> result = thread.get()
441
+
442
+ :param delete_tag_request_dto: (required)
443
+ :type delete_tag_request_dto: DeleteTagRequestDto
444
+ :param async_req: Whether to execute the request asynchronously.
445
+ :type async_req: bool, optional
446
+ :param _preload_content: if False, the ApiResponse.data will
447
+ be set to none and raw_data will store the
448
+ HTTP response body without reading/decoding.
449
+ Default is True.
450
+ :type _preload_content: bool, optional
451
+ :param _return_http_data_only: response data instead of ApiResponse
452
+ object with status code, headers, etc
453
+ :type _return_http_data_only: bool, optional
454
+ :param _request_timeout: timeout setting for this request. If one
455
+ number provided, it will be total request
456
+ timeout. It can also be a pair (tuple) of
457
+ (connection, read) timeouts.
458
+ :param _request_auth: set to override the auth_settings for an a single
459
+ request; this effectively ignores the authentication
460
+ in the spec for a single request.
461
+ :type _request_auth: dict, optional
462
+ :type _content_type: string, optional: force content-type for the request
463
+ :return: Returns the result object.
464
+ If the method is called asynchronously,
465
+ returns the request thread.
466
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
467
+ """
468
+
469
+ _params = locals()
470
+
471
+ _all_params = ["delete_tag_request_dto"]
472
+ _all_params.extend(
473
+ [
474
+ "async_req",
475
+ "_return_http_data_only",
476
+ "_preload_content",
477
+ "_request_timeout",
478
+ "_request_auth",
479
+ "_content_type",
480
+ "_headers",
481
+ ]
482
+ )
483
+
484
+ # validate the arguments
485
+ for _key, _val in _params["kwargs"].items():
486
+ if _key not in _all_params:
487
+ raise ApiTypeError(
488
+ "Got an unexpected keyword argument '%s'"
489
+ " to method delete_tag_post" % _key
490
+ )
491
+ _params[_key] = _val
492
+ del _params["kwargs"]
493
+
494
+ _collection_formats = {}
495
+
496
+ # process the path parameters
497
+ _path_params = {}
498
+
499
+ # process the query parameters
500
+ _query_params = []
501
+ # process the header parameters
502
+ _header_params = dict(_params.get("_headers", {}))
503
+ # process the form parameters
504
+ _form_params = []
505
+ _files = {}
506
+ # process the body parameter
507
+ _body_params = None
508
+ if _params["delete_tag_request_dto"] is not None:
509
+ _body_params = _params["delete_tag_request_dto"]
510
+
511
+ # set the HTTP header `Accept`
512
+ _header_params["Accept"] = self.api_client.select_header_accept(
513
+ ["application/json"]
514
+ ) # noqa: E501
515
+
516
+ # set the HTTP header `Content-Type`
517
+ _content_types_list = _params.get(
518
+ "_content_type",
519
+ self.api_client.select_header_content_type(["application/json"]),
520
+ )
521
+ if _content_types_list:
522
+ _header_params["Content-Type"] = _content_types_list
523
+
524
+ # authentication setting
525
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
526
+
527
+ _response_types_map = {
528
+ "200": "object",
529
+ "422": "HTTPValidationError",
530
+ }
531
+
532
+ return self.api_client.call_api(
533
+ "/api/2.0/mlflow/runs/delete-tag",
534
+ "POST",
535
+ _path_params,
536
+ _query_params,
537
+ _header_params,
538
+ body=_body_params,
539
+ post_params=_form_params,
540
+ files=_files,
541
+ response_types_map=_response_types_map,
542
+ auth_settings=_auth_settings,
543
+ async_req=_params.get("async_req"),
544
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
545
+ _preload_content=_params.get("_preload_content", True),
546
+ _request_timeout=_params.get("_request_timeout"),
547
+ collection_formats=_collection_formats,
548
+ _request_auth=_params.get("_request_auth"),
549
+ )
550
+
551
+ @validate_arguments
552
+ def get_run_by_fqn_get(self, run_fqn: StrictStr, **kwargs) -> RunResponseDto: # noqa: E501
553
+ """Get Run By Fqn # noqa: E501
554
+
555
+ Get Run by run FQN # noqa: E501
556
+ This method makes a synchronous HTTP request by default. To make an
557
+ asynchronous HTTP request, please pass async_req=True
558
+
559
+ >>> thread = api.get_run_by_fqn_get(run_fqn, async_req=True)
560
+ >>> result = thread.get()
561
+
562
+ :param run_fqn: (required)
563
+ :type run_fqn: str
564
+ :param async_req: Whether to execute the request asynchronously.
565
+ :type async_req: bool, optional
566
+ :param _request_timeout: timeout setting for this request.
567
+ If one number provided, it will be total request
568
+ timeout. It can also be a pair (tuple) of
569
+ (connection, read) timeouts.
570
+ :return: Returns the result object.
571
+ If the method is called asynchronously,
572
+ returns the request thread.
573
+ :rtype: RunResponseDto
574
+ """
575
+ kwargs["_return_http_data_only"] = True
576
+ if "_preload_content" in kwargs:
577
+ message = "Error! Please call the get_run_by_fqn_get_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
578
+ raise ValueError(message)
579
+ return self.get_run_by_fqn_get_with_http_info(run_fqn, **kwargs) # noqa: E501
580
+
581
+ @validate_arguments
582
+ def get_run_by_fqn_get_with_http_info(
583
+ self, run_fqn: StrictStr, **kwargs
584
+ ) -> ApiResponse: # noqa: E501
585
+ """Get Run By Fqn # noqa: E501
586
+
587
+ Get Run by run FQN # noqa: E501
588
+ This method makes a synchronous HTTP request by default. To make an
589
+ asynchronous HTTP request, please pass async_req=True
590
+
591
+ >>> thread = api.get_run_by_fqn_get_with_http_info(run_fqn, async_req=True)
592
+ >>> result = thread.get()
593
+
594
+ :param run_fqn: (required)
595
+ :type run_fqn: str
596
+ :param async_req: Whether to execute the request asynchronously.
597
+ :type async_req: bool, optional
598
+ :param _preload_content: if False, the ApiResponse.data will
599
+ be set to none and raw_data will store the
600
+ HTTP response body without reading/decoding.
601
+ Default is True.
602
+ :type _preload_content: bool, optional
603
+ :param _return_http_data_only: response data instead of ApiResponse
604
+ object with status code, headers, etc
605
+ :type _return_http_data_only: bool, optional
606
+ :param _request_timeout: timeout setting for this request. If one
607
+ number provided, it will be total request
608
+ timeout. It can also be a pair (tuple) of
609
+ (connection, read) timeouts.
610
+ :param _request_auth: set to override the auth_settings for an a single
611
+ request; this effectively ignores the authentication
612
+ in the spec for a single request.
613
+ :type _request_auth: dict, optional
614
+ :type _content_type: string, optional: force content-type for the request
615
+ :return: Returns the result object.
616
+ If the method is called asynchronously,
617
+ returns the request thread.
618
+ :rtype: tuple(RunResponseDto, status_code(int), headers(HTTPHeaderDict))
619
+ """
620
+
621
+ _params = locals()
622
+
623
+ _all_params = ["run_fqn"]
624
+ _all_params.extend(
625
+ [
626
+ "async_req",
627
+ "_return_http_data_only",
628
+ "_preload_content",
629
+ "_request_timeout",
630
+ "_request_auth",
631
+ "_content_type",
632
+ "_headers",
633
+ ]
634
+ )
635
+
636
+ # validate the arguments
637
+ for _key, _val in _params["kwargs"].items():
638
+ if _key not in _all_params:
639
+ raise ApiTypeError(
640
+ "Got an unexpected keyword argument '%s'"
641
+ " to method get_run_by_fqn_get" % _key
642
+ )
643
+ _params[_key] = _val
644
+ del _params["kwargs"]
645
+
646
+ _collection_formats = {}
647
+
648
+ # process the path parameters
649
+ _path_params = {}
650
+
651
+ # process the query parameters
652
+ _query_params = []
653
+ if _params.get("run_fqn") is not None: # noqa: E501
654
+ _query_params.append(("run_fqn", _params["run_fqn"]))
655
+
656
+ # process the header parameters
657
+ _header_params = dict(_params.get("_headers", {}))
658
+ # process the form parameters
659
+ _form_params = []
660
+ _files = {}
661
+ # process the body parameter
662
+ _body_params = None
663
+ # set the HTTP header `Accept`
664
+ _header_params["Accept"] = self.api_client.select_header_accept(
665
+ ["application/json"]
666
+ ) # noqa: E501
667
+
668
+ # authentication setting
669
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
670
+
671
+ _response_types_map = {
672
+ "200": "RunResponseDto",
673
+ "422": "HTTPValidationError",
674
+ }
675
+
676
+ return self.api_client.call_api(
677
+ "/api/2.0/mlflow/runs/get-by-fqn",
678
+ "GET",
679
+ _path_params,
680
+ _query_params,
681
+ _header_params,
682
+ body=_body_params,
683
+ post_params=_form_params,
684
+ files=_files,
685
+ response_types_map=_response_types_map,
686
+ auth_settings=_auth_settings,
687
+ async_req=_params.get("async_req"),
688
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
689
+ _preload_content=_params.get("_preload_content", True),
690
+ _request_timeout=_params.get("_request_timeout"),
691
+ collection_formats=_collection_formats,
692
+ _request_auth=_params.get("_request_auth"),
693
+ )
694
+
695
+ @validate_arguments
696
+ def get_run_by_name_get(
697
+ self,
698
+ run_name: StrictStr,
699
+ experiment_id: Optional[StrictStr] = None,
700
+ experiment_name: Optional[StrictStr] = None,
701
+ **kwargs,
702
+ ) -> RunResponseDto: # noqa: E501
703
+ """Get Run By Name # noqa: E501
704
+
705
+ Get Run by run name # noqa: E501
706
+ This method makes a synchronous HTTP request by default. To make an
707
+ asynchronous HTTP request, please pass async_req=True
708
+
709
+ >>> thread = api.get_run_by_name_get(run_name, experiment_id, experiment_name, async_req=True)
710
+ >>> result = thread.get()
711
+
712
+ :param run_name: (required)
713
+ :type run_name: str
714
+ :param experiment_id:
715
+ :type experiment_id: str
716
+ :param experiment_name:
717
+ :type experiment_name: str
718
+ :param async_req: Whether to execute the request asynchronously.
719
+ :type async_req: bool, optional
720
+ :param _request_timeout: timeout setting for this request.
721
+ If one number provided, it will be total request
722
+ timeout. It can also be a pair (tuple) of
723
+ (connection, read) timeouts.
724
+ :return: Returns the result object.
725
+ If the method is called asynchronously,
726
+ returns the request thread.
727
+ :rtype: RunResponseDto
728
+ """
729
+ kwargs["_return_http_data_only"] = True
730
+ if "_preload_content" in kwargs:
731
+ message = "Error! Please call the get_run_by_name_get_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
732
+ raise ValueError(message)
733
+ return self.get_run_by_name_get_with_http_info(
734
+ run_name, experiment_id, experiment_name, **kwargs
735
+ ) # noqa: E501
736
+
737
+ @validate_arguments
738
+ def get_run_by_name_get_with_http_info(
739
+ self,
740
+ run_name: StrictStr,
741
+ experiment_id: Optional[StrictStr] = None,
742
+ experiment_name: Optional[StrictStr] = None,
743
+ **kwargs,
744
+ ) -> ApiResponse: # noqa: E501
745
+ """Get Run By Name # noqa: E501
746
+
747
+ Get Run by run name # noqa: E501
748
+ This method makes a synchronous HTTP request by default. To make an
749
+ asynchronous HTTP request, please pass async_req=True
750
+
751
+ >>> thread = api.get_run_by_name_get_with_http_info(run_name, experiment_id, experiment_name, async_req=True)
752
+ >>> result = thread.get()
753
+
754
+ :param run_name: (required)
755
+ :type run_name: str
756
+ :param experiment_id:
757
+ :type experiment_id: str
758
+ :param experiment_name:
759
+ :type experiment_name: str
760
+ :param async_req: Whether to execute the request asynchronously.
761
+ :type async_req: bool, optional
762
+ :param _preload_content: if False, the ApiResponse.data will
763
+ be set to none and raw_data will store the
764
+ HTTP response body without reading/decoding.
765
+ Default is True.
766
+ :type _preload_content: bool, optional
767
+ :param _return_http_data_only: response data instead of ApiResponse
768
+ object with status code, headers, etc
769
+ :type _return_http_data_only: bool, optional
770
+ :param _request_timeout: timeout setting for this request. If one
771
+ number provided, it will be total request
772
+ timeout. It can also be a pair (tuple) of
773
+ (connection, read) timeouts.
774
+ :param _request_auth: set to override the auth_settings for an a single
775
+ request; this effectively ignores the authentication
776
+ in the spec for a single request.
777
+ :type _request_auth: dict, optional
778
+ :type _content_type: string, optional: force content-type for the request
779
+ :return: Returns the result object.
780
+ If the method is called asynchronously,
781
+ returns the request thread.
782
+ :rtype: tuple(RunResponseDto, status_code(int), headers(HTTPHeaderDict))
783
+ """
784
+
785
+ _params = locals()
786
+
787
+ _all_params = ["run_name", "experiment_id", "experiment_name"]
788
+ _all_params.extend(
789
+ [
790
+ "async_req",
791
+ "_return_http_data_only",
792
+ "_preload_content",
793
+ "_request_timeout",
794
+ "_request_auth",
795
+ "_content_type",
796
+ "_headers",
797
+ ]
798
+ )
799
+
800
+ # validate the arguments
801
+ for _key, _val in _params["kwargs"].items():
802
+ if _key not in _all_params:
803
+ raise ApiTypeError(
804
+ "Got an unexpected keyword argument '%s'"
805
+ " to method get_run_by_name_get" % _key
806
+ )
807
+ _params[_key] = _val
808
+ del _params["kwargs"]
809
+
810
+ _collection_formats = {}
811
+
812
+ # process the path parameters
813
+ _path_params = {}
814
+
815
+ # process the query parameters
816
+ _query_params = []
817
+ if _params.get("run_name") is not None: # noqa: E501
818
+ _query_params.append(("run_name", _params["run_name"]))
819
+
820
+ if _params.get("experiment_id") is not None: # noqa: E501
821
+ _query_params.append(("experiment_id", _params["experiment_id"]))
822
+
823
+ if _params.get("experiment_name") is not None: # noqa: E501
824
+ _query_params.append(("experiment_name", _params["experiment_name"]))
825
+
826
+ # process the header parameters
827
+ _header_params = dict(_params.get("_headers", {}))
828
+ # process the form parameters
829
+ _form_params = []
830
+ _files = {}
831
+ # process the body parameter
832
+ _body_params = None
833
+ # set the HTTP header `Accept`
834
+ _header_params["Accept"] = self.api_client.select_header_accept(
835
+ ["application/json"]
836
+ ) # noqa: E501
837
+
838
+ # authentication setting
839
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
840
+
841
+ _response_types_map = {
842
+ "200": "RunResponseDto",
843
+ "422": "HTTPValidationError",
844
+ }
845
+
846
+ return self.api_client.call_api(
847
+ "/api/2.0/mlflow/runs/get-by-name",
848
+ "GET",
849
+ _path_params,
850
+ _query_params,
851
+ _header_params,
852
+ body=_body_params,
853
+ post_params=_form_params,
854
+ files=_files,
855
+ response_types_map=_response_types_map,
856
+ auth_settings=_auth_settings,
857
+ async_req=_params.get("async_req"),
858
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
859
+ _preload_content=_params.get("_preload_content", True),
860
+ _request_timeout=_params.get("_request_timeout"),
861
+ collection_formats=_collection_formats,
862
+ _request_auth=_params.get("_request_auth"),
863
+ )
864
+
865
+ @validate_arguments
866
+ def get_run_get(
867
+ self,
868
+ run_id: Optional[StrictStr] = None,
869
+ run_uuid: Optional[StrictStr] = None,
870
+ **kwargs,
871
+ ) -> RunResponseDto: # noqa: E501
872
+ """Get Run # noqa: E501
873
+
874
+ Get Run # noqa: E501
875
+ This method makes a synchronous HTTP request by default. To make an
876
+ asynchronous HTTP request, please pass async_req=True
877
+
878
+ >>> thread = api.get_run_get(run_id, run_uuid, async_req=True)
879
+ >>> result = thread.get()
880
+
881
+ :param run_id:
882
+ :type run_id: str
883
+ :param run_uuid:
884
+ :type run_uuid: str
885
+ :param async_req: Whether to execute the request asynchronously.
886
+ :type async_req: bool, optional
887
+ :param _request_timeout: timeout setting for this request.
888
+ If one number provided, it will be total request
889
+ timeout. It can also be a pair (tuple) of
890
+ (connection, read) timeouts.
891
+ :return: Returns the result object.
892
+ If the method is called asynchronously,
893
+ returns the request thread.
894
+ :rtype: RunResponseDto
895
+ """
896
+ kwargs["_return_http_data_only"] = True
897
+ if "_preload_content" in kwargs:
898
+ message = "Error! Please call the get_run_get_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
899
+ raise ValueError(message)
900
+ return self.get_run_get_with_http_info(run_id, run_uuid, **kwargs) # noqa: E501
901
+
902
+ @validate_arguments
903
+ def get_run_get_with_http_info(
904
+ self,
905
+ run_id: Optional[StrictStr] = None,
906
+ run_uuid: Optional[StrictStr] = None,
907
+ **kwargs,
908
+ ) -> ApiResponse: # noqa: E501
909
+ """Get Run # noqa: E501
910
+
911
+ Get Run # noqa: E501
912
+ This method makes a synchronous HTTP request by default. To make an
913
+ asynchronous HTTP request, please pass async_req=True
914
+
915
+ >>> thread = api.get_run_get_with_http_info(run_id, run_uuid, async_req=True)
916
+ >>> result = thread.get()
917
+
918
+ :param run_id:
919
+ :type run_id: str
920
+ :param run_uuid:
921
+ :type run_uuid: str
922
+ :param async_req: Whether to execute the request asynchronously.
923
+ :type async_req: bool, optional
924
+ :param _preload_content: if False, the ApiResponse.data will
925
+ be set to none and raw_data will store the
926
+ HTTP response body without reading/decoding.
927
+ Default is True.
928
+ :type _preload_content: bool, optional
929
+ :param _return_http_data_only: response data instead of ApiResponse
930
+ object with status code, headers, etc
931
+ :type _return_http_data_only: bool, optional
932
+ :param _request_timeout: timeout setting for this request. If one
933
+ number provided, it will be total request
934
+ timeout. It can also be a pair (tuple) of
935
+ (connection, read) timeouts.
936
+ :param _request_auth: set to override the auth_settings for an a single
937
+ request; this effectively ignores the authentication
938
+ in the spec for a single request.
939
+ :type _request_auth: dict, optional
940
+ :type _content_type: string, optional: force content-type for the request
941
+ :return: Returns the result object.
942
+ If the method is called asynchronously,
943
+ returns the request thread.
944
+ :rtype: tuple(RunResponseDto, status_code(int), headers(HTTPHeaderDict))
945
+ """
946
+
947
+ _params = locals()
948
+
949
+ _all_params = ["run_id", "run_uuid"]
950
+ _all_params.extend(
951
+ [
952
+ "async_req",
953
+ "_return_http_data_only",
954
+ "_preload_content",
955
+ "_request_timeout",
956
+ "_request_auth",
957
+ "_content_type",
958
+ "_headers",
959
+ ]
960
+ )
961
+
962
+ # validate the arguments
963
+ for _key, _val in _params["kwargs"].items():
964
+ if _key not in _all_params:
965
+ raise ApiTypeError(
966
+ "Got an unexpected keyword argument '%s'"
967
+ " to method get_run_get" % _key
968
+ )
969
+ _params[_key] = _val
970
+ del _params["kwargs"]
971
+
972
+ _collection_formats = {}
973
+
974
+ # process the path parameters
975
+ _path_params = {}
976
+
977
+ # process the query parameters
978
+ _query_params = []
979
+ if _params.get("run_id") is not None: # noqa: E501
980
+ _query_params.append(("run_id", _params["run_id"]))
981
+
982
+ if _params.get("run_uuid") is not None: # noqa: E501
983
+ _query_params.append(("run_uuid", _params["run_uuid"]))
984
+
985
+ # process the header parameters
986
+ _header_params = dict(_params.get("_headers", {}))
987
+ # process the form parameters
988
+ _form_params = []
989
+ _files = {}
990
+ # process the body parameter
991
+ _body_params = None
992
+ # set the HTTP header `Accept`
993
+ _header_params["Accept"] = self.api_client.select_header_accept(
994
+ ["application/json"]
995
+ ) # noqa: E501
996
+
997
+ # authentication setting
998
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
999
+
1000
+ _response_types_map = {
1001
+ "200": "RunResponseDto",
1002
+ "422": "HTTPValidationError",
1003
+ }
1004
+
1005
+ return self.api_client.call_api(
1006
+ "/api/2.0/mlflow/runs/get",
1007
+ "GET",
1008
+ _path_params,
1009
+ _query_params,
1010
+ _header_params,
1011
+ body=_body_params,
1012
+ post_params=_form_params,
1013
+ files=_files,
1014
+ response_types_map=_response_types_map,
1015
+ auth_settings=_auth_settings,
1016
+ async_req=_params.get("async_req"),
1017
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
1018
+ _preload_content=_params.get("_preload_content", True),
1019
+ _request_timeout=_params.get("_request_timeout"),
1020
+ collection_formats=_collection_formats,
1021
+ _request_auth=_params.get("_request_auth"),
1022
+ )
1023
+
1024
+ @validate_arguments
1025
+ def hard_delete_run_post(
1026
+ self, delete_run_request: DeleteRunRequest, **kwargs
1027
+ ) -> object: # noqa: E501
1028
+ """Hard Delete Run # noqa: E501
1029
+
1030
+ Hard Delete Run # noqa: E501
1031
+ This method makes a synchronous HTTP request by default. To make an
1032
+ asynchronous HTTP request, please pass async_req=True
1033
+
1034
+ >>> thread = api.hard_delete_run_post(delete_run_request, async_req=True)
1035
+ >>> result = thread.get()
1036
+
1037
+ :param delete_run_request: (required)
1038
+ :type delete_run_request: DeleteRunRequest
1039
+ :param async_req: Whether to execute the request asynchronously.
1040
+ :type async_req: bool, optional
1041
+ :param _request_timeout: timeout setting for this request.
1042
+ If one number provided, it will be total request
1043
+ timeout. It can also be a pair (tuple) of
1044
+ (connection, read) timeouts.
1045
+ :return: Returns the result object.
1046
+ If the method is called asynchronously,
1047
+ returns the request thread.
1048
+ :rtype: object
1049
+ """
1050
+ kwargs["_return_http_data_only"] = True
1051
+ if "_preload_content" in kwargs:
1052
+ message = "Error! Please call the hard_delete_run_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
1053
+ raise ValueError(message)
1054
+ return self.hard_delete_run_post_with_http_info(delete_run_request, **kwargs) # noqa: E501
1055
+
1056
+ @validate_arguments
1057
+ def hard_delete_run_post_with_http_info(
1058
+ self, delete_run_request: DeleteRunRequest, **kwargs
1059
+ ) -> ApiResponse: # noqa: E501
1060
+ """Hard Delete Run # noqa: E501
1061
+
1062
+ Hard Delete Run # noqa: E501
1063
+ This method makes a synchronous HTTP request by default. To make an
1064
+ asynchronous HTTP request, please pass async_req=True
1065
+
1066
+ >>> thread = api.hard_delete_run_post_with_http_info(delete_run_request, async_req=True)
1067
+ >>> result = thread.get()
1068
+
1069
+ :param delete_run_request: (required)
1070
+ :type delete_run_request: DeleteRunRequest
1071
+ :param async_req: Whether to execute the request asynchronously.
1072
+ :type async_req: bool, optional
1073
+ :param _preload_content: if False, the ApiResponse.data will
1074
+ be set to none and raw_data will store the
1075
+ HTTP response body without reading/decoding.
1076
+ Default is True.
1077
+ :type _preload_content: bool, optional
1078
+ :param _return_http_data_only: response data instead of ApiResponse
1079
+ object with status code, headers, etc
1080
+ :type _return_http_data_only: bool, optional
1081
+ :param _request_timeout: timeout setting for this request. If one
1082
+ number provided, it will be total request
1083
+ timeout. It can also be a pair (tuple) of
1084
+ (connection, read) timeouts.
1085
+ :param _request_auth: set to override the auth_settings for an a single
1086
+ request; this effectively ignores the authentication
1087
+ in the spec for a single request.
1088
+ :type _request_auth: dict, optional
1089
+ :type _content_type: string, optional: force content-type for the request
1090
+ :return: Returns the result object.
1091
+ If the method is called asynchronously,
1092
+ returns the request thread.
1093
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
1094
+ """
1095
+
1096
+ _params = locals()
1097
+
1098
+ _all_params = ["delete_run_request"]
1099
+ _all_params.extend(
1100
+ [
1101
+ "async_req",
1102
+ "_return_http_data_only",
1103
+ "_preload_content",
1104
+ "_request_timeout",
1105
+ "_request_auth",
1106
+ "_content_type",
1107
+ "_headers",
1108
+ ]
1109
+ )
1110
+
1111
+ # validate the arguments
1112
+ for _key, _val in _params["kwargs"].items():
1113
+ if _key not in _all_params:
1114
+ raise ApiTypeError(
1115
+ "Got an unexpected keyword argument '%s'"
1116
+ " to method hard_delete_run_post" % _key
1117
+ )
1118
+ _params[_key] = _val
1119
+ del _params["kwargs"]
1120
+
1121
+ _collection_formats = {}
1122
+
1123
+ # process the path parameters
1124
+ _path_params = {}
1125
+
1126
+ # process the query parameters
1127
+ _query_params = []
1128
+ # process the header parameters
1129
+ _header_params = dict(_params.get("_headers", {}))
1130
+ # process the form parameters
1131
+ _form_params = []
1132
+ _files = {}
1133
+ # process the body parameter
1134
+ _body_params = None
1135
+ if _params["delete_run_request"] is not None:
1136
+ _body_params = _params["delete_run_request"]
1137
+
1138
+ # set the HTTP header `Accept`
1139
+ _header_params["Accept"] = self.api_client.select_header_accept(
1140
+ ["application/json"]
1141
+ ) # noqa: E501
1142
+
1143
+ # set the HTTP header `Content-Type`
1144
+ _content_types_list = _params.get(
1145
+ "_content_type",
1146
+ self.api_client.select_header_content_type(["application/json"]),
1147
+ )
1148
+ if _content_types_list:
1149
+ _header_params["Content-Type"] = _content_types_list
1150
+
1151
+ # authentication setting
1152
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
1153
+
1154
+ _response_types_map = {
1155
+ "200": "object",
1156
+ "422": "HTTPValidationError",
1157
+ }
1158
+
1159
+ return self.api_client.call_api(
1160
+ "/api/2.0/mlflow/runs/hard-delete",
1161
+ "POST",
1162
+ _path_params,
1163
+ _query_params,
1164
+ _header_params,
1165
+ body=_body_params,
1166
+ post_params=_form_params,
1167
+ files=_files,
1168
+ response_types_map=_response_types_map,
1169
+ auth_settings=_auth_settings,
1170
+ async_req=_params.get("async_req"),
1171
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
1172
+ _preload_content=_params.get("_preload_content", True),
1173
+ _request_timeout=_params.get("_request_timeout"),
1174
+ collection_formats=_collection_formats,
1175
+ _request_auth=_params.get("_request_auth"),
1176
+ )
1177
+
1178
+ @validate_arguments
1179
+ def latest_run_log_get(
1180
+ self, run_uuid: StrictStr, key: StrictStr, log_type: StrictStr, **kwargs
1181
+ ) -> GetLatestRunLogResponseDto: # noqa: E501
1182
+ """Latest Run Log # noqa: E501
1183
+
1184
+ Get latest run log for a key # noqa: E501
1185
+ This method makes a synchronous HTTP request by default. To make an
1186
+ asynchronous HTTP request, please pass async_req=True
1187
+
1188
+ >>> thread = api.latest_run_log_get(run_uuid, key, log_type, async_req=True)
1189
+ >>> result = thread.get()
1190
+
1191
+ :param run_uuid: (required)
1192
+ :type run_uuid: str
1193
+ :param key: (required)
1194
+ :type key: str
1195
+ :param log_type: (required)
1196
+ :type log_type: str
1197
+ :param async_req: Whether to execute the request asynchronously.
1198
+ :type async_req: bool, optional
1199
+ :param _request_timeout: timeout setting for this request.
1200
+ If one number provided, it will be total request
1201
+ timeout. It can also be a pair (tuple) of
1202
+ (connection, read) timeouts.
1203
+ :return: Returns the result object.
1204
+ If the method is called asynchronously,
1205
+ returns the request thread.
1206
+ :rtype: GetLatestRunLogResponseDto
1207
+ """
1208
+ kwargs["_return_http_data_only"] = True
1209
+ if "_preload_content" in kwargs:
1210
+ message = "Error! Please call the latest_run_log_get_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
1211
+ raise ValueError(message)
1212
+ return self.latest_run_log_get_with_http_info(run_uuid, key, log_type, **kwargs) # noqa: E501
1213
+
1214
+ @validate_arguments
1215
+ def latest_run_log_get_with_http_info(
1216
+ self, run_uuid: StrictStr, key: StrictStr, log_type: StrictStr, **kwargs
1217
+ ) -> ApiResponse: # noqa: E501
1218
+ """Latest Run Log # noqa: E501
1219
+
1220
+ Get latest run log for a key # noqa: E501
1221
+ This method makes a synchronous HTTP request by default. To make an
1222
+ asynchronous HTTP request, please pass async_req=True
1223
+
1224
+ >>> thread = api.latest_run_log_get_with_http_info(run_uuid, key, log_type, async_req=True)
1225
+ >>> result = thread.get()
1226
+
1227
+ :param run_uuid: (required)
1228
+ :type run_uuid: str
1229
+ :param key: (required)
1230
+ :type key: str
1231
+ :param log_type: (required)
1232
+ :type log_type: str
1233
+ :param async_req: Whether to execute the request asynchronously.
1234
+ :type async_req: bool, optional
1235
+ :param _preload_content: if False, the ApiResponse.data will
1236
+ be set to none and raw_data will store the
1237
+ HTTP response body without reading/decoding.
1238
+ Default is True.
1239
+ :type _preload_content: bool, optional
1240
+ :param _return_http_data_only: response data instead of ApiResponse
1241
+ object with status code, headers, etc
1242
+ :type _return_http_data_only: bool, optional
1243
+ :param _request_timeout: timeout setting for this request. If one
1244
+ number provided, it will be total request
1245
+ timeout. It can also be a pair (tuple) of
1246
+ (connection, read) timeouts.
1247
+ :param _request_auth: set to override the auth_settings for an a single
1248
+ request; this effectively ignores the authentication
1249
+ in the spec for a single request.
1250
+ :type _request_auth: dict, optional
1251
+ :type _content_type: string, optional: force content-type for the request
1252
+ :return: Returns the result object.
1253
+ If the method is called asynchronously,
1254
+ returns the request thread.
1255
+ :rtype: tuple(GetLatestRunLogResponseDto, status_code(int), headers(HTTPHeaderDict))
1256
+ """
1257
+
1258
+ _params = locals()
1259
+
1260
+ _all_params = ["run_uuid", "key", "log_type"]
1261
+ _all_params.extend(
1262
+ [
1263
+ "async_req",
1264
+ "_return_http_data_only",
1265
+ "_preload_content",
1266
+ "_request_timeout",
1267
+ "_request_auth",
1268
+ "_content_type",
1269
+ "_headers",
1270
+ ]
1271
+ )
1272
+
1273
+ # validate the arguments
1274
+ for _key, _val in _params["kwargs"].items():
1275
+ if _key not in _all_params:
1276
+ raise ApiTypeError(
1277
+ "Got an unexpected keyword argument '%s'"
1278
+ " to method latest_run_log_get" % _key
1279
+ )
1280
+ _params[_key] = _val
1281
+ del _params["kwargs"]
1282
+
1283
+ _collection_formats = {}
1284
+
1285
+ # process the path parameters
1286
+ _path_params = {}
1287
+
1288
+ # process the query parameters
1289
+ _query_params = []
1290
+ if _params.get("run_uuid") is not None: # noqa: E501
1291
+ _query_params.append(("run_uuid", _params["run_uuid"]))
1292
+
1293
+ if _params.get("key") is not None: # noqa: E501
1294
+ _query_params.append(("key", _params["key"]))
1295
+
1296
+ if _params.get("log_type") is not None: # noqa: E501
1297
+ _query_params.append(("log_type", _params["log_type"]))
1298
+
1299
+ # process the header parameters
1300
+ _header_params = dict(_params.get("_headers", {}))
1301
+ # process the form parameters
1302
+ _form_params = []
1303
+ _files = {}
1304
+ # process the body parameter
1305
+ _body_params = None
1306
+ # set the HTTP header `Accept`
1307
+ _header_params["Accept"] = self.api_client.select_header_accept(
1308
+ ["application/json"]
1309
+ ) # noqa: E501
1310
+
1311
+ # authentication setting
1312
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
1313
+
1314
+ _response_types_map = {
1315
+ "200": "GetLatestRunLogResponseDto",
1316
+ "422": "HTTPValidationError",
1317
+ }
1318
+
1319
+ return self.api_client.call_api(
1320
+ "/api/2.0/mlflow/runs/run-logs/latest-run-log",
1321
+ "GET",
1322
+ _path_params,
1323
+ _query_params,
1324
+ _header_params,
1325
+ body=_body_params,
1326
+ post_params=_form_params,
1327
+ files=_files,
1328
+ response_types_map=_response_types_map,
1329
+ auth_settings=_auth_settings,
1330
+ async_req=_params.get("async_req"),
1331
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
1332
+ _preload_content=_params.get("_preload_content", True),
1333
+ _request_timeout=_params.get("_request_timeout"),
1334
+ collection_formats=_collection_formats,
1335
+ _request_auth=_params.get("_request_auth"),
1336
+ )
1337
+
1338
+ @validate_arguments
1339
+ def list_latest_run_logs_get(
1340
+ self,
1341
+ run_uuid: StrictStr,
1342
+ key: Optional[StrictStr] = None,
1343
+ log_type: Optional[StrictStr] = None,
1344
+ **kwargs,
1345
+ ) -> ListLatestRunLogsResponseDto: # noqa: E501
1346
+ """List Latest Run Logs # noqa: E501
1347
+
1348
+ This method makes a synchronous HTTP request by default. To make an
1349
+ asynchronous HTTP request, please pass async_req=True
1350
+
1351
+ >>> thread = api.list_latest_run_logs_get(run_uuid, key, log_type, async_req=True)
1352
+ >>> result = thread.get()
1353
+
1354
+ :param run_uuid: (required)
1355
+ :type run_uuid: str
1356
+ :param key:
1357
+ :type key: str
1358
+ :param log_type:
1359
+ :type log_type: str
1360
+ :param async_req: Whether to execute the request asynchronously.
1361
+ :type async_req: bool, optional
1362
+ :param _request_timeout: timeout setting for this request.
1363
+ If one number provided, it will be total request
1364
+ timeout. It can also be a pair (tuple) of
1365
+ (connection, read) timeouts.
1366
+ :return: Returns the result object.
1367
+ If the method is called asynchronously,
1368
+ returns the request thread.
1369
+ :rtype: ListLatestRunLogsResponseDto
1370
+ """
1371
+ kwargs["_return_http_data_only"] = True
1372
+ if "_preload_content" in kwargs:
1373
+ message = "Error! Please call the list_latest_run_logs_get_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
1374
+ raise ValueError(message)
1375
+ return self.list_latest_run_logs_get_with_http_info(
1376
+ run_uuid, key, log_type, **kwargs
1377
+ ) # noqa: E501
1378
+
1379
+ @validate_arguments
1380
+ def list_latest_run_logs_get_with_http_info(
1381
+ self,
1382
+ run_uuid: StrictStr,
1383
+ key: Optional[StrictStr] = None,
1384
+ log_type: Optional[StrictStr] = None,
1385
+ **kwargs,
1386
+ ) -> ApiResponse: # noqa: E501
1387
+ """List Latest Run Logs # noqa: E501
1388
+
1389
+ This method makes a synchronous HTTP request by default. To make an
1390
+ asynchronous HTTP request, please pass async_req=True
1391
+
1392
+ >>> thread = api.list_latest_run_logs_get_with_http_info(run_uuid, key, log_type, async_req=True)
1393
+ >>> result = thread.get()
1394
+
1395
+ :param run_uuid: (required)
1396
+ :type run_uuid: str
1397
+ :param key:
1398
+ :type key: str
1399
+ :param log_type:
1400
+ :type log_type: str
1401
+ :param async_req: Whether to execute the request asynchronously.
1402
+ :type async_req: bool, optional
1403
+ :param _preload_content: if False, the ApiResponse.data will
1404
+ be set to none and raw_data will store the
1405
+ HTTP response body without reading/decoding.
1406
+ Default is True.
1407
+ :type _preload_content: bool, optional
1408
+ :param _return_http_data_only: response data instead of ApiResponse
1409
+ object with status code, headers, etc
1410
+ :type _return_http_data_only: bool, optional
1411
+ :param _request_timeout: timeout setting for this request. If one
1412
+ number provided, it will be total request
1413
+ timeout. It can also be a pair (tuple) of
1414
+ (connection, read) timeouts.
1415
+ :param _request_auth: set to override the auth_settings for an a single
1416
+ request; this effectively ignores the authentication
1417
+ in the spec for a single request.
1418
+ :type _request_auth: dict, optional
1419
+ :type _content_type: string, optional: force content-type for the request
1420
+ :return: Returns the result object.
1421
+ If the method is called asynchronously,
1422
+ returns the request thread.
1423
+ :rtype: tuple(ListLatestRunLogsResponseDto, status_code(int), headers(HTTPHeaderDict))
1424
+ """
1425
+
1426
+ _params = locals()
1427
+
1428
+ _all_params = ["run_uuid", "key", "log_type"]
1429
+ _all_params.extend(
1430
+ [
1431
+ "async_req",
1432
+ "_return_http_data_only",
1433
+ "_preload_content",
1434
+ "_request_timeout",
1435
+ "_request_auth",
1436
+ "_content_type",
1437
+ "_headers",
1438
+ ]
1439
+ )
1440
+
1441
+ # validate the arguments
1442
+ for _key, _val in _params["kwargs"].items():
1443
+ if _key not in _all_params:
1444
+ raise ApiTypeError(
1445
+ "Got an unexpected keyword argument '%s'"
1446
+ " to method list_latest_run_logs_get" % _key
1447
+ )
1448
+ _params[_key] = _val
1449
+ del _params["kwargs"]
1450
+
1451
+ _collection_formats = {}
1452
+
1453
+ # process the path parameters
1454
+ _path_params = {}
1455
+
1456
+ # process the query parameters
1457
+ _query_params = []
1458
+ if _params.get("run_uuid") is not None: # noqa: E501
1459
+ _query_params.append(("run_uuid", _params["run_uuid"]))
1460
+
1461
+ if _params.get("key") is not None: # noqa: E501
1462
+ _query_params.append(("key", _params["key"]))
1463
+
1464
+ if _params.get("log_type") is not None: # noqa: E501
1465
+ _query_params.append(("log_type", _params["log_type"]))
1466
+
1467
+ # process the header parameters
1468
+ _header_params = dict(_params.get("_headers", {}))
1469
+ # process the form parameters
1470
+ _form_params = []
1471
+ _files = {}
1472
+ # process the body parameter
1473
+ _body_params = None
1474
+ # set the HTTP header `Accept`
1475
+ _header_params["Accept"] = self.api_client.select_header_accept(
1476
+ ["application/json"]
1477
+ ) # noqa: E501
1478
+
1479
+ # authentication setting
1480
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
1481
+
1482
+ _response_types_map = {
1483
+ "200": "ListLatestRunLogsResponseDto",
1484
+ "422": "HTTPValidationError",
1485
+ }
1486
+
1487
+ return self.api_client.call_api(
1488
+ "/api/2.0/mlflow/runs/run-logs/list-latest",
1489
+ "GET",
1490
+ _path_params,
1491
+ _query_params,
1492
+ _header_params,
1493
+ body=_body_params,
1494
+ post_params=_form_params,
1495
+ files=_files,
1496
+ response_types_map=_response_types_map,
1497
+ auth_settings=_auth_settings,
1498
+ async_req=_params.get("async_req"),
1499
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
1500
+ _preload_content=_params.get("_preload_content", True),
1501
+ _request_timeout=_params.get("_request_timeout"),
1502
+ collection_formats=_collection_formats,
1503
+ _request_auth=_params.get("_request_auth"),
1504
+ )
1505
+
1506
+ @validate_arguments
1507
+ def list_run_logs_get(
1508
+ self,
1509
+ run_uuid: StrictStr,
1510
+ key: Optional[StrictStr] = None,
1511
+ log_type: Optional[StrictStr] = None,
1512
+ request_body: Optional[conlist(StrictInt)] = None,
1513
+ **kwargs,
1514
+ ) -> ListRunLogsResponseDto: # noqa: E501
1515
+ """List Run Logs # noqa: E501
1516
+
1517
+ List Run Logs # noqa: E501
1518
+ This method makes a synchronous HTTP request by default. To make an
1519
+ asynchronous HTTP request, please pass async_req=True
1520
+
1521
+ >>> thread = api.list_run_logs_get(run_uuid, key, log_type, request_body, async_req=True)
1522
+ >>> result = thread.get()
1523
+
1524
+ :param run_uuid: (required)
1525
+ :type run_uuid: str
1526
+ :param key:
1527
+ :type key: str
1528
+ :param log_type:
1529
+ :type log_type: str
1530
+ :param request_body:
1531
+ :type request_body: List[int]
1532
+ :param async_req: Whether to execute the request asynchronously.
1533
+ :type async_req: bool, optional
1534
+ :param _request_timeout: timeout setting for this request.
1535
+ If one number provided, it will be total request
1536
+ timeout. It can also be a pair (tuple) of
1537
+ (connection, read) timeouts.
1538
+ :return: Returns the result object.
1539
+ If the method is called asynchronously,
1540
+ returns the request thread.
1541
+ :rtype: ListRunLogsResponseDto
1542
+ """
1543
+ kwargs["_return_http_data_only"] = True
1544
+ if "_preload_content" in kwargs:
1545
+ message = "Error! Please call the list_run_logs_get_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
1546
+ raise ValueError(message)
1547
+ return self.list_run_logs_get_with_http_info(
1548
+ run_uuid, key, log_type, request_body, **kwargs
1549
+ ) # noqa: E501
1550
+
1551
+ @validate_arguments
1552
+ def list_run_logs_get_with_http_info(
1553
+ self,
1554
+ run_uuid: StrictStr,
1555
+ key: Optional[StrictStr] = None,
1556
+ log_type: Optional[StrictStr] = None,
1557
+ request_body: Optional[conlist(StrictInt)] = None,
1558
+ **kwargs,
1559
+ ) -> ApiResponse: # noqa: E501
1560
+ """List Run Logs # noqa: E501
1561
+
1562
+ List Run Logs # noqa: E501
1563
+ This method makes a synchronous HTTP request by default. To make an
1564
+ asynchronous HTTP request, please pass async_req=True
1565
+
1566
+ >>> thread = api.list_run_logs_get_with_http_info(run_uuid, key, log_type, request_body, async_req=True)
1567
+ >>> result = thread.get()
1568
+
1569
+ :param run_uuid: (required)
1570
+ :type run_uuid: str
1571
+ :param key:
1572
+ :type key: str
1573
+ :param log_type:
1574
+ :type log_type: str
1575
+ :param request_body:
1576
+ :type request_body: List[int]
1577
+ :param async_req: Whether to execute the request asynchronously.
1578
+ :type async_req: bool, optional
1579
+ :param _preload_content: if False, the ApiResponse.data will
1580
+ be set to none and raw_data will store the
1581
+ HTTP response body without reading/decoding.
1582
+ Default is True.
1583
+ :type _preload_content: bool, optional
1584
+ :param _return_http_data_only: response data instead of ApiResponse
1585
+ object with status code, headers, etc
1586
+ :type _return_http_data_only: bool, optional
1587
+ :param _request_timeout: timeout setting for this request. If one
1588
+ number provided, it will be total request
1589
+ timeout. It can also be a pair (tuple) of
1590
+ (connection, read) timeouts.
1591
+ :param _request_auth: set to override the auth_settings for an a single
1592
+ request; this effectively ignores the authentication
1593
+ in the spec for a single request.
1594
+ :type _request_auth: dict, optional
1595
+ :type _content_type: string, optional: force content-type for the request
1596
+ :return: Returns the result object.
1597
+ If the method is called asynchronously,
1598
+ returns the request thread.
1599
+ :rtype: tuple(ListRunLogsResponseDto, status_code(int), headers(HTTPHeaderDict))
1600
+ """
1601
+
1602
+ _params = locals()
1603
+
1604
+ _all_params = ["run_uuid", "key", "log_type", "request_body"]
1605
+ _all_params.extend(
1606
+ [
1607
+ "async_req",
1608
+ "_return_http_data_only",
1609
+ "_preload_content",
1610
+ "_request_timeout",
1611
+ "_request_auth",
1612
+ "_content_type",
1613
+ "_headers",
1614
+ ]
1615
+ )
1616
+
1617
+ # validate the arguments
1618
+ for _key, _val in _params["kwargs"].items():
1619
+ if _key not in _all_params:
1620
+ raise ApiTypeError(
1621
+ "Got an unexpected keyword argument '%s'"
1622
+ " to method list_run_logs_get" % _key
1623
+ )
1624
+ _params[_key] = _val
1625
+ del _params["kwargs"]
1626
+
1627
+ _collection_formats = {}
1628
+
1629
+ # process the path parameters
1630
+ _path_params = {}
1631
+
1632
+ # process the query parameters
1633
+ _query_params = []
1634
+ if _params.get("run_uuid") is not None: # noqa: E501
1635
+ _query_params.append(("run_uuid", _params["run_uuid"]))
1636
+
1637
+ if _params.get("key") is not None: # noqa: E501
1638
+ _query_params.append(("key", _params["key"]))
1639
+
1640
+ if _params.get("log_type") is not None: # noqa: E501
1641
+ _query_params.append(("log_type", _params["log_type"]))
1642
+
1643
+ # process the header parameters
1644
+ _header_params = dict(_params.get("_headers", {}))
1645
+ # process the form parameters
1646
+ _form_params = []
1647
+ _files = {}
1648
+ # process the body parameter
1649
+ _body_params = None
1650
+ if _params["request_body"] is not None:
1651
+ _body_params = _params["request_body"]
1652
+
1653
+ # set the HTTP header `Accept`
1654
+ _header_params["Accept"] = self.api_client.select_header_accept(
1655
+ ["application/json"]
1656
+ ) # noqa: E501
1657
+
1658
+ # set the HTTP header `Content-Type`
1659
+ _content_types_list = _params.get(
1660
+ "_content_type",
1661
+ self.api_client.select_header_content_type(["application/json"]),
1662
+ )
1663
+ if _content_types_list:
1664
+ _header_params["Content-Type"] = _content_types_list
1665
+
1666
+ # authentication setting
1667
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
1668
+
1669
+ _response_types_map = {
1670
+ "200": "ListRunLogsResponseDto",
1671
+ "422": "HTTPValidationError",
1672
+ }
1673
+
1674
+ return self.api_client.call_api(
1675
+ "/api/2.0/mlflow/runs/run-logs/list",
1676
+ "GET",
1677
+ _path_params,
1678
+ _query_params,
1679
+ _header_params,
1680
+ body=_body_params,
1681
+ post_params=_form_params,
1682
+ files=_files,
1683
+ response_types_map=_response_types_map,
1684
+ auth_settings=_auth_settings,
1685
+ async_req=_params.get("async_req"),
1686
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
1687
+ _preload_content=_params.get("_preload_content", True),
1688
+ _request_timeout=_params.get("_request_timeout"),
1689
+ collection_formats=_collection_formats,
1690
+ _request_auth=_params.get("_request_auth"),
1691
+ )
1692
+
1693
+ @validate_arguments
1694
+ def log_metric_post(
1695
+ self, log_metric_request_dto: LogMetricRequestDto, **kwargs
1696
+ ) -> object: # noqa: E501
1697
+ """Log Metric # noqa: E501
1698
+
1699
+ Log Metric # noqa: E501
1700
+ This method makes a synchronous HTTP request by default. To make an
1701
+ asynchronous HTTP request, please pass async_req=True
1702
+
1703
+ >>> thread = api.log_metric_post(log_metric_request_dto, async_req=True)
1704
+ >>> result = thread.get()
1705
+
1706
+ :param log_metric_request_dto: (required)
1707
+ :type log_metric_request_dto: LogMetricRequestDto
1708
+ :param async_req: Whether to execute the request asynchronously.
1709
+ :type async_req: bool, optional
1710
+ :param _request_timeout: timeout setting for this request.
1711
+ If one number provided, it will be total request
1712
+ timeout. It can also be a pair (tuple) of
1713
+ (connection, read) timeouts.
1714
+ :return: Returns the result object.
1715
+ If the method is called asynchronously,
1716
+ returns the request thread.
1717
+ :rtype: object
1718
+ """
1719
+ kwargs["_return_http_data_only"] = True
1720
+ if "_preload_content" in kwargs:
1721
+ message = "Error! Please call the log_metric_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
1722
+ raise ValueError(message)
1723
+ return self.log_metric_post_with_http_info(log_metric_request_dto, **kwargs) # noqa: E501
1724
+
1725
+ @validate_arguments
1726
+ def log_metric_post_with_http_info(
1727
+ self, log_metric_request_dto: LogMetricRequestDto, **kwargs
1728
+ ) -> ApiResponse: # noqa: E501
1729
+ """Log Metric # noqa: E501
1730
+
1731
+ Log Metric # noqa: E501
1732
+ This method makes a synchronous HTTP request by default. To make an
1733
+ asynchronous HTTP request, please pass async_req=True
1734
+
1735
+ >>> thread = api.log_metric_post_with_http_info(log_metric_request_dto, async_req=True)
1736
+ >>> result = thread.get()
1737
+
1738
+ :param log_metric_request_dto: (required)
1739
+ :type log_metric_request_dto: LogMetricRequestDto
1740
+ :param async_req: Whether to execute the request asynchronously.
1741
+ :type async_req: bool, optional
1742
+ :param _preload_content: if False, the ApiResponse.data will
1743
+ be set to none and raw_data will store the
1744
+ HTTP response body without reading/decoding.
1745
+ Default is True.
1746
+ :type _preload_content: bool, optional
1747
+ :param _return_http_data_only: response data instead of ApiResponse
1748
+ object with status code, headers, etc
1749
+ :type _return_http_data_only: bool, optional
1750
+ :param _request_timeout: timeout setting for this request. If one
1751
+ number provided, it will be total request
1752
+ timeout. It can also be a pair (tuple) of
1753
+ (connection, read) timeouts.
1754
+ :param _request_auth: set to override the auth_settings for an a single
1755
+ request; this effectively ignores the authentication
1756
+ in the spec for a single request.
1757
+ :type _request_auth: dict, optional
1758
+ :type _content_type: string, optional: force content-type for the request
1759
+ :return: Returns the result object.
1760
+ If the method is called asynchronously,
1761
+ returns the request thread.
1762
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
1763
+ """
1764
+
1765
+ _params = locals()
1766
+
1767
+ _all_params = ["log_metric_request_dto"]
1768
+ _all_params.extend(
1769
+ [
1770
+ "async_req",
1771
+ "_return_http_data_only",
1772
+ "_preload_content",
1773
+ "_request_timeout",
1774
+ "_request_auth",
1775
+ "_content_type",
1776
+ "_headers",
1777
+ ]
1778
+ )
1779
+
1780
+ # validate the arguments
1781
+ for _key, _val in _params["kwargs"].items():
1782
+ if _key not in _all_params:
1783
+ raise ApiTypeError(
1784
+ "Got an unexpected keyword argument '%s'"
1785
+ " to method log_metric_post" % _key
1786
+ )
1787
+ _params[_key] = _val
1788
+ del _params["kwargs"]
1789
+
1790
+ _collection_formats = {}
1791
+
1792
+ # process the path parameters
1793
+ _path_params = {}
1794
+
1795
+ # process the query parameters
1796
+ _query_params = []
1797
+ # process the header parameters
1798
+ _header_params = dict(_params.get("_headers", {}))
1799
+ # process the form parameters
1800
+ _form_params = []
1801
+ _files = {}
1802
+ # process the body parameter
1803
+ _body_params = None
1804
+ if _params["log_metric_request_dto"] is not None:
1805
+ _body_params = _params["log_metric_request_dto"]
1806
+
1807
+ # set the HTTP header `Accept`
1808
+ _header_params["Accept"] = self.api_client.select_header_accept(
1809
+ ["application/json"]
1810
+ ) # noqa: E501
1811
+
1812
+ # set the HTTP header `Content-Type`
1813
+ _content_types_list = _params.get(
1814
+ "_content_type",
1815
+ self.api_client.select_header_content_type(["application/json"]),
1816
+ )
1817
+ if _content_types_list:
1818
+ _header_params["Content-Type"] = _content_types_list
1819
+
1820
+ # authentication setting
1821
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
1822
+
1823
+ _response_types_map = {
1824
+ "200": "object",
1825
+ "422": "HTTPValidationError",
1826
+ }
1827
+
1828
+ return self.api_client.call_api(
1829
+ "/api/2.0/mlflow/runs/log-metric",
1830
+ "POST",
1831
+ _path_params,
1832
+ _query_params,
1833
+ _header_params,
1834
+ body=_body_params,
1835
+ post_params=_form_params,
1836
+ files=_files,
1837
+ response_types_map=_response_types_map,
1838
+ auth_settings=_auth_settings,
1839
+ async_req=_params.get("async_req"),
1840
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
1841
+ _preload_content=_params.get("_preload_content", True),
1842
+ _request_timeout=_params.get("_request_timeout"),
1843
+ collection_formats=_collection_formats,
1844
+ _request_auth=_params.get("_request_auth"),
1845
+ )
1846
+
1847
+ @validate_arguments
1848
+ def log_parameter_post(
1849
+ self, log_param_request_dto: LogParamRequestDto, **kwargs
1850
+ ) -> object: # noqa: E501
1851
+ """Log Parameter # noqa: E501
1852
+
1853
+ Log Param # noqa: E501
1854
+ This method makes a synchronous HTTP request by default. To make an
1855
+ asynchronous HTTP request, please pass async_req=True
1856
+
1857
+ >>> thread = api.log_parameter_post(log_param_request_dto, async_req=True)
1858
+ >>> result = thread.get()
1859
+
1860
+ :param log_param_request_dto: (required)
1861
+ :type log_param_request_dto: LogParamRequestDto
1862
+ :param async_req: Whether to execute the request asynchronously.
1863
+ :type async_req: bool, optional
1864
+ :param _request_timeout: timeout setting for this request.
1865
+ If one number provided, it will be total request
1866
+ timeout. It can also be a pair (tuple) of
1867
+ (connection, read) timeouts.
1868
+ :return: Returns the result object.
1869
+ If the method is called asynchronously,
1870
+ returns the request thread.
1871
+ :rtype: object
1872
+ """
1873
+ kwargs["_return_http_data_only"] = True
1874
+ if "_preload_content" in kwargs:
1875
+ message = "Error! Please call the log_parameter_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
1876
+ raise ValueError(message)
1877
+ return self.log_parameter_post_with_http_info(log_param_request_dto, **kwargs) # noqa: E501
1878
+
1879
+ @validate_arguments
1880
+ def log_parameter_post_with_http_info(
1881
+ self, log_param_request_dto: LogParamRequestDto, **kwargs
1882
+ ) -> ApiResponse: # noqa: E501
1883
+ """Log Parameter # noqa: E501
1884
+
1885
+ Log Param # noqa: E501
1886
+ This method makes a synchronous HTTP request by default. To make an
1887
+ asynchronous HTTP request, please pass async_req=True
1888
+
1889
+ >>> thread = api.log_parameter_post_with_http_info(log_param_request_dto, async_req=True)
1890
+ >>> result = thread.get()
1891
+
1892
+ :param log_param_request_dto: (required)
1893
+ :type log_param_request_dto: LogParamRequestDto
1894
+ :param async_req: Whether to execute the request asynchronously.
1895
+ :type async_req: bool, optional
1896
+ :param _preload_content: if False, the ApiResponse.data will
1897
+ be set to none and raw_data will store the
1898
+ HTTP response body without reading/decoding.
1899
+ Default is True.
1900
+ :type _preload_content: bool, optional
1901
+ :param _return_http_data_only: response data instead of ApiResponse
1902
+ object with status code, headers, etc
1903
+ :type _return_http_data_only: bool, optional
1904
+ :param _request_timeout: timeout setting for this request. If one
1905
+ number provided, it will be total request
1906
+ timeout. It can also be a pair (tuple) of
1907
+ (connection, read) timeouts.
1908
+ :param _request_auth: set to override the auth_settings for an a single
1909
+ request; this effectively ignores the authentication
1910
+ in the spec for a single request.
1911
+ :type _request_auth: dict, optional
1912
+ :type _content_type: string, optional: force content-type for the request
1913
+ :return: Returns the result object.
1914
+ If the method is called asynchronously,
1915
+ returns the request thread.
1916
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
1917
+ """
1918
+
1919
+ _params = locals()
1920
+
1921
+ _all_params = ["log_param_request_dto"]
1922
+ _all_params.extend(
1923
+ [
1924
+ "async_req",
1925
+ "_return_http_data_only",
1926
+ "_preload_content",
1927
+ "_request_timeout",
1928
+ "_request_auth",
1929
+ "_content_type",
1930
+ "_headers",
1931
+ ]
1932
+ )
1933
+
1934
+ # validate the arguments
1935
+ for _key, _val in _params["kwargs"].items():
1936
+ if _key not in _all_params:
1937
+ raise ApiTypeError(
1938
+ "Got an unexpected keyword argument '%s'"
1939
+ " to method log_parameter_post" % _key
1940
+ )
1941
+ _params[_key] = _val
1942
+ del _params["kwargs"]
1943
+
1944
+ _collection_formats = {}
1945
+
1946
+ # process the path parameters
1947
+ _path_params = {}
1948
+
1949
+ # process the query parameters
1950
+ _query_params = []
1951
+ # process the header parameters
1952
+ _header_params = dict(_params.get("_headers", {}))
1953
+ # process the form parameters
1954
+ _form_params = []
1955
+ _files = {}
1956
+ # process the body parameter
1957
+ _body_params = None
1958
+ if _params["log_param_request_dto"] is not None:
1959
+ _body_params = _params["log_param_request_dto"]
1960
+
1961
+ # set the HTTP header `Accept`
1962
+ _header_params["Accept"] = self.api_client.select_header_accept(
1963
+ ["application/json"]
1964
+ ) # noqa: E501
1965
+
1966
+ # set the HTTP header `Content-Type`
1967
+ _content_types_list = _params.get(
1968
+ "_content_type",
1969
+ self.api_client.select_header_content_type(["application/json"]),
1970
+ )
1971
+ if _content_types_list:
1972
+ _header_params["Content-Type"] = _content_types_list
1973
+
1974
+ # authentication setting
1975
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
1976
+
1977
+ _response_types_map = {
1978
+ "200": "object",
1979
+ "422": "HTTPValidationError",
1980
+ }
1981
+
1982
+ return self.api_client.call_api(
1983
+ "/api/2.0/mlflow/runs/log-parameter",
1984
+ "POST",
1985
+ _path_params,
1986
+ _query_params,
1987
+ _header_params,
1988
+ body=_body_params,
1989
+ post_params=_form_params,
1990
+ files=_files,
1991
+ response_types_map=_response_types_map,
1992
+ auth_settings=_auth_settings,
1993
+ async_req=_params.get("async_req"),
1994
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
1995
+ _preload_content=_params.get("_preload_content", True),
1996
+ _request_timeout=_params.get("_request_timeout"),
1997
+ collection_formats=_collection_formats,
1998
+ _request_auth=_params.get("_request_auth"),
1999
+ )
2000
+
2001
+ @validate_arguments
2002
+ def log_run_batch_post(
2003
+ self, log_batch_request_dto: LogBatchRequestDto, **kwargs
2004
+ ) -> object: # noqa: E501
2005
+ """Log Run Batch # noqa: E501
2006
+
2007
+ Log Batch # noqa: E501
2008
+ This method makes a synchronous HTTP request by default. To make an
2009
+ asynchronous HTTP request, please pass async_req=True
2010
+
2011
+ >>> thread = api.log_run_batch_post(log_batch_request_dto, async_req=True)
2012
+ >>> result = thread.get()
2013
+
2014
+ :param log_batch_request_dto: (required)
2015
+ :type log_batch_request_dto: LogBatchRequestDto
2016
+ :param async_req: Whether to execute the request asynchronously.
2017
+ :type async_req: bool, optional
2018
+ :param _request_timeout: timeout setting for this request.
2019
+ If one number provided, it will be total request
2020
+ timeout. It can also be a pair (tuple) of
2021
+ (connection, read) timeouts.
2022
+ :return: Returns the result object.
2023
+ If the method is called asynchronously,
2024
+ returns the request thread.
2025
+ :rtype: object
2026
+ """
2027
+ kwargs["_return_http_data_only"] = True
2028
+ if "_preload_content" in kwargs:
2029
+ message = "Error! Please call the log_run_batch_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
2030
+ raise ValueError(message)
2031
+ return self.log_run_batch_post_with_http_info(log_batch_request_dto, **kwargs) # noqa: E501
2032
+
2033
+ @validate_arguments
2034
+ def log_run_batch_post_with_http_info(
2035
+ self, log_batch_request_dto: LogBatchRequestDto, **kwargs
2036
+ ) -> ApiResponse: # noqa: E501
2037
+ """Log Run Batch # noqa: E501
2038
+
2039
+ Log Batch # noqa: E501
2040
+ This method makes a synchronous HTTP request by default. To make an
2041
+ asynchronous HTTP request, please pass async_req=True
2042
+
2043
+ >>> thread = api.log_run_batch_post_with_http_info(log_batch_request_dto, async_req=True)
2044
+ >>> result = thread.get()
2045
+
2046
+ :param log_batch_request_dto: (required)
2047
+ :type log_batch_request_dto: LogBatchRequestDto
2048
+ :param async_req: Whether to execute the request asynchronously.
2049
+ :type async_req: bool, optional
2050
+ :param _preload_content: if False, the ApiResponse.data will
2051
+ be set to none and raw_data will store the
2052
+ HTTP response body without reading/decoding.
2053
+ Default is True.
2054
+ :type _preload_content: bool, optional
2055
+ :param _return_http_data_only: response data instead of ApiResponse
2056
+ object with status code, headers, etc
2057
+ :type _return_http_data_only: bool, optional
2058
+ :param _request_timeout: timeout setting for this request. If one
2059
+ number provided, it will be total request
2060
+ timeout. It can also be a pair (tuple) of
2061
+ (connection, read) timeouts.
2062
+ :param _request_auth: set to override the auth_settings for an a single
2063
+ request; this effectively ignores the authentication
2064
+ in the spec for a single request.
2065
+ :type _request_auth: dict, optional
2066
+ :type _content_type: string, optional: force content-type for the request
2067
+ :return: Returns the result object.
2068
+ If the method is called asynchronously,
2069
+ returns the request thread.
2070
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
2071
+ """
2072
+
2073
+ _params = locals()
2074
+
2075
+ _all_params = ["log_batch_request_dto"]
2076
+ _all_params.extend(
2077
+ [
2078
+ "async_req",
2079
+ "_return_http_data_only",
2080
+ "_preload_content",
2081
+ "_request_timeout",
2082
+ "_request_auth",
2083
+ "_content_type",
2084
+ "_headers",
2085
+ ]
2086
+ )
2087
+
2088
+ # validate the arguments
2089
+ for _key, _val in _params["kwargs"].items():
2090
+ if _key not in _all_params:
2091
+ raise ApiTypeError(
2092
+ "Got an unexpected keyword argument '%s'"
2093
+ " to method log_run_batch_post" % _key
2094
+ )
2095
+ _params[_key] = _val
2096
+ del _params["kwargs"]
2097
+
2098
+ _collection_formats = {}
2099
+
2100
+ # process the path parameters
2101
+ _path_params = {}
2102
+
2103
+ # process the query parameters
2104
+ _query_params = []
2105
+ # process the header parameters
2106
+ _header_params = dict(_params.get("_headers", {}))
2107
+ # process the form parameters
2108
+ _form_params = []
2109
+ _files = {}
2110
+ # process the body parameter
2111
+ _body_params = None
2112
+ if _params["log_batch_request_dto"] is not None:
2113
+ _body_params = _params["log_batch_request_dto"]
2114
+
2115
+ # set the HTTP header `Accept`
2116
+ _header_params["Accept"] = self.api_client.select_header_accept(
2117
+ ["application/json"]
2118
+ ) # noqa: E501
2119
+
2120
+ # set the HTTP header `Content-Type`
2121
+ _content_types_list = _params.get(
2122
+ "_content_type",
2123
+ self.api_client.select_header_content_type(["application/json"]),
2124
+ )
2125
+ if _content_types_list:
2126
+ _header_params["Content-Type"] = _content_types_list
2127
+
2128
+ # authentication setting
2129
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
2130
+
2131
+ _response_types_map = {
2132
+ "200": "object",
2133
+ "422": "HTTPValidationError",
2134
+ }
2135
+
2136
+ return self.api_client.call_api(
2137
+ "/api/2.0/mlflow/runs/log-batch",
2138
+ "POST",
2139
+ _path_params,
2140
+ _query_params,
2141
+ _header_params,
2142
+ body=_body_params,
2143
+ post_params=_form_params,
2144
+ files=_files,
2145
+ response_types_map=_response_types_map,
2146
+ auth_settings=_auth_settings,
2147
+ async_req=_params.get("async_req"),
2148
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
2149
+ _preload_content=_params.get("_preload_content", True),
2150
+ _request_timeout=_params.get("_request_timeout"),
2151
+ collection_formats=_collection_formats,
2152
+ _request_auth=_params.get("_request_auth"),
2153
+ )
2154
+
2155
+ @validate_arguments
2156
+ def restore_run_post(
2157
+ self, restore_run_request_dto: RestoreRunRequestDto, **kwargs
2158
+ ) -> object: # noqa: E501
2159
+ """Restore Run # noqa: E501
2160
+
2161
+ This method makes a synchronous HTTP request by default. To make an
2162
+ asynchronous HTTP request, please pass async_req=True
2163
+
2164
+ >>> thread = api.restore_run_post(restore_run_request_dto, async_req=True)
2165
+ >>> result = thread.get()
2166
+
2167
+ :param restore_run_request_dto: (required)
2168
+ :type restore_run_request_dto: RestoreRunRequestDto
2169
+ :param async_req: Whether to execute the request asynchronously.
2170
+ :type async_req: bool, optional
2171
+ :param _request_timeout: timeout setting for this request.
2172
+ If one number provided, it will be total request
2173
+ timeout. It can also be a pair (tuple) of
2174
+ (connection, read) timeouts.
2175
+ :return: Returns the result object.
2176
+ If the method is called asynchronously,
2177
+ returns the request thread.
2178
+ :rtype: object
2179
+ """
2180
+ kwargs["_return_http_data_only"] = True
2181
+ if "_preload_content" in kwargs:
2182
+ message = "Error! Please call the restore_run_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
2183
+ raise ValueError(message)
2184
+ return self.restore_run_post_with_http_info(restore_run_request_dto, **kwargs) # noqa: E501
2185
+
2186
+ @validate_arguments
2187
+ def restore_run_post_with_http_info(
2188
+ self, restore_run_request_dto: RestoreRunRequestDto, **kwargs
2189
+ ) -> ApiResponse: # noqa: E501
2190
+ """Restore Run # noqa: E501
2191
+
2192
+ This method makes a synchronous HTTP request by default. To make an
2193
+ asynchronous HTTP request, please pass async_req=True
2194
+
2195
+ >>> thread = api.restore_run_post_with_http_info(restore_run_request_dto, async_req=True)
2196
+ >>> result = thread.get()
2197
+
2198
+ :param restore_run_request_dto: (required)
2199
+ :type restore_run_request_dto: RestoreRunRequestDto
2200
+ :param async_req: Whether to execute the request asynchronously.
2201
+ :type async_req: bool, optional
2202
+ :param _preload_content: if False, the ApiResponse.data will
2203
+ be set to none and raw_data will store the
2204
+ HTTP response body without reading/decoding.
2205
+ Default is True.
2206
+ :type _preload_content: bool, optional
2207
+ :param _return_http_data_only: response data instead of ApiResponse
2208
+ object with status code, headers, etc
2209
+ :type _return_http_data_only: bool, optional
2210
+ :param _request_timeout: timeout setting for this request. If one
2211
+ number provided, it will be total request
2212
+ timeout. It can also be a pair (tuple) of
2213
+ (connection, read) timeouts.
2214
+ :param _request_auth: set to override the auth_settings for an a single
2215
+ request; this effectively ignores the authentication
2216
+ in the spec for a single request.
2217
+ :type _request_auth: dict, optional
2218
+ :type _content_type: string, optional: force content-type for the request
2219
+ :return: Returns the result object.
2220
+ If the method is called asynchronously,
2221
+ returns the request thread.
2222
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
2223
+ """
2224
+
2225
+ _params = locals()
2226
+
2227
+ _all_params = ["restore_run_request_dto"]
2228
+ _all_params.extend(
2229
+ [
2230
+ "async_req",
2231
+ "_return_http_data_only",
2232
+ "_preload_content",
2233
+ "_request_timeout",
2234
+ "_request_auth",
2235
+ "_content_type",
2236
+ "_headers",
2237
+ ]
2238
+ )
2239
+
2240
+ # validate the arguments
2241
+ for _key, _val in _params["kwargs"].items():
2242
+ if _key not in _all_params:
2243
+ raise ApiTypeError(
2244
+ "Got an unexpected keyword argument '%s'"
2245
+ " to method restore_run_post" % _key
2246
+ )
2247
+ _params[_key] = _val
2248
+ del _params["kwargs"]
2249
+
2250
+ _collection_formats = {}
2251
+
2252
+ # process the path parameters
2253
+ _path_params = {}
2254
+
2255
+ # process the query parameters
2256
+ _query_params = []
2257
+ # process the header parameters
2258
+ _header_params = dict(_params.get("_headers", {}))
2259
+ # process the form parameters
2260
+ _form_params = []
2261
+ _files = {}
2262
+ # process the body parameter
2263
+ _body_params = None
2264
+ if _params["restore_run_request_dto"] is not None:
2265
+ _body_params = _params["restore_run_request_dto"]
2266
+
2267
+ # set the HTTP header `Accept`
2268
+ _header_params["Accept"] = self.api_client.select_header_accept(
2269
+ ["application/json"]
2270
+ ) # noqa: E501
2271
+
2272
+ # set the HTTP header `Content-Type`
2273
+ _content_types_list = _params.get(
2274
+ "_content_type",
2275
+ self.api_client.select_header_content_type(["application/json"]),
2276
+ )
2277
+ if _content_types_list:
2278
+ _header_params["Content-Type"] = _content_types_list
2279
+
2280
+ # authentication setting
2281
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
2282
+
2283
+ _response_types_map = {
2284
+ "200": "object",
2285
+ "422": "HTTPValidationError",
2286
+ }
2287
+
2288
+ return self.api_client.call_api(
2289
+ "/api/2.0/mlflow/runs/restore",
2290
+ "POST",
2291
+ _path_params,
2292
+ _query_params,
2293
+ _header_params,
2294
+ body=_body_params,
2295
+ post_params=_form_params,
2296
+ files=_files,
2297
+ response_types_map=_response_types_map,
2298
+ auth_settings=_auth_settings,
2299
+ async_req=_params.get("async_req"),
2300
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
2301
+ _preload_content=_params.get("_preload_content", True),
2302
+ _request_timeout=_params.get("_request_timeout"),
2303
+ collection_formats=_collection_formats,
2304
+ _request_auth=_params.get("_request_auth"),
2305
+ )
2306
+
2307
+ @validate_arguments
2308
+ def run_logs_post(
2309
+ self, store_run_logs_request_dto: StoreRunLogsRequestDto, **kwargs
2310
+ ) -> object: # noqa: E501
2311
+ """Run Logs # noqa: E501
2312
+
2313
+ Store Run Logs # noqa: E501
2314
+ This method makes a synchronous HTTP request by default. To make an
2315
+ asynchronous HTTP request, please pass async_req=True
2316
+
2317
+ >>> thread = api.run_logs_post(store_run_logs_request_dto, async_req=True)
2318
+ >>> result = thread.get()
2319
+
2320
+ :param store_run_logs_request_dto: (required)
2321
+ :type store_run_logs_request_dto: StoreRunLogsRequestDto
2322
+ :param async_req: Whether to execute the request asynchronously.
2323
+ :type async_req: bool, optional
2324
+ :param _request_timeout: timeout setting for this request.
2325
+ If one number provided, it will be total request
2326
+ timeout. It can also be a pair (tuple) of
2327
+ (connection, read) timeouts.
2328
+ :return: Returns the result object.
2329
+ If the method is called asynchronously,
2330
+ returns the request thread.
2331
+ :rtype: object
2332
+ """
2333
+ kwargs["_return_http_data_only"] = True
2334
+ if "_preload_content" in kwargs:
2335
+ message = "Error! Please call the run_logs_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
2336
+ raise ValueError(message)
2337
+ return self.run_logs_post_with_http_info(store_run_logs_request_dto, **kwargs) # noqa: E501
2338
+
2339
+ @validate_arguments
2340
+ def run_logs_post_with_http_info(
2341
+ self, store_run_logs_request_dto: StoreRunLogsRequestDto, **kwargs
2342
+ ) -> ApiResponse: # noqa: E501
2343
+ """Run Logs # noqa: E501
2344
+
2345
+ Store Run Logs # noqa: E501
2346
+ This method makes a synchronous HTTP request by default. To make an
2347
+ asynchronous HTTP request, please pass async_req=True
2348
+
2349
+ >>> thread = api.run_logs_post_with_http_info(store_run_logs_request_dto, async_req=True)
2350
+ >>> result = thread.get()
2351
+
2352
+ :param store_run_logs_request_dto: (required)
2353
+ :type store_run_logs_request_dto: StoreRunLogsRequestDto
2354
+ :param async_req: Whether to execute the request asynchronously.
2355
+ :type async_req: bool, optional
2356
+ :param _preload_content: if False, the ApiResponse.data will
2357
+ be set to none and raw_data will store the
2358
+ HTTP response body without reading/decoding.
2359
+ Default is True.
2360
+ :type _preload_content: bool, optional
2361
+ :param _return_http_data_only: response data instead of ApiResponse
2362
+ object with status code, headers, etc
2363
+ :type _return_http_data_only: bool, optional
2364
+ :param _request_timeout: timeout setting for this request. If one
2365
+ number provided, it will be total request
2366
+ timeout. It can also be a pair (tuple) of
2367
+ (connection, read) timeouts.
2368
+ :param _request_auth: set to override the auth_settings for an a single
2369
+ request; this effectively ignores the authentication
2370
+ in the spec for a single request.
2371
+ :type _request_auth: dict, optional
2372
+ :type _content_type: string, optional: force content-type for the request
2373
+ :return: Returns the result object.
2374
+ If the method is called asynchronously,
2375
+ returns the request thread.
2376
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
2377
+ """
2378
+
2379
+ _params = locals()
2380
+
2381
+ _all_params = ["store_run_logs_request_dto"]
2382
+ _all_params.extend(
2383
+ [
2384
+ "async_req",
2385
+ "_return_http_data_only",
2386
+ "_preload_content",
2387
+ "_request_timeout",
2388
+ "_request_auth",
2389
+ "_content_type",
2390
+ "_headers",
2391
+ ]
2392
+ )
2393
+
2394
+ # validate the arguments
2395
+ for _key, _val in _params["kwargs"].items():
2396
+ if _key not in _all_params:
2397
+ raise ApiTypeError(
2398
+ "Got an unexpected keyword argument '%s'"
2399
+ " to method run_logs_post" % _key
2400
+ )
2401
+ _params[_key] = _val
2402
+ del _params["kwargs"]
2403
+
2404
+ _collection_formats = {}
2405
+
2406
+ # process the path parameters
2407
+ _path_params = {}
2408
+
2409
+ # process the query parameters
2410
+ _query_params = []
2411
+ # process the header parameters
2412
+ _header_params = dict(_params.get("_headers", {}))
2413
+ # process the form parameters
2414
+ _form_params = []
2415
+ _files = {}
2416
+ # process the body parameter
2417
+ _body_params = None
2418
+ if _params["store_run_logs_request_dto"] is not None:
2419
+ _body_params = _params["store_run_logs_request_dto"]
2420
+
2421
+ # set the HTTP header `Accept`
2422
+ _header_params["Accept"] = self.api_client.select_header_accept(
2423
+ ["application/json"]
2424
+ ) # noqa: E501
2425
+
2426
+ # set the HTTP header `Content-Type`
2427
+ _content_types_list = _params.get(
2428
+ "_content_type",
2429
+ self.api_client.select_header_content_type(["application/json"]),
2430
+ )
2431
+ if _content_types_list:
2432
+ _header_params["Content-Type"] = _content_types_list
2433
+
2434
+ # authentication setting
2435
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
2436
+
2437
+ _response_types_map = {
2438
+ "200": "object",
2439
+ "422": "HTTPValidationError",
2440
+ }
2441
+
2442
+ return self.api_client.call_api(
2443
+ "/api/2.0/mlflow/runs/run-logs",
2444
+ "POST",
2445
+ _path_params,
2446
+ _query_params,
2447
+ _header_params,
2448
+ body=_body_params,
2449
+ post_params=_form_params,
2450
+ files=_files,
2451
+ response_types_map=_response_types_map,
2452
+ auth_settings=_auth_settings,
2453
+ async_req=_params.get("async_req"),
2454
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
2455
+ _preload_content=_params.get("_preload_content", True),
2456
+ _request_timeout=_params.get("_request_timeout"),
2457
+ collection_formats=_collection_formats,
2458
+ _request_auth=_params.get("_request_auth"),
2459
+ )
2460
+
2461
+ @validate_arguments
2462
+ def search_runs_post(
2463
+ self, search_runs_request_dto: SearchRunsRequestDto, **kwargs
2464
+ ) -> SearchRunsResponseDto: # noqa: E501
2465
+ """Search Runs # noqa: E501
2466
+
2467
+ This method makes a synchronous HTTP request by default. To make an
2468
+ asynchronous HTTP request, please pass async_req=True
2469
+
2470
+ >>> thread = api.search_runs_post(search_runs_request_dto, async_req=True)
2471
+ >>> result = thread.get()
2472
+
2473
+ :param search_runs_request_dto: (required)
2474
+ :type search_runs_request_dto: SearchRunsRequestDto
2475
+ :param async_req: Whether to execute the request asynchronously.
2476
+ :type async_req: bool, optional
2477
+ :param _request_timeout: timeout setting for this request.
2478
+ If one number provided, it will be total request
2479
+ timeout. It can also be a pair (tuple) of
2480
+ (connection, read) timeouts.
2481
+ :return: Returns the result object.
2482
+ If the method is called asynchronously,
2483
+ returns the request thread.
2484
+ :rtype: SearchRunsResponseDto
2485
+ """
2486
+ kwargs["_return_http_data_only"] = True
2487
+ if "_preload_content" in kwargs:
2488
+ message = "Error! Please call the search_runs_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
2489
+ raise ValueError(message)
2490
+ return self.search_runs_post_with_http_info(search_runs_request_dto, **kwargs) # noqa: E501
2491
+
2492
+ @validate_arguments
2493
+ def search_runs_post_with_http_info(
2494
+ self, search_runs_request_dto: SearchRunsRequestDto, **kwargs
2495
+ ) -> ApiResponse: # noqa: E501
2496
+ """Search Runs # noqa: E501
2497
+
2498
+ This method makes a synchronous HTTP request by default. To make an
2499
+ asynchronous HTTP request, please pass async_req=True
2500
+
2501
+ >>> thread = api.search_runs_post_with_http_info(search_runs_request_dto, async_req=True)
2502
+ >>> result = thread.get()
2503
+
2504
+ :param search_runs_request_dto: (required)
2505
+ :type search_runs_request_dto: SearchRunsRequestDto
2506
+ :param async_req: Whether to execute the request asynchronously.
2507
+ :type async_req: bool, optional
2508
+ :param _preload_content: if False, the ApiResponse.data will
2509
+ be set to none and raw_data will store the
2510
+ HTTP response body without reading/decoding.
2511
+ Default is True.
2512
+ :type _preload_content: bool, optional
2513
+ :param _return_http_data_only: response data instead of ApiResponse
2514
+ object with status code, headers, etc
2515
+ :type _return_http_data_only: bool, optional
2516
+ :param _request_timeout: timeout setting for this request. If one
2517
+ number provided, it will be total request
2518
+ timeout. It can also be a pair (tuple) of
2519
+ (connection, read) timeouts.
2520
+ :param _request_auth: set to override the auth_settings for an a single
2521
+ request; this effectively ignores the authentication
2522
+ in the spec for a single request.
2523
+ :type _request_auth: dict, optional
2524
+ :type _content_type: string, optional: force content-type for the request
2525
+ :return: Returns the result object.
2526
+ If the method is called asynchronously,
2527
+ returns the request thread.
2528
+ :rtype: tuple(SearchRunsResponseDto, status_code(int), headers(HTTPHeaderDict))
2529
+ """
2530
+
2531
+ _params = locals()
2532
+
2533
+ _all_params = ["search_runs_request_dto"]
2534
+ _all_params.extend(
2535
+ [
2536
+ "async_req",
2537
+ "_return_http_data_only",
2538
+ "_preload_content",
2539
+ "_request_timeout",
2540
+ "_request_auth",
2541
+ "_content_type",
2542
+ "_headers",
2543
+ ]
2544
+ )
2545
+
2546
+ # validate the arguments
2547
+ for _key, _val in _params["kwargs"].items():
2548
+ if _key not in _all_params:
2549
+ raise ApiTypeError(
2550
+ "Got an unexpected keyword argument '%s'"
2551
+ " to method search_runs_post" % _key
2552
+ )
2553
+ _params[_key] = _val
2554
+ del _params["kwargs"]
2555
+
2556
+ _collection_formats = {}
2557
+
2558
+ # process the path parameters
2559
+ _path_params = {}
2560
+
2561
+ # process the query parameters
2562
+ _query_params = []
2563
+ # process the header parameters
2564
+ _header_params = dict(_params.get("_headers", {}))
2565
+ # process the form parameters
2566
+ _form_params = []
2567
+ _files = {}
2568
+ # process the body parameter
2569
+ _body_params = None
2570
+ if _params["search_runs_request_dto"] is not None:
2571
+ _body_params = _params["search_runs_request_dto"]
2572
+
2573
+ # set the HTTP header `Accept`
2574
+ _header_params["Accept"] = self.api_client.select_header_accept(
2575
+ ["application/json"]
2576
+ ) # noqa: E501
2577
+
2578
+ # set the HTTP header `Content-Type`
2579
+ _content_types_list = _params.get(
2580
+ "_content_type",
2581
+ self.api_client.select_header_content_type(["application/json"]),
2582
+ )
2583
+ if _content_types_list:
2584
+ _header_params["Content-Type"] = _content_types_list
2585
+
2586
+ # authentication setting
2587
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
2588
+
2589
+ _response_types_map = {
2590
+ "200": "SearchRunsResponseDto",
2591
+ "422": "HTTPValidationError",
2592
+ }
2593
+
2594
+ return self.api_client.call_api(
2595
+ "/api/2.0/mlflow/runs/search",
2596
+ "POST",
2597
+ _path_params,
2598
+ _query_params,
2599
+ _header_params,
2600
+ body=_body_params,
2601
+ post_params=_form_params,
2602
+ files=_files,
2603
+ response_types_map=_response_types_map,
2604
+ auth_settings=_auth_settings,
2605
+ async_req=_params.get("async_req"),
2606
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
2607
+ _preload_content=_params.get("_preload_content", True),
2608
+ _request_timeout=_params.get("_request_timeout"),
2609
+ collection_formats=_collection_formats,
2610
+ _request_auth=_params.get("_request_auth"),
2611
+ )
2612
+
2613
+ @validate_arguments
2614
+ def set_tag_request_post(
2615
+ self, set_tag_request_dto: SetTagRequestDto, **kwargs
2616
+ ) -> object: # noqa: E501
2617
+ """Set Tag Request # noqa: E501
2618
+
2619
+ Set Tag # noqa: E501
2620
+ This method makes a synchronous HTTP request by default. To make an
2621
+ asynchronous HTTP request, please pass async_req=True
2622
+
2623
+ >>> thread = api.set_tag_request_post(set_tag_request_dto, async_req=True)
2624
+ >>> result = thread.get()
2625
+
2626
+ :param set_tag_request_dto: (required)
2627
+ :type set_tag_request_dto: SetTagRequestDto
2628
+ :param async_req: Whether to execute the request asynchronously.
2629
+ :type async_req: bool, optional
2630
+ :param _request_timeout: timeout setting for this request.
2631
+ If one number provided, it will be total request
2632
+ timeout. It can also be a pair (tuple) of
2633
+ (connection, read) timeouts.
2634
+ :return: Returns the result object.
2635
+ If the method is called asynchronously,
2636
+ returns the request thread.
2637
+ :rtype: object
2638
+ """
2639
+ kwargs["_return_http_data_only"] = True
2640
+ if "_preload_content" in kwargs:
2641
+ message = "Error! Please call the set_tag_request_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
2642
+ raise ValueError(message)
2643
+ return self.set_tag_request_post_with_http_info(set_tag_request_dto, **kwargs) # noqa: E501
2644
+
2645
+ @validate_arguments
2646
+ def set_tag_request_post_with_http_info(
2647
+ self, set_tag_request_dto: SetTagRequestDto, **kwargs
2648
+ ) -> ApiResponse: # noqa: E501
2649
+ """Set Tag Request # noqa: E501
2650
+
2651
+ Set Tag # noqa: E501
2652
+ This method makes a synchronous HTTP request by default. To make an
2653
+ asynchronous HTTP request, please pass async_req=True
2654
+
2655
+ >>> thread = api.set_tag_request_post_with_http_info(set_tag_request_dto, async_req=True)
2656
+ >>> result = thread.get()
2657
+
2658
+ :param set_tag_request_dto: (required)
2659
+ :type set_tag_request_dto: SetTagRequestDto
2660
+ :param async_req: Whether to execute the request asynchronously.
2661
+ :type async_req: bool, optional
2662
+ :param _preload_content: if False, the ApiResponse.data will
2663
+ be set to none and raw_data will store the
2664
+ HTTP response body without reading/decoding.
2665
+ Default is True.
2666
+ :type _preload_content: bool, optional
2667
+ :param _return_http_data_only: response data instead of ApiResponse
2668
+ object with status code, headers, etc
2669
+ :type _return_http_data_only: bool, optional
2670
+ :param _request_timeout: timeout setting for this request. If one
2671
+ number provided, it will be total request
2672
+ timeout. It can also be a pair (tuple) of
2673
+ (connection, read) timeouts.
2674
+ :param _request_auth: set to override the auth_settings for an a single
2675
+ request; this effectively ignores the authentication
2676
+ in the spec for a single request.
2677
+ :type _request_auth: dict, optional
2678
+ :type _content_type: string, optional: force content-type for the request
2679
+ :return: Returns the result object.
2680
+ If the method is called asynchronously,
2681
+ returns the request thread.
2682
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
2683
+ """
2684
+
2685
+ _params = locals()
2686
+
2687
+ _all_params = ["set_tag_request_dto"]
2688
+ _all_params.extend(
2689
+ [
2690
+ "async_req",
2691
+ "_return_http_data_only",
2692
+ "_preload_content",
2693
+ "_request_timeout",
2694
+ "_request_auth",
2695
+ "_content_type",
2696
+ "_headers",
2697
+ ]
2698
+ )
2699
+
2700
+ # validate the arguments
2701
+ for _key, _val in _params["kwargs"].items():
2702
+ if _key not in _all_params:
2703
+ raise ApiTypeError(
2704
+ "Got an unexpected keyword argument '%s'"
2705
+ " to method set_tag_request_post" % _key
2706
+ )
2707
+ _params[_key] = _val
2708
+ del _params["kwargs"]
2709
+
2710
+ _collection_formats = {}
2711
+
2712
+ # process the path parameters
2713
+ _path_params = {}
2714
+
2715
+ # process the query parameters
2716
+ _query_params = []
2717
+ # process the header parameters
2718
+ _header_params = dict(_params.get("_headers", {}))
2719
+ # process the form parameters
2720
+ _form_params = []
2721
+ _files = {}
2722
+ # process the body parameter
2723
+ _body_params = None
2724
+ if _params["set_tag_request_dto"] is not None:
2725
+ _body_params = _params["set_tag_request_dto"]
2726
+
2727
+ # set the HTTP header `Accept`
2728
+ _header_params["Accept"] = self.api_client.select_header_accept(
2729
+ ["application/json"]
2730
+ ) # noqa: E501
2731
+
2732
+ # set the HTTP header `Content-Type`
2733
+ _content_types_list = _params.get(
2734
+ "_content_type",
2735
+ self.api_client.select_header_content_type(["application/json"]),
2736
+ )
2737
+ if _content_types_list:
2738
+ _header_params["Content-Type"] = _content_types_list
2739
+
2740
+ # authentication setting
2741
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
2742
+
2743
+ _response_types_map = {
2744
+ "200": "object",
2745
+ "422": "HTTPValidationError",
2746
+ }
2747
+
2748
+ return self.api_client.call_api(
2749
+ "/api/2.0/mlflow/runs/set-tag",
2750
+ "POST",
2751
+ _path_params,
2752
+ _query_params,
2753
+ _header_params,
2754
+ body=_body_params,
2755
+ post_params=_form_params,
2756
+ files=_files,
2757
+ response_types_map=_response_types_map,
2758
+ auth_settings=_auth_settings,
2759
+ async_req=_params.get("async_req"),
2760
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
2761
+ _preload_content=_params.get("_preload_content", True),
2762
+ _request_timeout=_params.get("_request_timeout"),
2763
+ collection_formats=_collection_formats,
2764
+ _request_auth=_params.get("_request_auth"),
2765
+ )
2766
+
2767
+ @validate_arguments
2768
+ def update_run_post(
2769
+ self, update_run_request_dto: UpdateRunRequestDto, **kwargs
2770
+ ) -> UpdateRunResponseDto: # noqa: E501
2771
+ """Update Run # noqa: E501
2772
+
2773
+ Update Run # noqa: E501
2774
+ This method makes a synchronous HTTP request by default. To make an
2775
+ asynchronous HTTP request, please pass async_req=True
2776
+
2777
+ >>> thread = api.update_run_post(update_run_request_dto, async_req=True)
2778
+ >>> result = thread.get()
2779
+
2780
+ :param update_run_request_dto: (required)
2781
+ :type update_run_request_dto: UpdateRunRequestDto
2782
+ :param async_req: Whether to execute the request asynchronously.
2783
+ :type async_req: bool, optional
2784
+ :param _request_timeout: timeout setting for this request.
2785
+ If one number provided, it will be total request
2786
+ timeout. It can also be a pair (tuple) of
2787
+ (connection, read) timeouts.
2788
+ :return: Returns the result object.
2789
+ If the method is called asynchronously,
2790
+ returns the request thread.
2791
+ :rtype: UpdateRunResponseDto
2792
+ """
2793
+ kwargs["_return_http_data_only"] = True
2794
+ if "_preload_content" in kwargs:
2795
+ message = "Error! Please call the update_run_post_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
2796
+ raise ValueError(message)
2797
+ return self.update_run_post_with_http_info(update_run_request_dto, **kwargs) # noqa: E501
2798
+
2799
+ @validate_arguments
2800
+ def update_run_post_with_http_info(
2801
+ self, update_run_request_dto: UpdateRunRequestDto, **kwargs
2802
+ ) -> ApiResponse: # noqa: E501
2803
+ """Update Run # noqa: E501
2804
+
2805
+ Update Run # noqa: E501
2806
+ This method makes a synchronous HTTP request by default. To make an
2807
+ asynchronous HTTP request, please pass async_req=True
2808
+
2809
+ >>> thread = api.update_run_post_with_http_info(update_run_request_dto, async_req=True)
2810
+ >>> result = thread.get()
2811
+
2812
+ :param update_run_request_dto: (required)
2813
+ :type update_run_request_dto: UpdateRunRequestDto
2814
+ :param async_req: Whether to execute the request asynchronously.
2815
+ :type async_req: bool, optional
2816
+ :param _preload_content: if False, the ApiResponse.data will
2817
+ be set to none and raw_data will store the
2818
+ HTTP response body without reading/decoding.
2819
+ Default is True.
2820
+ :type _preload_content: bool, optional
2821
+ :param _return_http_data_only: response data instead of ApiResponse
2822
+ object with status code, headers, etc
2823
+ :type _return_http_data_only: bool, optional
2824
+ :param _request_timeout: timeout setting for this request. If one
2825
+ number provided, it will be total request
2826
+ timeout. It can also be a pair (tuple) of
2827
+ (connection, read) timeouts.
2828
+ :param _request_auth: set to override the auth_settings for an a single
2829
+ request; this effectively ignores the authentication
2830
+ in the spec for a single request.
2831
+ :type _request_auth: dict, optional
2832
+ :type _content_type: string, optional: force content-type for the request
2833
+ :return: Returns the result object.
2834
+ If the method is called asynchronously,
2835
+ returns the request thread.
2836
+ :rtype: tuple(UpdateRunResponseDto, status_code(int), headers(HTTPHeaderDict))
2837
+ """
2838
+
2839
+ _params = locals()
2840
+
2841
+ _all_params = ["update_run_request_dto"]
2842
+ _all_params.extend(
2843
+ [
2844
+ "async_req",
2845
+ "_return_http_data_only",
2846
+ "_preload_content",
2847
+ "_request_timeout",
2848
+ "_request_auth",
2849
+ "_content_type",
2850
+ "_headers",
2851
+ ]
2852
+ )
2853
+
2854
+ # validate the arguments
2855
+ for _key, _val in _params["kwargs"].items():
2856
+ if _key not in _all_params:
2857
+ raise ApiTypeError(
2858
+ "Got an unexpected keyword argument '%s'"
2859
+ " to method update_run_post" % _key
2860
+ )
2861
+ _params[_key] = _val
2862
+ del _params["kwargs"]
2863
+
2864
+ _collection_formats = {}
2865
+
2866
+ # process the path parameters
2867
+ _path_params = {}
2868
+
2869
+ # process the query parameters
2870
+ _query_params = []
2871
+ # process the header parameters
2872
+ _header_params = dict(_params.get("_headers", {}))
2873
+ # process the form parameters
2874
+ _form_params = []
2875
+ _files = {}
2876
+ # process the body parameter
2877
+ _body_params = None
2878
+ if _params["update_run_request_dto"] is not None:
2879
+ _body_params = _params["update_run_request_dto"]
2880
+
2881
+ # set the HTTP header `Accept`
2882
+ _header_params["Accept"] = self.api_client.select_header_accept(
2883
+ ["application/json"]
2884
+ ) # noqa: E501
2885
+
2886
+ # set the HTTP header `Content-Type`
2887
+ _content_types_list = _params.get(
2888
+ "_content_type",
2889
+ self.api_client.select_header_content_type(["application/json"]),
2890
+ )
2891
+ if _content_types_list:
2892
+ _header_params["Content-Type"] = _content_types_list
2893
+
2894
+ # authentication setting
2895
+ _auth_settings = ["HTTPBearer", "APIKeyCookie"] # noqa: E501
2896
+
2897
+ _response_types_map = {
2898
+ "200": "UpdateRunResponseDto",
2899
+ "422": "HTTPValidationError",
2900
+ }
2901
+
2902
+ return self.api_client.call_api(
2903
+ "/api/2.0/mlflow/runs/update",
2904
+ "POST",
2905
+ _path_params,
2906
+ _query_params,
2907
+ _header_params,
2908
+ body=_body_params,
2909
+ post_params=_form_params,
2910
+ files=_files,
2911
+ response_types_map=_response_types_map,
2912
+ auth_settings=_auth_settings,
2913
+ async_req=_params.get("async_req"),
2914
+ _return_http_data_only=_params.get("_return_http_data_only"), # noqa: E501
2915
+ _preload_content=_params.get("_preload_content", True),
2916
+ _request_timeout=_params.get("_request_timeout"),
2917
+ collection_formats=_collection_formats,
2918
+ _request_auth=_params.get("_request_auth"),
2919
+ )