rapidata 2.35.3__py3-none-any.whl → 2.36.1__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 rapidata might be problematic. Click here for more details.

Files changed (58) hide show
  1. rapidata/__init__.py +1 -1
  2. rapidata/api_client/__init__.py +25 -4
  3. rapidata/api_client/api/__init__.py +1 -0
  4. rapidata/api_client/api/benchmark_api.py +294 -0
  5. rapidata/api_client/api/campaign_api.py +268 -0
  6. rapidata/api_client/api/customer_rapid_api.py +247 -0
  7. rapidata/api_client/api/leaderboard_api.py +295 -6
  8. rapidata/api_client/api/pipeline_api.py +0 -873
  9. rapidata/api_client/api/sample_api.py +299 -0
  10. rapidata/api_client/api/validation_set_api.py +537 -312
  11. rapidata/api_client/models/__init__.py +24 -4
  12. rapidata/api_client/models/add_validation_rapid_model.py +12 -2
  13. rapidata/api_client/models/add_validation_rapid_model_truth.py +7 -1
  14. rapidata/api_client/models/and_filter.py +121 -0
  15. rapidata/api_client/models/and_filter_filters_inner.py +268 -0
  16. rapidata/api_client/models/asset_type.py +40 -0
  17. rapidata/api_client/models/boost_mode.py +37 -0
  18. rapidata/api_client/models/boost_query_result.py +10 -1
  19. rapidata/api_client/models/campaign_filter.py +98 -0
  20. rapidata/api_client/models/change_boost_model.py +89 -0
  21. rapidata/api_client/models/compare_rapid_blueprint.py +5 -3
  22. rapidata/api_client/models/compare_rapid_blueprint1.py +96 -0
  23. rapidata/api_client/models/country_filter.py +98 -0
  24. rapidata/api_client/models/create_leaderboard_model.py +32 -2
  25. rapidata/api_client/models/demographic_filter.py +100 -0
  26. rapidata/api_client/models/feature_flag_model.py +4 -4
  27. rapidata/api_client/models/free_text_payload.py +10 -3
  28. rapidata/api_client/models/free_text_rapid_blueprint.py +10 -3
  29. rapidata/api_client/models/get_compare_ab_summary_result.py +4 -2
  30. rapidata/api_client/models/get_leaderboard_by_id_result.py +29 -2
  31. rapidata/api_client/models/get_public_responses_result.py +95 -0
  32. rapidata/api_client/models/get_sample_by_id_result.py +126 -0
  33. rapidata/api_client/models/language_filter.py +98 -0
  34. rapidata/api_client/models/leaderboard_query_result.py +29 -2
  35. rapidata/api_client/models/new_user_filter.py +96 -0
  36. rapidata/api_client/models/not_filter.py +117 -0
  37. rapidata/api_client/models/or_filter.py +121 -0
  38. rapidata/api_client/models/prompt_type.py +38 -0
  39. rapidata/api_client/models/public_rapid_response.py +112 -0
  40. rapidata/api_client/models/rapid_modality.py +46 -0
  41. rapidata/api_client/models/response_count_filter.py +109 -0
  42. rapidata/api_client/models/sample_by_identifier.py +126 -0
  43. rapidata/api_client/models/sample_by_identifier_paged_result.py +105 -0
  44. rapidata/api_client/models/simple_workflow_config_blueprint.py +37 -23
  45. rapidata/api_client/models/update_leaderboard_model.py +91 -0
  46. rapidata/api_client/models/user_score_filter.py +102 -0
  47. rapidata/api_client/models/user_state.py +38 -0
  48. rapidata/api_client/models/user_state_filter.py +101 -0
  49. rapidata/api_client/models/validation_set_model.py +54 -3
  50. rapidata/api_client_README.md +33 -10
  51. rapidata/rapidata_client/benchmark/rapidata_benchmark.py +26 -2
  52. rapidata/rapidata_client/order/rapidata_order_manager.py +298 -219
  53. rapidata/rapidata_client/workflow/_compare_workflow.py +7 -2
  54. rapidata/rapidata_client/workflow/_free_text_workflow.py +9 -2
  55. {rapidata-2.35.3.dist-info → rapidata-2.36.1.dist-info}/METADATA +1 -1
  56. {rapidata-2.35.3.dist-info → rapidata-2.36.1.dist-info}/RECORD +58 -32
  57. {rapidata-2.35.3.dist-info → rapidata-2.36.1.dist-info}/LICENSE +0 -0
  58. {rapidata-2.35.3.dist-info → rapidata-2.36.1.dist-info}/WHEEL +0 -0
@@ -0,0 +1,299 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ Rapidata.Dataset
5
+
6
+ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
7
+
8
+ The version of the OpenAPI document: v1
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """ # noqa: E501
13
+
14
+ import warnings
15
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
+ from typing import Any, Dict, List, Optional, Tuple, Union
17
+ from typing_extensions import Annotated
18
+
19
+ from pydantic import Field, StrictStr
20
+ from typing_extensions import Annotated
21
+ from rapidata.api_client.models.get_sample_by_id_result import GetSampleByIdResult
22
+
23
+ from rapidata.api_client.api_client import ApiClient, RequestSerialized
24
+ from rapidata.api_client.api_response import ApiResponse
25
+ from rapidata.api_client.rest import RESTResponseType
26
+
27
+
28
+ class SampleApi:
29
+ """NOTE: This class is auto generated by OpenAPI Generator
30
+ Ref: https://openapi-generator.tech
31
+
32
+ Do not edit the class manually.
33
+ """
34
+
35
+ def __init__(self, api_client=None) -> None:
36
+ if api_client is None:
37
+ api_client = ApiClient.get_default()
38
+ self.api_client = api_client
39
+
40
+
41
+ @validate_call
42
+ def benchmark_sample_sample_id_get(
43
+ self,
44
+ sample_id: Annotated[StrictStr, Field(description="The Id of the sample to be retrieved")],
45
+ _request_timeout: Union[
46
+ None,
47
+ Annotated[StrictFloat, Field(gt=0)],
48
+ Tuple[
49
+ Annotated[StrictFloat, Field(gt=0)],
50
+ Annotated[StrictFloat, Field(gt=0)]
51
+ ]
52
+ ] = None,
53
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
54
+ _content_type: Optional[StrictStr] = None,
55
+ _headers: Optional[Dict[StrictStr, Any]] = None,
56
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
57
+ ) -> GetSampleByIdResult:
58
+ """Gets a sample by its Id.
59
+
60
+
61
+ :param sample_id: The Id of the sample to be retrieved (required)
62
+ :type sample_id: str
63
+ :param _request_timeout: timeout setting for this request. If one
64
+ number provided, it will be total request
65
+ timeout. It can also be a pair (tuple) of
66
+ (connection, read) timeouts.
67
+ :type _request_timeout: int, tuple(int, int), optional
68
+ :param _request_auth: set to override the auth_settings for an a single
69
+ request; this effectively ignores the
70
+ authentication in the spec for a single request.
71
+ :type _request_auth: dict, optional
72
+ :param _content_type: force content-type for the request.
73
+ :type _content_type: str, Optional
74
+ :param _headers: set to override the headers for a single
75
+ request; this effectively ignores the headers
76
+ in the spec for a single request.
77
+ :type _headers: dict, optional
78
+ :param _host_index: set to override the host_index for a single
79
+ request; this effectively ignores the host_index
80
+ in the spec for a single request.
81
+ :type _host_index: int, optional
82
+ :return: Returns the result object.
83
+ """ # noqa: E501
84
+
85
+ _param = self._benchmark_sample_sample_id_get_serialize(
86
+ sample_id=sample_id,
87
+ _request_auth=_request_auth,
88
+ _content_type=_content_type,
89
+ _headers=_headers,
90
+ _host_index=_host_index
91
+ )
92
+
93
+ _response_types_map: Dict[str, Optional[str]] = {
94
+ '200': "GetSampleByIdResult",
95
+ }
96
+ response_data = self.api_client.call_api(
97
+ *_param,
98
+ _request_timeout=_request_timeout
99
+ )
100
+ response_data.read()
101
+ return self.api_client.response_deserialize(
102
+ response_data=response_data,
103
+ response_types_map=_response_types_map,
104
+ ).data
105
+
106
+
107
+ @validate_call
108
+ def benchmark_sample_sample_id_get_with_http_info(
109
+ self,
110
+ sample_id: Annotated[StrictStr, Field(description="The Id of the sample to be retrieved")],
111
+ _request_timeout: Union[
112
+ None,
113
+ Annotated[StrictFloat, Field(gt=0)],
114
+ Tuple[
115
+ Annotated[StrictFloat, Field(gt=0)],
116
+ Annotated[StrictFloat, Field(gt=0)]
117
+ ]
118
+ ] = None,
119
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
120
+ _content_type: Optional[StrictStr] = None,
121
+ _headers: Optional[Dict[StrictStr, Any]] = None,
122
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
123
+ ) -> ApiResponse[GetSampleByIdResult]:
124
+ """Gets a sample by its Id.
125
+
126
+
127
+ :param sample_id: The Id of the sample to be retrieved (required)
128
+ :type sample_id: str
129
+ :param _request_timeout: timeout setting for this request. If one
130
+ number provided, it will be total request
131
+ timeout. It can also be a pair (tuple) of
132
+ (connection, read) timeouts.
133
+ :type _request_timeout: int, tuple(int, int), optional
134
+ :param _request_auth: set to override the auth_settings for an a single
135
+ request; this effectively ignores the
136
+ authentication in the spec for a single request.
137
+ :type _request_auth: dict, optional
138
+ :param _content_type: force content-type for the request.
139
+ :type _content_type: str, Optional
140
+ :param _headers: set to override the headers for a single
141
+ request; this effectively ignores the headers
142
+ in the spec for a single request.
143
+ :type _headers: dict, optional
144
+ :param _host_index: set to override the host_index for a single
145
+ request; this effectively ignores the host_index
146
+ in the spec for a single request.
147
+ :type _host_index: int, optional
148
+ :return: Returns the result object.
149
+ """ # noqa: E501
150
+
151
+ _param = self._benchmark_sample_sample_id_get_serialize(
152
+ sample_id=sample_id,
153
+ _request_auth=_request_auth,
154
+ _content_type=_content_type,
155
+ _headers=_headers,
156
+ _host_index=_host_index
157
+ )
158
+
159
+ _response_types_map: Dict[str, Optional[str]] = {
160
+ '200': "GetSampleByIdResult",
161
+ }
162
+ response_data = self.api_client.call_api(
163
+ *_param,
164
+ _request_timeout=_request_timeout
165
+ )
166
+ response_data.read()
167
+ return self.api_client.response_deserialize(
168
+ response_data=response_data,
169
+ response_types_map=_response_types_map,
170
+ )
171
+
172
+
173
+ @validate_call
174
+ def benchmark_sample_sample_id_get_without_preload_content(
175
+ self,
176
+ sample_id: Annotated[StrictStr, Field(description="The Id of the sample to be retrieved")],
177
+ _request_timeout: Union[
178
+ None,
179
+ Annotated[StrictFloat, Field(gt=0)],
180
+ Tuple[
181
+ Annotated[StrictFloat, Field(gt=0)],
182
+ Annotated[StrictFloat, Field(gt=0)]
183
+ ]
184
+ ] = None,
185
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
186
+ _content_type: Optional[StrictStr] = None,
187
+ _headers: Optional[Dict[StrictStr, Any]] = None,
188
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
189
+ ) -> RESTResponseType:
190
+ """Gets a sample by its Id.
191
+
192
+
193
+ :param sample_id: The Id of the sample to be retrieved (required)
194
+ :type sample_id: str
195
+ :param _request_timeout: timeout setting for this request. If one
196
+ number provided, it will be total request
197
+ timeout. It can also be a pair (tuple) of
198
+ (connection, read) timeouts.
199
+ :type _request_timeout: int, tuple(int, int), optional
200
+ :param _request_auth: set to override the auth_settings for an a single
201
+ request; this effectively ignores the
202
+ authentication in the spec for a single request.
203
+ :type _request_auth: dict, optional
204
+ :param _content_type: force content-type for the request.
205
+ :type _content_type: str, Optional
206
+ :param _headers: set to override the headers for a single
207
+ request; this effectively ignores the headers
208
+ in the spec for a single request.
209
+ :type _headers: dict, optional
210
+ :param _host_index: set to override the host_index for a single
211
+ request; this effectively ignores the host_index
212
+ in the spec for a single request.
213
+ :type _host_index: int, optional
214
+ :return: Returns the result object.
215
+ """ # noqa: E501
216
+
217
+ _param = self._benchmark_sample_sample_id_get_serialize(
218
+ sample_id=sample_id,
219
+ _request_auth=_request_auth,
220
+ _content_type=_content_type,
221
+ _headers=_headers,
222
+ _host_index=_host_index
223
+ )
224
+
225
+ _response_types_map: Dict[str, Optional[str]] = {
226
+ '200': "GetSampleByIdResult",
227
+ }
228
+ response_data = self.api_client.call_api(
229
+ *_param,
230
+ _request_timeout=_request_timeout
231
+ )
232
+ return response_data.response
233
+
234
+
235
+ def _benchmark_sample_sample_id_get_serialize(
236
+ self,
237
+ sample_id,
238
+ _request_auth,
239
+ _content_type,
240
+ _headers,
241
+ _host_index,
242
+ ) -> RequestSerialized:
243
+
244
+ _host = None
245
+
246
+ _collection_formats: Dict[str, str] = {
247
+ }
248
+
249
+ _path_params: Dict[str, str] = {}
250
+ _query_params: List[Tuple[str, str]] = []
251
+ _header_params: Dict[str, Optional[str]] = _headers or {}
252
+ _form_params: List[Tuple[str, str]] = []
253
+ _files: Dict[
254
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
255
+ ] = {}
256
+ _body_params: Optional[bytes] = None
257
+
258
+ # process the path parameters
259
+ if sample_id is not None:
260
+ _path_params['sampleId'] = sample_id
261
+ # process the query parameters
262
+ # process the header parameters
263
+ # process the form parameters
264
+ # process the body parameter
265
+
266
+
267
+ # set the HTTP header `Accept`
268
+ if 'Accept' not in _header_params:
269
+ _header_params['Accept'] = self.api_client.select_header_accept(
270
+ [
271
+ 'text/plain',
272
+ 'application/json',
273
+ 'text/json'
274
+ ]
275
+ )
276
+
277
+
278
+ # authentication setting
279
+ _auth_settings: List[str] = [
280
+ 'bearer',
281
+ 'oauth2'
282
+ ]
283
+
284
+ return self.api_client.param_serialize(
285
+ method='GET',
286
+ resource_path='/benchmark-sample/{sampleId}',
287
+ path_params=_path_params,
288
+ query_params=_query_params,
289
+ header_params=_header_params,
290
+ body=_body_params,
291
+ post_params=_form_params,
292
+ files=_files,
293
+ auth_settings=_auth_settings,
294
+ collection_formats=_collection_formats,
295
+ _host=_host,
296
+ _request_auth=_request_auth
297
+ )
298
+
299
+