rapidata 2.36.0__py3-none-any.whl → 2.36.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of rapidata might be problematic. Click here for more details.
- rapidata/__init__.py +2 -2
- rapidata/api_client/__init__.py +3 -2
- rapidata/api_client/api/leaderboard_api.py +295 -6
- rapidata/api_client/api/validation_set_api.py +561 -313
- rapidata/api_client/models/__init__.py +3 -2
- rapidata/api_client/models/add_validation_rapid_model.py +29 -4
- rapidata/api_client/models/add_validation_rapid_model_truth.py +7 -1
- rapidata/api_client/models/asset_metadata.py +9 -1
- rapidata/api_client/models/asset_type.py +40 -0
- rapidata/api_client/models/boost_query_result.py +5 -17
- rapidata/api_client/models/campaign_query_result.py +3 -9
- rapidata/api_client/models/classification_metadata.py +12 -1
- rapidata/api_client/models/compare_workflow_config.py +22 -12
- rapidata/api_client/models/compare_workflow_config_model.py +12 -2
- rapidata/api_client/models/compare_workflow_model.py +12 -2
- rapidata/api_client/models/count_metadata.py +12 -1
- rapidata/api_client/models/create_demographic_rapid_model.py +18 -3
- rapidata/api_client/models/create_order_model.py +6 -48
- rapidata/api_client/models/effort_capped_selection.py +2 -11
- rapidata/api_client/models/evaluation_workflow_config.py +13 -3
- rapidata/api_client/models/evaluation_workflow_model.py +13 -3
- rapidata/api_client/models/file_type_metadata.py +11 -6
- rapidata/api_client/models/file_type_metadata_model.py +2 -8
- rapidata/api_client/models/filter.py +5 -23
- rapidata/api_client/models/get_datapoint_by_id_result.py +3 -9
- rapidata/api_client/models/get_rapid_responses_result.py +3 -9
- rapidata/api_client/models/get_recommended_validation_set_result.py +95 -0
- rapidata/api_client/models/get_standing_by_id_result.py +3 -9
- rapidata/api_client/models/get_validation_rapids_result.py +3 -9
- rapidata/api_client/models/get_workflow_progress_result.py +3 -9
- rapidata/api_client/models/get_workflow_results_result.py +3 -9
- rapidata/api_client/models/image_dimension_metadata.py +12 -1
- rapidata/api_client/models/labeling_selection.py +2 -11
- rapidata/api_client/models/location_metadata.py +12 -1
- rapidata/api_client/models/order_model.py +3 -9
- rapidata/api_client/models/original_filename_metadata.py +12 -1
- rapidata/api_client/models/participant_by_benchmark.py +3 -9
- rapidata/api_client/models/prompt_metadata.py +12 -1
- rapidata/api_client/models/prompt_type.py +38 -0
- rapidata/api_client/models/rapid_modality.py +46 -0
- rapidata/api_client/models/rapid_model.py +3 -9
- rapidata/api_client/models/report_model.py +3 -9
- rapidata/api_client/models/response_count_filter.py +2 -8
- rapidata/api_client/models/response_count_user_filter_model.py +2 -8
- rapidata/api_client/models/root_filter.py +3 -12
- rapidata/api_client/models/runs_by_leaderboard_result.py +3 -9
- rapidata/api_client/models/simple_workflow_config.py +13 -3
- rapidata/api_client/models/simple_workflow_config_model.py +11 -3
- rapidata/api_client/models/simple_workflow_model.py +13 -3
- rapidata/api_client/models/sort_criterion.py +3 -9
- rapidata/api_client/models/source_url_metadata.py +12 -1
- rapidata/api_client/models/standing_by_leaderboard.py +3 -9
- rapidata/api_client/models/streams_metadata.py +12 -1
- rapidata/api_client/models/text_metadata.py +12 -1
- rapidata/api_client/models/transcription_metadata.py +9 -1
- rapidata/api_client/models/update_leaderboard_model.py +91 -0
- rapidata/api_client/models/update_should_alert_model.py +1 -1
- rapidata/api_client/models/validation_set_model.py +42 -3
- rapidata/api_client/models/video_duration_metadata.py +12 -1
- rapidata/api_client/models/workflow_aggregation_step_model.py +3 -12
- rapidata/api_client_README.md +8 -5
- rapidata/rapidata_client/__init__.py +1 -1
- rapidata/rapidata_client/benchmark/participant/_participant.py +5 -5
- rapidata/rapidata_client/benchmark/rapidata_benchmark.py +2 -1
- rapidata/rapidata_client/benchmark/rapidata_benchmark_manager.py +10 -2
- rapidata/rapidata_client/config/__init__.py +1 -1
- rapidata/rapidata_client/config/rapidata_config.py +31 -0
- rapidata/rapidata_client/datapoints/__init__.py +10 -2
- rapidata/rapidata_client/datapoints/{datapoint.py → _datapoint.py} +105 -17
- rapidata/rapidata_client/datapoints/assets/_media_asset.py +80 -68
- rapidata/rapidata_client/datapoints/assets/_sessions.py +3 -3
- rapidata/rapidata_client/datapoints/assets/constants.py +7 -0
- rapidata/rapidata_client/exceptions/failed_upload_exception.py +42 -13
- rapidata/rapidata_client/filter/response_count_filter.py +16 -11
- rapidata/rapidata_client/order/_rapidata_dataset.py +8 -8
- rapidata/rapidata_client/order/_rapidata_order_builder.py +87 -8
- rapidata/rapidata_client/order/rapidata_order_manager.py +18 -4
- rapidata/rapidata_client/rapidata_client.py +6 -0
- rapidata/rapidata_client/selection/__init__.py +1 -1
- rapidata/rapidata_client/selection/effort_selection.py +18 -7
- rapidata/rapidata_client/selection/labeling_selection.py +19 -7
- rapidata/rapidata_client/selection/{retrieval_modes.py → rapidata_retrieval_modes.py} +7 -4
- rapidata/rapidata_client/validation/rapidata_validation_set.py +26 -1
- rapidata/rapidata_client/validation/rapids/rapids.py +46 -19
- rapidata/rapidata_client/validation/validation_set_manager.py +41 -4
- rapidata/rapidata_client/workflow/_base_workflow.py +27 -0
- rapidata/rapidata_client/workflow/_classify_workflow.py +25 -9
- rapidata/rapidata_client/workflow/_compare_workflow.py +11 -0
- rapidata/rapidata_client/workflow/_draw_workflow.py +15 -7
- rapidata/rapidata_client/workflow/_evaluation_workflow.py +8 -1
- rapidata/rapidata_client/workflow/_free_text_workflow.py +20 -2
- rapidata/rapidata_client/workflow/_locate_workflow.py +15 -7
- rapidata/rapidata_client/workflow/_ranking_workflow.py +39 -15
- rapidata/rapidata_client/workflow/_select_words_workflow.py +41 -7
- rapidata/rapidata_client/workflow/_timestamp_workflow.py +17 -8
- rapidata/service/openapi_service.py +1 -1
- {rapidata-2.36.0.dist-info → rapidata-2.36.2.dist-info}/METADATA +1 -1
- {rapidata-2.36.0.dist-info → rapidata-2.36.2.dist-info}/RECORD +100 -94
- rapidata/rapidata_client/config/config.py +0 -33
- {rapidata-2.36.0.dist-info → rapidata-2.36.2.dist-info}/LICENSE +0 -0
- {rapidata-2.36.0.dist-info → rapidata-2.36.2.dist-info}/WHEEL +0 -0
|
@@ -29,7 +29,7 @@ class ImageDimensionMetadata(BaseModel):
|
|
|
29
29
|
t: StrictStr = Field(description="Discriminator value for ImageDimensionMetadata", alias="_t")
|
|
30
30
|
height: Optional[StrictInt] = None
|
|
31
31
|
width: Optional[StrictInt] = None
|
|
32
|
-
visibilities: Optional[StrictStr] = None
|
|
32
|
+
visibilities: Optional[List[StrictStr]] = None
|
|
33
33
|
__properties: ClassVar[List[str]] = ["_t", "height", "width", "visibilities"]
|
|
34
34
|
|
|
35
35
|
@field_validator('t')
|
|
@@ -39,6 +39,17 @@ class ImageDimensionMetadata(BaseModel):
|
|
|
39
39
|
raise ValueError("must be one of enum values ('ImageDimensionMetadata')")
|
|
40
40
|
return value
|
|
41
41
|
|
|
42
|
+
@field_validator('visibilities')
|
|
43
|
+
def visibilities_validate_enum(cls, value):
|
|
44
|
+
"""Validates the enum"""
|
|
45
|
+
if value is None:
|
|
46
|
+
return value
|
|
47
|
+
|
|
48
|
+
for i in value:
|
|
49
|
+
if i not in set(['None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All']):
|
|
50
|
+
raise ValueError("each list item must be one of ('None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All')")
|
|
51
|
+
return value
|
|
52
|
+
|
|
42
53
|
model_config = ConfigDict(
|
|
43
54
|
populate_by_name=True,
|
|
44
55
|
validate_assignment=True,
|
|
@@ -19,6 +19,7 @@ import json
|
|
|
19
19
|
|
|
20
20
|
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
|
|
21
21
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from rapidata.api_client.models.retrieval_mode import RetrievalMode
|
|
22
23
|
from typing import Optional, Set
|
|
23
24
|
from typing_extensions import Self
|
|
24
25
|
|
|
@@ -28,7 +29,7 @@ class LabelingSelection(BaseModel):
|
|
|
28
29
|
""" # noqa: E501
|
|
29
30
|
t: StrictStr = Field(description="Discriminator value for LabelingSelection", alias="_t")
|
|
30
31
|
amount: StrictInt
|
|
31
|
-
retrieval_mode: Optional[
|
|
32
|
+
retrieval_mode: Optional[RetrievalMode] = Field(default=None, alias="retrievalMode")
|
|
32
33
|
max_iterations: Optional[StrictInt] = Field(default=None, alias="maxIterations")
|
|
33
34
|
__properties: ClassVar[List[str]] = ["_t", "amount", "retrievalMode", "maxIterations"]
|
|
34
35
|
|
|
@@ -39,16 +40,6 @@ class LabelingSelection(BaseModel):
|
|
|
39
40
|
raise ValueError("must be one of enum values ('LabelingSelection')")
|
|
40
41
|
return value
|
|
41
42
|
|
|
42
|
-
@field_validator('retrieval_mode')
|
|
43
|
-
def retrieval_mode_validate_enum(cls, value):
|
|
44
|
-
"""Validates the enum"""
|
|
45
|
-
if value is None:
|
|
46
|
-
return value
|
|
47
|
-
|
|
48
|
-
if value not in set(['Random', 'Shuffled', 'Sequential']):
|
|
49
|
-
raise ValueError("must be one of enum values ('Random', 'Shuffled', 'Sequential')")
|
|
50
|
-
return value
|
|
51
|
-
|
|
52
43
|
model_config = ConfigDict(
|
|
53
44
|
populate_by_name=True,
|
|
54
45
|
validate_assignment=True,
|
|
@@ -29,7 +29,7 @@ class LocationMetadata(BaseModel):
|
|
|
29
29
|
t: StrictStr = Field(description="Discriminator value for LocationMetadata", alias="_t")
|
|
30
30
|
x: Union[StrictFloat, StrictInt]
|
|
31
31
|
y: Union[StrictFloat, StrictInt]
|
|
32
|
-
visibilities: Optional[StrictStr] = None
|
|
32
|
+
visibilities: Optional[List[StrictStr]] = None
|
|
33
33
|
__properties: ClassVar[List[str]] = ["_t", "x", "y", "visibilities"]
|
|
34
34
|
|
|
35
35
|
@field_validator('t')
|
|
@@ -39,6 +39,17 @@ class LocationMetadata(BaseModel):
|
|
|
39
39
|
raise ValueError("must be one of enum values ('LocationMetadata')")
|
|
40
40
|
return value
|
|
41
41
|
|
|
42
|
+
@field_validator('visibilities')
|
|
43
|
+
def visibilities_validate_enum(cls, value):
|
|
44
|
+
"""Validates the enum"""
|
|
45
|
+
if value is None:
|
|
46
|
+
return value
|
|
47
|
+
|
|
48
|
+
for i in value:
|
|
49
|
+
if i not in set(['None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All']):
|
|
50
|
+
raise ValueError("each list item must be one of ('None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All')")
|
|
51
|
+
return value
|
|
52
|
+
|
|
42
53
|
model_config = ConfigDict(
|
|
43
54
|
populate_by_name=True,
|
|
44
55
|
validate_assignment=True,
|
|
@@ -18,8 +18,9 @@ import re # noqa: F401
|
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
20
|
from datetime import datetime
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictStr
|
|
22
22
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from rapidata.api_client.models.order_state import OrderState
|
|
23
24
|
from typing import Optional, Set
|
|
24
25
|
from typing_extensions import Self
|
|
25
26
|
|
|
@@ -31,18 +32,11 @@ class OrderModel(BaseModel):
|
|
|
31
32
|
pipeline_id: StrictStr = Field(alias="pipelineId")
|
|
32
33
|
order_date: Optional[datetime] = Field(default=None, alias="orderDate")
|
|
33
34
|
customer_mail: StrictStr = Field(alias="customerMail")
|
|
34
|
-
state:
|
|
35
|
+
state: OrderState
|
|
35
36
|
order_name: StrictStr = Field(alias="orderName")
|
|
36
37
|
is_public: StrictBool = Field(alias="isPublic")
|
|
37
38
|
__properties: ClassVar[List[str]] = ["id", "pipelineId", "orderDate", "customerMail", "state", "orderName", "isPublic"]
|
|
38
39
|
|
|
39
|
-
@field_validator('state')
|
|
40
|
-
def state_validate_enum(cls, value):
|
|
41
|
-
"""Validates the enum"""
|
|
42
|
-
if value not in set(['Created', 'Preview', 'Submitted', 'ManualReview', 'Processing', 'Paused', 'Completed', 'Cancelled', 'Failed']):
|
|
43
|
-
raise ValueError("must be one of enum values ('Created', 'Preview', 'Submitted', 'ManualReview', 'Processing', 'Paused', 'Completed', 'Cancelled', 'Failed')")
|
|
44
|
-
return value
|
|
45
|
-
|
|
46
40
|
model_config = ConfigDict(
|
|
47
41
|
populate_by_name=True,
|
|
48
42
|
validate_assignment=True,
|
|
@@ -28,7 +28,7 @@ class OriginalFilenameMetadata(BaseModel):
|
|
|
28
28
|
""" # noqa: E501
|
|
29
29
|
t: StrictStr = Field(description="Discriminator value for OriginalFilenameMetadata", alias="_t")
|
|
30
30
|
original_filename: StrictStr = Field(alias="originalFilename")
|
|
31
|
-
visibilities: Optional[StrictStr] = None
|
|
31
|
+
visibilities: Optional[List[StrictStr]] = None
|
|
32
32
|
__properties: ClassVar[List[str]] = ["_t", "originalFilename", "visibilities"]
|
|
33
33
|
|
|
34
34
|
@field_validator('t')
|
|
@@ -38,6 +38,17 @@ class OriginalFilenameMetadata(BaseModel):
|
|
|
38
38
|
raise ValueError("must be one of enum values ('OriginalFilenameMetadata')")
|
|
39
39
|
return value
|
|
40
40
|
|
|
41
|
+
@field_validator('visibilities')
|
|
42
|
+
def visibilities_validate_enum(cls, value):
|
|
43
|
+
"""Validates the enum"""
|
|
44
|
+
if value is None:
|
|
45
|
+
return value
|
|
46
|
+
|
|
47
|
+
for i in value:
|
|
48
|
+
if i not in set(['None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All']):
|
|
49
|
+
raise ValueError("each list item must be one of ('None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All')")
|
|
50
|
+
return value
|
|
51
|
+
|
|
41
52
|
model_config = ConfigDict(
|
|
42
53
|
populate_by_name=True,
|
|
43
54
|
validate_assignment=True,
|
|
@@ -17,8 +17,9 @@ import pprint
|
|
|
17
17
|
import re # noqa: F401
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
|
-
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
21
21
|
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from rapidata.api_client.models.participant_status import ParticipantStatus
|
|
22
23
|
from typing import Optional, Set
|
|
23
24
|
from typing_extensions import Self
|
|
24
25
|
|
|
@@ -30,16 +31,9 @@ class ParticipantByBenchmark(BaseModel):
|
|
|
30
31
|
name: StrictStr
|
|
31
32
|
benchmark_id: StrictStr = Field(alias="benchmarkId")
|
|
32
33
|
dataset_id: StrictStr = Field(alias="datasetId")
|
|
33
|
-
status:
|
|
34
|
+
status: ParticipantStatus
|
|
34
35
|
__properties: ClassVar[List[str]] = ["id", "name", "benchmarkId", "datasetId", "status"]
|
|
35
36
|
|
|
36
|
-
@field_validator('status')
|
|
37
|
-
def status_validate_enum(cls, value):
|
|
38
|
-
"""Validates the enum"""
|
|
39
|
-
if value not in set(['Created', 'Submitted', 'Disabled']):
|
|
40
|
-
raise ValueError("must be one of enum values ('Created', 'Submitted', 'Disabled')")
|
|
41
|
-
return value
|
|
42
|
-
|
|
43
37
|
model_config = ConfigDict(
|
|
44
38
|
populate_by_name=True,
|
|
45
39
|
validate_assignment=True,
|
|
@@ -28,7 +28,7 @@ class PromptMetadata(BaseModel):
|
|
|
28
28
|
""" # noqa: E501
|
|
29
29
|
t: StrictStr = Field(description="Discriminator value for PromptMetadata", alias="_t")
|
|
30
30
|
prompt: StrictStr
|
|
31
|
-
visibilities: Optional[StrictStr] = None
|
|
31
|
+
visibilities: Optional[List[StrictStr]] = None
|
|
32
32
|
__properties: ClassVar[List[str]] = ["_t", "prompt", "visibilities"]
|
|
33
33
|
|
|
34
34
|
@field_validator('t')
|
|
@@ -38,6 +38,17 @@ class PromptMetadata(BaseModel):
|
|
|
38
38
|
raise ValueError("must be one of enum values ('PromptMetadata')")
|
|
39
39
|
return value
|
|
40
40
|
|
|
41
|
+
@field_validator('visibilities')
|
|
42
|
+
def visibilities_validate_enum(cls, value):
|
|
43
|
+
"""Validates the enum"""
|
|
44
|
+
if value is None:
|
|
45
|
+
return value
|
|
46
|
+
|
|
47
|
+
for i in value:
|
|
48
|
+
if i not in set(['None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All']):
|
|
49
|
+
raise ValueError("each list item must be one of ('None', 'Users', 'Customers', 'Admins', 'Dashboard', 'All')")
|
|
50
|
+
return value
|
|
51
|
+
|
|
41
52
|
model_config = ConfigDict(
|
|
42
53
|
populate_by_name=True,
|
|
43
54
|
validate_assignment=True,
|
|
@@ -0,0 +1,38 @@
|
|
|
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
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import json
|
|
17
|
+
from enum import Enum
|
|
18
|
+
from typing_extensions import Self
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class PromptType(str, Enum):
|
|
22
|
+
"""
|
|
23
|
+
PromptType
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
"""
|
|
27
|
+
allowed enum values
|
|
28
|
+
"""
|
|
29
|
+
NONE = 'None'
|
|
30
|
+
TEXT = 'Text'
|
|
31
|
+
ASSET = 'Asset'
|
|
32
|
+
|
|
33
|
+
@classmethod
|
|
34
|
+
def from_json(cls, json_str: str) -> Self:
|
|
35
|
+
"""Create an instance of PromptType from a JSON string"""
|
|
36
|
+
return cls(json.loads(json_str))
|
|
37
|
+
|
|
38
|
+
|
|
@@ -0,0 +1,46 @@
|
|
|
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
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import json
|
|
17
|
+
from enum import Enum
|
|
18
|
+
from typing_extensions import Self
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class RapidModality(str, Enum):
|
|
22
|
+
"""
|
|
23
|
+
RapidModality
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
"""
|
|
27
|
+
allowed enum values
|
|
28
|
+
"""
|
|
29
|
+
NONE = 'None'
|
|
30
|
+
BOUNDINGBOX = 'BoundingBox'
|
|
31
|
+
CLASSIFY = 'Classify'
|
|
32
|
+
COMPARE = 'Compare'
|
|
33
|
+
FREETEXT = 'FreeText'
|
|
34
|
+
LINE = 'Line'
|
|
35
|
+
LOCATE = 'Locate'
|
|
36
|
+
NAMEDENTITY = 'NamedEntity'
|
|
37
|
+
POLYGON = 'Polygon'
|
|
38
|
+
SCRUB = 'Scrub'
|
|
39
|
+
TRANSCRIPTION = 'Transcription'
|
|
40
|
+
|
|
41
|
+
@classmethod
|
|
42
|
+
def from_json(cls, json_str: str) -> Self:
|
|
43
|
+
"""Create an instance of RapidModality from a JSON string"""
|
|
44
|
+
return cls(json.loads(json_str))
|
|
45
|
+
|
|
46
|
+
|
|
@@ -18,13 +18,14 @@ import re # noqa: F401
|
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
20
|
from datetime import datetime
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr
|
|
22
22
|
from typing import Any, ClassVar, Dict, List, Optional, Union
|
|
23
23
|
from rapidata.api_client.models.datapoint_asset import DatapointAsset
|
|
24
24
|
from rapidata.api_client.models.file_asset_model_metadata_value import FileAssetModelMetadataValue
|
|
25
25
|
from rapidata.api_client.models.get_validation_rapids_result_payload import GetValidationRapidsResultPayload
|
|
26
26
|
from rapidata.api_client.models.get_validation_rapids_result_truth import GetValidationRapidsResultTruth
|
|
27
27
|
from rapidata.api_client.models.rapid_model_referee import RapidModelReferee
|
|
28
|
+
from rapidata.api_client.models.rapid_state import RapidState
|
|
28
29
|
from typing import Optional, Set
|
|
29
30
|
from typing_extensions import Self
|
|
30
31
|
|
|
@@ -37,7 +38,7 @@ class RapidModel(BaseModel):
|
|
|
37
38
|
referee: RapidModelReferee
|
|
38
39
|
asset: DatapointAsset
|
|
39
40
|
metadata: Dict[str, FileAssetModelMetadataValue]
|
|
40
|
-
state:
|
|
41
|
+
state: RapidState
|
|
41
42
|
has_responses: StrictBool = Field(alias="hasResponses")
|
|
42
43
|
should_accept_incorrect: StrictBool = Field(alias="shouldAcceptIncorrect")
|
|
43
44
|
truth: Optional[GetValidationRapidsResultTruth] = None
|
|
@@ -47,13 +48,6 @@ class RapidModel(BaseModel):
|
|
|
47
48
|
completed_at: Optional[datetime] = Field(default=None, alias="completedAt")
|
|
48
49
|
__properties: ClassVar[List[str]] = ["id", "payload", "referee", "asset", "metadata", "state", "hasResponses", "shouldAcceptIncorrect", "truth", "explanation", "randomCorrectProbability", "key", "completedAt"]
|
|
49
50
|
|
|
50
|
-
@field_validator('state')
|
|
51
|
-
def state_validate_enum(cls, value):
|
|
52
|
-
"""Validates the enum"""
|
|
53
|
-
if value not in set(['Labeling', 'Paused', 'Incomplete', 'Flagged', 'Done', 'None']):
|
|
54
|
-
raise ValueError("must be one of enum values ('Labeling', 'Paused', 'Incomplete', 'Flagged', 'Done', 'None')")
|
|
55
|
-
return value
|
|
56
|
-
|
|
57
51
|
model_config = ConfigDict(
|
|
58
52
|
populate_by_name=True,
|
|
59
53
|
validate_assignment=True,
|
|
@@ -17,8 +17,9 @@ import pprint
|
|
|
17
17
|
import re # noqa: F401
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
|
-
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
21
21
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from rapidata.api_client.models.rapid_issue import RapidIssue
|
|
22
23
|
from typing import Optional, Set
|
|
23
24
|
from typing_extensions import Self
|
|
24
25
|
|
|
@@ -26,19 +27,12 @@ class ReportModel(BaseModel):
|
|
|
26
27
|
"""
|
|
27
28
|
The model for reporting an issue with a rapid.
|
|
28
29
|
""" # noqa: E501
|
|
29
|
-
issue:
|
|
30
|
+
issue: RapidIssue
|
|
30
31
|
message: Optional[StrictStr] = Field(default=None, description="An optional message typed by the user.")
|
|
31
32
|
dump: Optional[StrictStr] = Field(default=None, description="A dump, that the frontend defines and can read again.")
|
|
32
33
|
source: Optional[StrictStr] = Field(default=None, description="An optional identifier where the report originated from.")
|
|
33
34
|
__properties: ClassVar[List[str]] = ["issue", "message", "dump", "source"]
|
|
34
35
|
|
|
35
|
-
@field_validator('issue')
|
|
36
|
-
def issue_validate_enum(cls, value):
|
|
37
|
-
"""Validates the enum"""
|
|
38
|
-
if value not in set(['Other', 'CannotSubmit', 'NoAsset', 'Inappropriate', 'NoCorrectOption', 'WrongLanguage', 'DoNotUnderstand', 'DoNotCare', 'NotSeeOptionsOrMediaDidntLoad', 'MyAnswerIsCorrect']):
|
|
39
|
-
raise ValueError("must be one of enum values ('Other', 'CannotSubmit', 'NoAsset', 'Inappropriate', 'NoCorrectOption', 'WrongLanguage', 'DoNotUnderstand', 'DoNotCare', 'NotSeeOptionsOrMediaDidntLoad', 'MyAnswerIsCorrect')")
|
|
40
|
-
return value
|
|
41
|
-
|
|
42
36
|
model_config = ConfigDict(
|
|
43
37
|
populate_by_name=True,
|
|
44
38
|
validate_assignment=True,
|
|
@@ -19,6 +19,7 @@ import json
|
|
|
19
19
|
|
|
20
20
|
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
|
|
21
21
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from rapidata.api_client.models.comparison_operator import ComparisonOperator
|
|
22
23
|
from typing import Optional, Set
|
|
23
24
|
from typing_extensions import Self
|
|
24
25
|
|
|
@@ -29,7 +30,7 @@ class ResponseCountFilter(BaseModel):
|
|
|
29
30
|
t: StrictStr = Field(description="Discriminator value for ResponseCountFilter", alias="_t")
|
|
30
31
|
response_count: StrictInt = Field(alias="responseCount")
|
|
31
32
|
dimension: StrictStr
|
|
32
|
-
operator:
|
|
33
|
+
operator: ComparisonOperator
|
|
33
34
|
execution_order: Optional[StrictInt] = Field(default=None, alias="executionOrder")
|
|
34
35
|
__properties: ClassVar[List[str]] = ["_t", "responseCount", "dimension", "operator", "executionOrder"]
|
|
35
36
|
|
|
@@ -40,13 +41,6 @@ class ResponseCountFilter(BaseModel):
|
|
|
40
41
|
raise ValueError("must be one of enum values ('ResponseCountFilter')")
|
|
41
42
|
return value
|
|
42
43
|
|
|
43
|
-
@field_validator('operator')
|
|
44
|
-
def operator_validate_enum(cls, value):
|
|
45
|
-
"""Validates the enum"""
|
|
46
|
-
if value not in set(['Equal', 'NotEqual', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual']):
|
|
47
|
-
raise ValueError("must be one of enum values ('Equal', 'NotEqual', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual')")
|
|
48
|
-
return value
|
|
49
|
-
|
|
50
44
|
model_config = ConfigDict(
|
|
51
45
|
populate_by_name=True,
|
|
52
46
|
validate_assignment=True,
|
|
@@ -19,6 +19,7 @@ import json
|
|
|
19
19
|
|
|
20
20
|
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
|
|
21
21
|
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from rapidata.api_client.models.comparison_operator import ComparisonOperator
|
|
22
23
|
from typing import Optional, Set
|
|
23
24
|
from typing_extensions import Self
|
|
24
25
|
|
|
@@ -29,7 +30,7 @@ class ResponseCountUserFilterModel(BaseModel):
|
|
|
29
30
|
t: StrictStr = Field(description="Discriminator value for ResponseCountFilter", alias="_t")
|
|
30
31
|
response_count: StrictInt = Field(alias="responseCount")
|
|
31
32
|
dimension: StrictStr
|
|
32
|
-
operator:
|
|
33
|
+
operator: ComparisonOperator
|
|
33
34
|
__properties: ClassVar[List[str]] = ["_t", "responseCount", "dimension", "operator"]
|
|
34
35
|
|
|
35
36
|
@field_validator('t')
|
|
@@ -39,13 +40,6 @@ class ResponseCountUserFilterModel(BaseModel):
|
|
|
39
40
|
raise ValueError("must be one of enum values ('ResponseCountFilter')")
|
|
40
41
|
return value
|
|
41
42
|
|
|
42
|
-
@field_validator('operator')
|
|
43
|
-
def operator_validate_enum(cls, value):
|
|
44
|
-
"""Validates the enum"""
|
|
45
|
-
if value not in set(['Equal', 'NotEqual', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual']):
|
|
46
|
-
raise ValueError("must be one of enum values ('Equal', 'NotEqual', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual')")
|
|
47
|
-
return value
|
|
48
|
-
|
|
49
43
|
model_config = ConfigDict(
|
|
50
44
|
populate_by_name=True,
|
|
51
45
|
validate_assignment=True,
|
|
@@ -17,9 +17,10 @@ import pprint
|
|
|
17
17
|
import re # noqa: F401
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
|
-
from pydantic import BaseModel, ConfigDict
|
|
20
|
+
from pydantic import BaseModel, ConfigDict
|
|
21
21
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
22
|
from rapidata.api_client.models.filter import Filter
|
|
23
|
+
from rapidata.api_client.models.logic_operator import LogicOperator
|
|
23
24
|
from typing import Optional, Set
|
|
24
25
|
from typing_extensions import Self
|
|
25
26
|
|
|
@@ -28,19 +29,9 @@ class RootFilter(BaseModel):
|
|
|
28
29
|
RootFilter
|
|
29
30
|
""" # noqa: E501
|
|
30
31
|
filters: Optional[List[Filter]] = None
|
|
31
|
-
logic: Optional[
|
|
32
|
+
logic: Optional[LogicOperator] = None
|
|
32
33
|
__properties: ClassVar[List[str]] = ["filters", "logic"]
|
|
33
34
|
|
|
34
|
-
@field_validator('logic')
|
|
35
|
-
def logic_validate_enum(cls, value):
|
|
36
|
-
"""Validates the enum"""
|
|
37
|
-
if value is None:
|
|
38
|
-
return value
|
|
39
|
-
|
|
40
|
-
if value not in set(['And', 'Or', 'Not']):
|
|
41
|
-
raise ValueError("must be one of enum values ('And', 'Or', 'Not')")
|
|
42
|
-
return value
|
|
43
|
-
|
|
44
35
|
model_config = ConfigDict(
|
|
45
36
|
populate_by_name=True,
|
|
46
37
|
validate_assignment=True,
|
|
@@ -18,8 +18,9 @@ import re # noqa: F401
|
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
20
|
from datetime import datetime
|
|
21
|
-
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
22
|
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from rapidata.api_client.models.run_status import RunStatus
|
|
23
24
|
from typing import Optional, Set
|
|
24
25
|
from typing_extensions import Self
|
|
25
26
|
|
|
@@ -29,19 +30,12 @@ class RunsByLeaderboardResult(BaseModel):
|
|
|
29
30
|
""" # noqa: E501
|
|
30
31
|
id: StrictStr
|
|
31
32
|
name: StrictStr
|
|
32
|
-
status:
|
|
33
|
+
status: RunStatus
|
|
33
34
|
created_at: datetime = Field(alias="createdAt")
|
|
34
35
|
owner_mail: StrictStr = Field(alias="ownerMail")
|
|
35
36
|
order_id: Optional[StrictStr] = Field(default=None, alias="orderId")
|
|
36
37
|
__properties: ClassVar[List[str]] = ["id", "name", "status", "createdAt", "ownerMail", "orderId"]
|
|
37
38
|
|
|
38
|
-
@field_validator('status')
|
|
39
|
-
def status_validate_enum(cls, value):
|
|
40
|
-
"""Validates the enum"""
|
|
41
|
-
if value not in set(['Queued', 'Running', 'Completed', 'Failed']):
|
|
42
|
-
raise ValueError("must be one of enum values ('Queued', 'Running', 'Completed', 'Failed')")
|
|
43
|
-
return value
|
|
44
|
-
|
|
45
39
|
model_config = ConfigDict(
|
|
46
40
|
populate_by_name=True,
|
|
47
41
|
validate_assignment=True,
|
|
@@ -18,8 +18,9 @@ import re # noqa: F401
|
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
20
|
from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
|
|
21
|
-
from typing import Any, ClassVar, Dict, List
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
22
|
from rapidata.api_client.models.compare_workflow_model1_referee import CompareWorkflowModel1Referee
|
|
23
|
+
from rapidata.api_client.models.feature_flag import FeatureFlag
|
|
23
24
|
from rapidata.api_client.models.validation_set_zip_post_request_blueprint import ValidationSetZipPostRequestBlueprint
|
|
24
25
|
from typing import Optional, Set
|
|
25
26
|
from typing_extensions import Self
|
|
@@ -31,7 +32,8 @@ class SimpleWorkflowConfig(BaseModel):
|
|
|
31
32
|
t: StrictStr = Field(description="Discriminator value for SimpleWorkflowConfig", alias="_t")
|
|
32
33
|
referee: CompareWorkflowModel1Referee
|
|
33
34
|
blueprint: ValidationSetZipPostRequestBlueprint
|
|
34
|
-
|
|
35
|
+
feature_flags: Optional[List[FeatureFlag]] = Field(default=None, alias="featureFlags")
|
|
36
|
+
__properties: ClassVar[List[str]] = ["_t", "referee", "blueprint", "featureFlags"]
|
|
35
37
|
|
|
36
38
|
@field_validator('t')
|
|
37
39
|
def t_validate_enum(cls, value):
|
|
@@ -85,6 +87,13 @@ class SimpleWorkflowConfig(BaseModel):
|
|
|
85
87
|
# override the default output from pydantic by calling `to_dict()` of blueprint
|
|
86
88
|
if self.blueprint:
|
|
87
89
|
_dict['blueprint'] = self.blueprint.to_dict()
|
|
90
|
+
# override the default output from pydantic by calling `to_dict()` of each item in feature_flags (list)
|
|
91
|
+
_items = []
|
|
92
|
+
if self.feature_flags:
|
|
93
|
+
for _item_feature_flags in self.feature_flags:
|
|
94
|
+
if _item_feature_flags:
|
|
95
|
+
_items.append(_item_feature_flags.to_dict())
|
|
96
|
+
_dict['featureFlags'] = _items
|
|
88
97
|
return _dict
|
|
89
98
|
|
|
90
99
|
@classmethod
|
|
@@ -99,7 +108,8 @@ class SimpleWorkflowConfig(BaseModel):
|
|
|
99
108
|
_obj = cls.model_validate({
|
|
100
109
|
"_t": obj.get("_t") if obj.get("_t") is not None else 'SimpleWorkflowConfig',
|
|
101
110
|
"referee": CompareWorkflowModel1Referee.from_dict(obj["referee"]) if obj.get("referee") is not None else None,
|
|
102
|
-
"blueprint": ValidationSetZipPostRequestBlueprint.from_dict(obj["blueprint"]) if obj.get("blueprint") is not None else None
|
|
111
|
+
"blueprint": ValidationSetZipPostRequestBlueprint.from_dict(obj["blueprint"]) if obj.get("blueprint") is not None else None,
|
|
112
|
+
"featureFlags": [FeatureFlag.from_dict(_item) for _item in obj["featureFlags"]] if obj.get("featureFlags") is not None else None
|
|
103
113
|
})
|
|
104
114
|
return _obj
|
|
105
115
|
|
|
@@ -20,6 +20,7 @@ import json
|
|
|
20
20
|
from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
|
|
21
21
|
from typing import Any, ClassVar, Dict, List
|
|
22
22
|
from rapidata.api_client.models.compare_workflow_model1_referee import CompareWorkflowModel1Referee
|
|
23
|
+
from rapidata.api_client.models.feature_flag import FeatureFlag
|
|
23
24
|
from rapidata.api_client.models.simple_workflow_config_model_blueprint import SimpleWorkflowConfigModelBlueprint
|
|
24
25
|
from typing import Optional, Set
|
|
25
26
|
from typing_extensions import Self
|
|
@@ -31,8 +32,8 @@ class SimpleWorkflowConfigModel(BaseModel):
|
|
|
31
32
|
t: StrictStr = Field(description="Discriminator value for SimpleWorkflowConfig", alias="_t")
|
|
32
33
|
referee: CompareWorkflowModel1Referee
|
|
33
34
|
blueprint: SimpleWorkflowConfigModelBlueprint
|
|
34
|
-
|
|
35
|
-
__properties: ClassVar[List[str]] = ["_t", "referee", "blueprint", "
|
|
35
|
+
feature_flags: List[FeatureFlag] = Field(description="The list of feature flags that will be applied to the rapids created by this workflow.", alias="featureFlags")
|
|
36
|
+
__properties: ClassVar[List[str]] = ["_t", "referee", "blueprint", "featureFlags"]
|
|
36
37
|
|
|
37
38
|
@field_validator('t')
|
|
38
39
|
def t_validate_enum(cls, value):
|
|
@@ -86,6 +87,13 @@ class SimpleWorkflowConfigModel(BaseModel):
|
|
|
86
87
|
# override the default output from pydantic by calling `to_dict()` of blueprint
|
|
87
88
|
if self.blueprint:
|
|
88
89
|
_dict['blueprint'] = self.blueprint.to_dict()
|
|
90
|
+
# override the default output from pydantic by calling `to_dict()` of each item in feature_flags (list)
|
|
91
|
+
_items = []
|
|
92
|
+
if self.feature_flags:
|
|
93
|
+
for _item_feature_flags in self.feature_flags:
|
|
94
|
+
if _item_feature_flags:
|
|
95
|
+
_items.append(_item_feature_flags.to_dict())
|
|
96
|
+
_dict['featureFlags'] = _items
|
|
89
97
|
return _dict
|
|
90
98
|
|
|
91
99
|
@classmethod
|
|
@@ -101,7 +109,7 @@ class SimpleWorkflowConfigModel(BaseModel):
|
|
|
101
109
|
"_t": obj.get("_t") if obj.get("_t") is not None else 'SimpleWorkflowConfig',
|
|
102
110
|
"referee": CompareWorkflowModel1Referee.from_dict(obj["referee"]) if obj.get("referee") is not None else None,
|
|
103
111
|
"blueprint": SimpleWorkflowConfigModelBlueprint.from_dict(obj["blueprint"]) if obj.get("blueprint") is not None else None,
|
|
104
|
-
"
|
|
112
|
+
"featureFlags": [FeatureFlag.from_dict(_item) for _item in obj["featureFlags"]] if obj.get("featureFlags") is not None else None
|
|
105
113
|
})
|
|
106
114
|
return _obj
|
|
107
115
|
|
|
@@ -18,7 +18,8 @@ import re # noqa: F401
|
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
20
|
from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
|
|
21
|
-
from typing import Any, ClassVar, Dict, List
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from rapidata.api_client.models.feature_flag import FeatureFlag
|
|
22
23
|
from rapidata.api_client.models.simple_workflow_model_blueprint import SimpleWorkflowModelBlueprint
|
|
23
24
|
from typing import Optional, Set
|
|
24
25
|
from typing_extensions import Self
|
|
@@ -29,7 +30,8 @@ class SimpleWorkflowModel(BaseModel):
|
|
|
29
30
|
""" # noqa: E501
|
|
30
31
|
t: StrictStr = Field(description="Discriminator value for SimpleWorkflow", alias="_t")
|
|
31
32
|
blueprint: SimpleWorkflowModelBlueprint
|
|
32
|
-
|
|
33
|
+
feature_flags: Optional[List[FeatureFlag]] = Field(default=None, description="The list of feature flags that will be applied to the rapids created by this workflow.", alias="featureFlags")
|
|
34
|
+
__properties: ClassVar[List[str]] = ["_t", "blueprint", "featureFlags"]
|
|
33
35
|
|
|
34
36
|
@field_validator('t')
|
|
35
37
|
def t_validate_enum(cls, value):
|
|
@@ -80,6 +82,13 @@ class SimpleWorkflowModel(BaseModel):
|
|
|
80
82
|
# override the default output from pydantic by calling `to_dict()` of blueprint
|
|
81
83
|
if self.blueprint:
|
|
82
84
|
_dict['blueprint'] = self.blueprint.to_dict()
|
|
85
|
+
# override the default output from pydantic by calling `to_dict()` of each item in feature_flags (list)
|
|
86
|
+
_items = []
|
|
87
|
+
if self.feature_flags:
|
|
88
|
+
for _item_feature_flags in self.feature_flags:
|
|
89
|
+
if _item_feature_flags:
|
|
90
|
+
_items.append(_item_feature_flags.to_dict())
|
|
91
|
+
_dict['featureFlags'] = _items
|
|
83
92
|
return _dict
|
|
84
93
|
|
|
85
94
|
@classmethod
|
|
@@ -93,7 +102,8 @@ class SimpleWorkflowModel(BaseModel):
|
|
|
93
102
|
|
|
94
103
|
_obj = cls.model_validate({
|
|
95
104
|
"_t": obj.get("_t") if obj.get("_t") is not None else 'SimpleWorkflow',
|
|
96
|
-
"blueprint": SimpleWorkflowModelBlueprint.from_dict(obj["blueprint"]) if obj.get("blueprint") is not None else None
|
|
105
|
+
"blueprint": SimpleWorkflowModelBlueprint.from_dict(obj["blueprint"]) if obj.get("blueprint") is not None else None,
|
|
106
|
+
"featureFlags": [FeatureFlag.from_dict(_item) for _item in obj["featureFlags"]] if obj.get("featureFlags") is not None else None
|
|
97
107
|
})
|
|
98
108
|
return _obj
|
|
99
109
|
|
|
@@ -17,8 +17,9 @@ import pprint
|
|
|
17
17
|
import re # noqa: F401
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
|
-
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
21
21
|
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from rapidata.api_client.models.sort_direction import SortDirection
|
|
22
23
|
from typing import Optional, Set
|
|
23
24
|
from typing_extensions import Self
|
|
24
25
|
|
|
@@ -27,16 +28,9 @@ class SortCriterion(BaseModel):
|
|
|
27
28
|
SortCriterion
|
|
28
29
|
""" # noqa: E501
|
|
29
30
|
property_name: StrictStr = Field(alias="propertyName")
|
|
30
|
-
direction:
|
|
31
|
+
direction: SortDirection
|
|
31
32
|
__properties: ClassVar[List[str]] = ["propertyName", "direction"]
|
|
32
33
|
|
|
33
|
-
@field_validator('direction')
|
|
34
|
-
def direction_validate_enum(cls, value):
|
|
35
|
-
"""Validates the enum"""
|
|
36
|
-
if value not in set(['Asc', 'Desc']):
|
|
37
|
-
raise ValueError("must be one of enum values ('Asc', 'Desc')")
|
|
38
|
-
return value
|
|
39
|
-
|
|
40
34
|
model_config = ConfigDict(
|
|
41
35
|
populate_by_name=True,
|
|
42
36
|
validate_assignment=True,
|