label-studio-sdk 2.0.0__py3-none-any.whl → 2.0.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 label-studio-sdk might be problematic. Click here for more details.

Files changed (175) hide show
  1. label_studio_sdk/__init__.py +24 -0
  2. label_studio_sdk/actions/client.py +13 -13
  3. label_studio_sdk/actions/types/actions_list_response_item.py +3 -3
  4. label_studio_sdk/actions/types/actions_list_response_item_dialog.py +2 -2
  5. label_studio_sdk/annotations/client.py +441 -441
  6. label_studio_sdk/base_client.py +4 -0
  7. label_studio_sdk/billing/__init__.py +2 -0
  8. label_studio_sdk/billing/client.py +112 -0
  9. label_studio_sdk/comments/client.py +176 -176
  10. label_studio_sdk/export_storage/azure/client.py +274 -274
  11. label_studio_sdk/export_storage/gcs/client.py +263 -263
  12. label_studio_sdk/export_storage/local/client.py +206 -206
  13. label_studio_sdk/export_storage/redis/client.py +287 -287
  14. label_studio_sdk/export_storage/s3/client.py +347 -347
  15. label_studio_sdk/export_storage/s3s/client.py +678 -678
  16. label_studio_sdk/import_storage/azure/client.py +357 -357
  17. label_studio_sdk/import_storage/gcs/client.py +357 -357
  18. label_studio_sdk/import_storage/local/client.py +206 -206
  19. label_studio_sdk/import_storage/redis/client.py +309 -309
  20. label_studio_sdk/import_storage/s3/client.py +452 -452
  21. label_studio_sdk/import_storage/s3s/client.py +735 -735
  22. label_studio_sdk/jwt_settings/client.py +10 -10
  23. label_studio_sdk/ml/client.py +118 -118
  24. label_studio_sdk/ml/types/ml_list_model_versions_response.py +1 -1
  25. label_studio_sdk/model_providers/client.py +181 -181
  26. label_studio_sdk/organizations/members/client.py +348 -2
  27. label_studio_sdk/predictions/client.py +60 -60
  28. label_studio_sdk/projects/__init__.py +30 -1
  29. label_studio_sdk/projects/assignments/__init__.py +33 -0
  30. label_studio_sdk/projects/assignments/client.py +764 -0
  31. label_studio_sdk/projects/assignments/types/__init__.py +35 -0
  32. label_studio_sdk/projects/assignments/types/assignments_assign_request_type.py +5 -0
  33. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_filters.py +33 -0
  34. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_filters_conjunction.py +5 -0
  35. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_filters_items_item.py +44 -0
  36. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_filters_items_item_filter.py +31 -0
  37. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_filters_items_item_operator.py +23 -0
  38. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_filters_items_item_value.py +7 -0
  39. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_selected_items.py +9 -0
  40. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_selected_items_excluded.py +29 -0
  41. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_selected_items_included.py +29 -0
  42. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_request_type.py +5 -0
  43. label_studio_sdk/projects/assignments/types/assignments_bulk_assign_response.py +22 -0
  44. label_studio_sdk/projects/assignments/types/assignments_update_request_type.py +5 -0
  45. label_studio_sdk/projects/client.py +441 -425
  46. label_studio_sdk/projects/exports/client.py +55 -55
  47. label_studio_sdk/projects/exports/types/exports_convert_response.py +1 -1
  48. label_studio_sdk/projects/stats/types/stats_iaa_response.py +5 -5
  49. label_studio_sdk/projects/types/projects_import_tasks_response.py +12 -12
  50. label_studio_sdk/prompts/client.py +211 -211
  51. label_studio_sdk/prompts/runs/client.py +33 -33
  52. label_studio_sdk/prompts/versions/client.py +72 -72
  53. label_studio_sdk/tasks/client.py +174 -174
  54. label_studio_sdk/types/__init__.py +22 -0
  55. label_studio_sdk/types/all_roles_project_list.py +98 -98
  56. label_studio_sdk/types/annotation.py +35 -35
  57. label_studio_sdk/types/annotation_request.py +27 -27
  58. label_studio_sdk/types/azure_blob_export_storage.py +29 -29
  59. label_studio_sdk/types/azure_blob_import_storage.py +33 -33
  60. label_studio_sdk/types/batch_failed_predictions.py +1 -1
  61. label_studio_sdk/types/billing_checks.py +39 -0
  62. label_studio_sdk/types/billing_flags.py +44 -0
  63. label_studio_sdk/types/billing_info_response.py +22 -0
  64. label_studio_sdk/types/blueprint_list.py +7 -8
  65. label_studio_sdk/types/child_filter.py +11 -10
  66. label_studio_sdk/types/comment.py +15 -15
  67. label_studio_sdk/types/comment_request.py +7 -8
  68. label_studio_sdk/types/comment_serializer_with_expanded_user.py +17 -18
  69. label_studio_sdk/types/converted_format.py +1 -1
  70. label_studio_sdk/types/converted_format_request.py +1 -1
  71. label_studio_sdk/types/count_limit.py +22 -0
  72. label_studio_sdk/types/export.py +8 -8
  73. label_studio_sdk/types/file_upload.py +3 -2
  74. label_studio_sdk/types/filter.py +10 -9
  75. label_studio_sdk/types/filter_group.py +4 -3
  76. label_studio_sdk/types/gcs_export_storage.py +23 -23
  77. label_studio_sdk/types/gcs_import_storage.py +27 -27
  78. label_studio_sdk/types/import_api_request.py +26 -26
  79. label_studio_sdk/types/inference_run_cost_estimate.py +10 -10
  80. label_studio_sdk/types/local_files_export_storage.py +23 -23
  81. label_studio_sdk/types/local_files_import_storage.py +26 -26
  82. label_studio_sdk/types/lse_annotation_filter_options.py +10 -10
  83. label_studio_sdk/types/lse_annotation_filter_options_request.py +10 -10
  84. label_studio_sdk/types/lse_export_create.py +12 -12
  85. label_studio_sdk/types/lse_fields.py +14 -14
  86. label_studio_sdk/types/lse_organization.py +17 -17
  87. label_studio_sdk/types/lse_organization_member_list.py +32 -0
  88. label_studio_sdk/types/lse_project_create.py +72 -72
  89. label_studio_sdk/types/lse_project_update.py +89 -89
  90. label_studio_sdk/types/lse_s3export_storage.py +46 -46
  91. label_studio_sdk/types/lse_s3export_storage_request.py +43 -43
  92. label_studio_sdk/types/lse_s3import_storage.py +53 -53
  93. label_studio_sdk/types/lse_s3import_storage_request.py +49 -49
  94. label_studio_sdk/types/lse_task.py +49 -49
  95. label_studio_sdk/types/lse_task_drafts_item.py +1 -1
  96. label_studio_sdk/types/lse_task_filter_options.py +14 -14
  97. label_studio_sdk/types/lse_task_filter_options_request.py +14 -14
  98. label_studio_sdk/types/lse_task_predictions_item.py +5 -5
  99. label_studio_sdk/types/lse_task_serializer_for_annotators.py +12 -12
  100. label_studio_sdk/types/lse_task_serializer_for_annotators_drafts_item.py +1 -1
  101. label_studio_sdk/types/lse_task_serializer_for_annotators_predictions_item.py +5 -5
  102. label_studio_sdk/types/lse_task_serializer_for_reviewers.py +49 -49
  103. label_studio_sdk/types/lse_task_serializer_for_reviewers_drafts_item.py +1 -1
  104. label_studio_sdk/types/lse_task_serializer_for_reviewers_predictions_item.py +5 -5
  105. label_studio_sdk/types/lse_user.py +13 -13
  106. label_studio_sdk/types/lse_user_api.py +11 -11
  107. label_studio_sdk/types/lse_user_organization_member_list.py +48 -0
  108. label_studio_sdk/types/lseapi_token_create.py +1 -1
  109. label_studio_sdk/types/lseapi_token_list.py +1 -1
  110. label_studio_sdk/types/lsejwt_settings.py +5 -5
  111. label_studio_sdk/types/ml_backend.py +27 -28
  112. label_studio_sdk/types/model_interface.py +12 -12
  113. label_studio_sdk/types/model_interface_request.py +7 -8
  114. label_studio_sdk/types/model_interface_serializer_get.py +13 -13
  115. label_studio_sdk/types/model_provider_connection.py +34 -34
  116. label_studio_sdk/types/model_provider_connection_request.py +15 -14
  117. label_studio_sdk/types/model_run.py +12 -12
  118. label_studio_sdk/types/organization_billing.py +1 -1
  119. label_studio_sdk/types/organization_id.py +2 -2
  120. label_studio_sdk/types/organization_invite.py +1 -1
  121. label_studio_sdk/types/organization_member.py +8 -9
  122. label_studio_sdk/types/organization_membership.py +2 -1
  123. label_studio_sdk/types/paginated_lse_organization_member_list_list.py +23 -0
  124. label_studio_sdk/types/pause.py +23 -23
  125. label_studio_sdk/types/prediction.py +21 -21
  126. label_studio_sdk/types/prediction_request.py +16 -16
  127. label_studio_sdk/types/project.py +72 -72
  128. label_studio_sdk/types/project_import.py +21 -21
  129. label_studio_sdk/types/prompts_status_enum.py +16 -0
  130. label_studio_sdk/types/redis_export_storage.py +34 -34
  131. label_studio_sdk/types/redis_import_storage.py +37 -37
  132. label_studio_sdk/types/refined_prompt_response.py +11 -11
  133. label_studio_sdk/types/review_settings.py +29 -30
  134. label_studio_sdk/types/review_settings_request.py +29 -30
  135. label_studio_sdk/types/role9e7enum.py +5 -0
  136. label_studio_sdk/types/s3export_storage.py +45 -45
  137. label_studio_sdk/types/s3import_storage.py +44 -44
  138. label_studio_sdk/types/selected_items_request.py +1 -1
  139. label_studio_sdk/types/serialization_options.py +10 -10
  140. label_studio_sdk/types/serialization_options_request.py +10 -10
  141. label_studio_sdk/types/task_assignment.py +43 -0
  142. label_studio_sdk/types/third_party_model_version.py +11 -11
  143. label_studio_sdk/types/third_party_model_version_request.py +6 -7
  144. label_studio_sdk/types/type_enum.py +5 -0
  145. label_studio_sdk/types/user_simple.py +3 -3
  146. label_studio_sdk/types/user_simple_request.py +1 -1
  147. label_studio_sdk/types/version_response.py +19 -20
  148. label_studio_sdk/types/view.py +8 -8
  149. label_studio_sdk/types/webhook.py +16 -16
  150. label_studio_sdk/types/webhook_serializer_for_update.py +16 -16
  151. label_studio_sdk/types/workspace.py +10 -11
  152. label_studio_sdk/users/client.py +160 -160
  153. label_studio_sdk/views/client.py +164 -164
  154. label_studio_sdk/webhooks/client.py +183 -183
  155. label_studio_sdk/webhooks/types/webhooks_info_response.py +32 -32
  156. label_studio_sdk/webhooks/types/webhooks_info_response_annotation_created.py +1 -1
  157. label_studio_sdk/webhooks/types/webhooks_info_response_annotation_updated.py +1 -1
  158. label_studio_sdk/webhooks/types/webhooks_info_response_annotations_created.py +1 -1
  159. label_studio_sdk/webhooks/types/webhooks_info_response_annotations_deleted.py +1 -1
  160. label_studio_sdk/webhooks/types/webhooks_info_response_label_link_created.py +1 -1
  161. label_studio_sdk/webhooks/types/webhooks_info_response_label_link_deleted.py +1 -1
  162. label_studio_sdk/webhooks/types/webhooks_info_response_label_link_updated.py +1 -1
  163. label_studio_sdk/webhooks/types/webhooks_info_response_project_created.py +1 -1
  164. label_studio_sdk/webhooks/types/webhooks_info_response_project_deleted.py +1 -1
  165. label_studio_sdk/webhooks/types/webhooks_info_response_project_updated.py +1 -1
  166. label_studio_sdk/webhooks/types/webhooks_info_response_review_created.py +1 -1
  167. label_studio_sdk/webhooks/types/webhooks_info_response_review_updated.py +1 -1
  168. label_studio_sdk/webhooks/types/webhooks_info_response_reviews_deleted.py +1 -1
  169. label_studio_sdk/webhooks/types/webhooks_info_response_tasks_created.py +1 -1
  170. label_studio_sdk/webhooks/types/webhooks_info_response_tasks_deleted.py +1 -1
  171. label_studio_sdk/workspaces/client.py +40 -40
  172. {label_studio_sdk-2.0.0.dist-info → label_studio_sdk-2.0.2.dist-info}/METADATA +73 -25
  173. {label_studio_sdk-2.0.0.dist-info → label_studio_sdk-2.0.2.dist-info}/RECORD +175 -146
  174. {label_studio_sdk-2.0.0.dist-info → label_studio_sdk-2.0.2.dist-info}/LICENSE +0 -0
  175. {label_studio_sdk-2.0.0.dist-info → label_studio_sdk-2.0.2.dist-info}/WHEEL +0 -0
@@ -8,21 +8,11 @@ from ..core.pydantic_utilities import IS_PYDANTIC_V2
8
8
 
9
9
 
10
10
  class LseAnnotationFilterOptionsRequest(UncheckedBaseModel):
11
- usual: typing.Optional[bool] = pydantic.Field(default=None)
12
- """
13
- Include not skipped and not ground truth annotations
14
- """
15
-
16
11
  ground_truth: typing.Optional[bool] = pydantic.Field(default=None)
17
12
  """
18
13
  Include ground truth annotations
19
14
  """
20
15
 
21
- skipped: typing.Optional[bool] = pydantic.Field(default=None)
22
- """
23
- Include skipped annotations
24
- """
25
-
26
16
  reviewed: typing.Optional[LseAnnotationFilterOptionsRequestReviewed] = pydantic.Field(default=None)
27
17
  """
28
18
  `only` - include all tasks with at least one not reviewed annotation<br>`exclude` - exclude with at least one not reviewed annotation
@@ -32,6 +22,16 @@ class LseAnnotationFilterOptionsRequest(UncheckedBaseModel):
32
22
  * `None` - None
33
23
  """
34
24
 
25
+ skipped: typing.Optional[bool] = pydantic.Field(default=None)
26
+ """
27
+ Include skipped annotations
28
+ """
29
+
30
+ usual: typing.Optional[bool] = pydantic.Field(default=None)
31
+ """
32
+ Include not skipped and not ground truth annotations
33
+ """
34
+
35
35
  if IS_PYDANTIC_V2:
36
36
  model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
37
37
  else:
@@ -2,38 +2,38 @@
2
2
 
3
3
  from ..core.unchecked_base_model import UncheckedBaseModel
4
4
  import typing
5
- from .user_simple import UserSimple
5
+ from .lse_annotation_filter_options import LseAnnotationFilterOptions
6
+ from .converted_format import ConvertedFormat
6
7
  import datetime as dt
7
8
  import pydantic
9
+ from .user_simple import UserSimple
10
+ from .serialization_options import SerializationOptions
8
11
  from .status7bf_enum import Status7BfEnum
9
- from .converted_format import ConvertedFormat
10
12
  from .lse_task_filter_options import LseTaskFilterOptions
11
- from .lse_annotation_filter_options import LseAnnotationFilterOptions
12
- from .serialization_options import SerializationOptions
13
13
  from ..core.pydantic_utilities import IS_PYDANTIC_V2
14
14
 
15
15
 
16
16
  class LseExportCreate(UncheckedBaseModel):
17
- title: typing.Optional[str] = None
18
- id: int
19
- created_by: typing.Optional[UserSimple] = None
17
+ annotation_filter_options: typing.Optional[LseAnnotationFilterOptions] = None
18
+ converted_formats: typing.Optional[typing.List[ConvertedFormat]] = None
19
+ counters: typing.Optional[typing.Optional[typing.Any]] = None
20
20
  created_at: dt.datetime = pydantic.Field()
21
21
  """
22
22
  Creation time
23
23
  """
24
24
 
25
+ created_by: typing.Optional[UserSimple] = None
25
26
  finished_at: typing.Optional[dt.datetime] = pydantic.Field(default=None)
26
27
  """
27
28
  Complete or fail time
28
29
  """
29
30
 
30
- status: typing.Optional[Status7BfEnum] = None
31
+ id: int
31
32
  md5: typing.Optional[str] = None
32
- counters: typing.Optional[typing.Optional[typing.Any]] = None
33
- converted_formats: typing.Optional[typing.List[ConvertedFormat]] = None
34
- task_filter_options: typing.Optional[LseTaskFilterOptions] = None
35
- annotation_filter_options: typing.Optional[LseAnnotationFilterOptions] = None
36
33
  serialization_options: typing.Optional[SerializationOptions] = None
34
+ status: typing.Optional[Status7BfEnum] = None
35
+ task_filter_options: typing.Optional[LseTaskFilterOptions] = None
36
+ title: typing.Optional[str] = None
37
37
 
38
38
  if IS_PYDANTIC_V2:
39
39
  model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -3,27 +3,18 @@
3
3
  from ..core.unchecked_base_model import UncheckedBaseModel
4
4
  import typing
5
5
  import datetime as dt
6
- from .lse_fields_trial_role import LseFieldsTrialRole
7
- import pydantic
8
6
  from .lse_fields_onboarding_state import LseFieldsOnboardingState
7
+ import pydantic
8
+ from .lse_fields_trial_role import LseFieldsTrialRole
9
9
  from ..core.pydantic_utilities import IS_PYDANTIC_V2
10
10
 
11
11
 
12
12
  class LseFields(UncheckedBaseModel):
13
+ email_notification_settings: str
14
+ invite_activated: typing.Optional[bool] = None
13
15
  invite_expired: str
14
16
  invite_expired_at: str
15
17
  invited_at: typing.Optional[dt.datetime] = None
16
- invite_activated: typing.Optional[bool] = None
17
- trial_company: typing.Optional[str] = None
18
- trial_role: typing.Optional[LseFieldsTrialRole] = None
19
- trial_models_in_production: typing.Optional[str] = None
20
- trial_experience_labeling: typing.Optional[str] = None
21
- trial_license_enterprise: typing.Optional[bool] = None
22
- social_auth_finished: typing.Optional[bool] = pydantic.Field(default=None)
23
- """
24
- Is user finished social authentication
25
- """
26
-
27
18
  invited_by: typing.Optional[int] = None
28
19
  onboarding_state: typing.Optional[LseFieldsOnboardingState] = pydantic.Field(default=None)
29
20
  """
@@ -37,7 +28,16 @@ class LseFields(UncheckedBaseModel):
37
28
  * `complete` - Complete
38
29
  """
39
30
 
40
- email_notification_settings: str
31
+ social_auth_finished: typing.Optional[bool] = pydantic.Field(default=None)
32
+ """
33
+ Is user finished social authentication
34
+ """
35
+
36
+ trial_company: typing.Optional[str] = None
37
+ trial_experience_labeling: typing.Optional[str] = None
38
+ trial_license_enterprise: typing.Optional[bool] = None
39
+ trial_models_in_production: typing.Optional[str] = None
40
+ trial_role: typing.Optional[LseFieldsTrialRole] = None
41
41
 
42
42
  if IS_PYDANTIC_V2:
43
43
  model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -1,24 +1,27 @@
1
1
  # This file was auto-generated by Fern from our API Definition.
2
2
 
3
3
  from ..core.unchecked_base_model import UncheckedBaseModel
4
+ from .organization_billing import OrganizationBilling
5
+ import datetime as dt
4
6
  import typing
7
+ from .lse_organization_custom_scripts_editable_by import LseOrganizationCustomScriptsEditableBy
5
8
  import pydantic
6
9
  from .default_role_enum import DefaultRoleEnum
7
- import datetime as dt
8
- from .organization_billing import OrganizationBilling
9
- from .lse_organization_custom_scripts_editable_by import LseOrganizationCustomScriptsEditableBy
10
10
  from ..core.pydantic_utilities import IS_PYDANTIC_V2
11
11
 
12
12
 
13
13
  class LseOrganization(UncheckedBaseModel):
14
- id: int
15
- external_id: typing.Optional[str] = pydantic.Field(default=None)
14
+ billing: OrganizationBilling
15
+ created_at: dt.datetime
16
+ custom_scripts_editable_by: typing.Optional[LseOrganizationCustomScriptsEditableBy] = pydantic.Field(default=None)
16
17
  """
17
- External ID to uniquely identify this organization
18
+ Set the minimum user role that can edit custom scripts in the UI.
19
+
20
+ * `AD` - Administrator
21
+ * `MA` - Manager
18
22
  """
19
23
 
20
- title: str
21
- token: str
24
+ custom_scripts_enabled: str
22
25
  default_role: typing.Optional[DefaultRoleEnum] = pydantic.Field(default=None)
23
26
  """
24
27
  Default membership role for invited users
@@ -32,20 +35,17 @@ class LseOrganization(UncheckedBaseModel):
32
35
  * `NO` - Not Activated
33
36
  """
34
37
 
35
- created_at: dt.datetime
36
- billing: OrganizationBilling
38
+ email_notification_settings: str
37
39
  embed_domains: typing.Optional[typing.Optional[typing.Any]] = None
38
40
  embed_settings: typing.Optional[typing.Optional[typing.Any]] = None
39
- custom_scripts_enabled: str
40
- custom_scripts_editable_by: typing.Optional[LseOrganizationCustomScriptsEditableBy] = pydantic.Field(default=None)
41
+ external_id: typing.Optional[str] = pydantic.Field(default=None)
41
42
  """
42
- Set the minimum user role that can edit custom scripts in the UI.
43
-
44
- * `AD` - Administrator
45
- * `MA` - Manager
43
+ External ID to uniquely identify this organization
46
44
  """
47
45
 
48
- email_notification_settings: str
46
+ id: int
47
+ title: str
48
+ token: str
49
49
 
50
50
  if IS_PYDANTIC_V2:
51
51
  model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -0,0 +1,32 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from ..core.unchecked_base_model import UncheckedBaseModel
4
+ import pydantic
5
+ from .lse_user_organization_member_list import LseUserOrganizationMemberList
6
+ from ..core.pydantic_utilities import IS_PYDANTIC_V2
7
+ import typing
8
+
9
+
10
+ class LseOrganizationMemberList(UncheckedBaseModel):
11
+ """
12
+ A serializer mixin that takes an additional `fields` argument that controls
13
+ which fields should be displayed.
14
+ """
15
+
16
+ id: int
17
+ organization: int = pydantic.Field()
18
+ """
19
+ Organization ID
20
+ """
21
+
22
+ role: str
23
+ user: LseUserOrganizationMemberList
24
+
25
+ if IS_PYDANTIC_V2:
26
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
27
+ else:
28
+
29
+ class Config:
30
+ frozen = True
31
+ smart_union = True
32
+ extra = pydantic.Extra.allow
@@ -3,8 +3,8 @@
3
3
  from ..core.unchecked_base_model import UncheckedBaseModel
4
4
  import typing
5
5
  import pydantic
6
- from .user_simple import UserSimple
7
6
  import datetime as dt
7
+ from .user_simple import UserSimple
8
8
  from .lse_project_create_sampling import LseProjectCreateSampling
9
9
  from .lse_project_create_skip_queue import LseProjectCreateSkipQueue
10
10
  from ..core.pydantic_utilities import IS_PYDANTIC_V2
@@ -16,10 +16,22 @@ class LseProjectCreate(UncheckedBaseModel):
16
16
  make sure, that you use correct one(Project.objects.with_counts())
17
17
  """
18
18
 
19
- id: int
20
- title: typing.Optional[str] = pydantic.Field(default=None)
19
+ color: typing.Optional[str] = None
20
+ config_has_control_tags: bool = pydantic.Field()
21
21
  """
22
- Project name. Must be between 3 and 50 characters long.
22
+ Flag to detect is project ready for labeling
23
+ """
24
+
25
+ config_suitable_for_bulk_annotation: bool = pydantic.Field()
26
+ """
27
+ Flag to detect is project ready for bulk annotation
28
+ """
29
+
30
+ control_weights: typing.Optional[typing.Optional[typing.Any]] = None
31
+ created_at: dt.datetime
32
+ created_by: typing.Optional[UserSimple] = pydantic.Field(default=None)
33
+ """
34
+ Project owner
23
35
  """
24
36
 
25
37
  description: typing.Optional[str] = pydantic.Field(default=None)
@@ -27,9 +39,14 @@ class LseProjectCreate(UncheckedBaseModel):
27
39
  Project description
28
40
  """
29
41
 
30
- label_config: typing.Optional[str] = pydantic.Field(default=None)
42
+ enable_empty_annotation: typing.Optional[bool] = pydantic.Field(default=None)
31
43
  """
32
- Label config in XML format. See more about it in documentation
44
+ Allow annotators to submit empty annotations
45
+ """
46
+
47
+ evaluate_predictions_automatically: typing.Optional[bool] = pydantic.Field(default=None)
48
+ """
49
+ Retrieve and display predictions when loading a task
33
50
  """
34
51
 
35
52
  expert_instruction: typing.Optional[str] = pydantic.Field(default=None)
@@ -37,36 +54,40 @@ class LseProjectCreate(UncheckedBaseModel):
37
54
  Labeling instructions in HTML format
38
55
  """
39
56
 
40
- show_instruction: typing.Optional[bool] = pydantic.Field(default=None)
57
+ finished_task_number: int = pydantic.Field()
41
58
  """
42
- Show instructions to the annotator before they start
59
+ Finished tasks
43
60
  """
44
61
 
45
- show_skip_button: typing.Optional[bool] = pydantic.Field(default=None)
62
+ ground_truth_number: int = pydantic.Field()
46
63
  """
47
- Show a skip button in interface and allow annotators to skip the task
64
+ Honeypot annotation number in project
48
65
  """
49
66
 
50
- enable_empty_annotation: typing.Optional[bool] = pydantic.Field(default=None)
67
+ id: int
68
+ is_draft: typing.Optional[bool] = pydantic.Field(default=None)
51
69
  """
52
- Allow annotators to submit empty annotations
70
+ Whether or not the project is in the middle of being created
53
71
  """
54
72
 
55
- show_annotation_history: typing.Optional[bool] = pydantic.Field(default=None)
73
+ is_published: typing.Optional[bool] = pydantic.Field(default=None)
56
74
  """
57
- Show annotation history to annotator
75
+ Whether or not the project is published to annotators
76
+ """
77
+
78
+ label_config: typing.Optional[str] = pydantic.Field(default=None)
79
+ """
80
+ Label config in XML format. See more about it in documentation
58
81
  """
59
82
 
60
- organization: typing.Optional[int] = None
61
- color: typing.Optional[str] = None
62
83
  maximum_annotations: typing.Optional[int] = pydantic.Field(default=None)
63
84
  """
64
85
  Maximum number of annotations for one task. If the number of annotations per task is equal or greater to this value, the task is completed (is_labeled=True)
65
86
  """
66
87
 
67
- is_published: typing.Optional[bool] = pydantic.Field(default=None)
88
+ min_annotations_to_start_training: typing.Optional[int] = pydantic.Field(default=None)
68
89
  """
69
- Whether or not the project is published to annotators
90
+ Minimum number of completed tasks after which model training is started
70
91
  """
71
92
 
72
93
  model_version: typing.Optional[str] = pydantic.Field(default=None)
@@ -74,25 +95,30 @@ class LseProjectCreate(UncheckedBaseModel):
74
95
  Machine learning model version
75
96
  """
76
97
 
77
- is_draft: typing.Optional[bool] = pydantic.Field(default=None)
98
+ num_tasks_with_annotations: int = pydantic.Field()
78
99
  """
79
- Whether or not the project is in the middle of being created
100
+ Tasks with annotations count
80
101
  """
81
102
 
82
- created_by: typing.Optional[UserSimple] = pydantic.Field(default=None)
103
+ organization: typing.Optional[int] = None
104
+ overlap_cohort_percentage: typing.Optional[int] = None
105
+ parsed_label_config: typing.Optional[typing.Any] = None
106
+ pinned_at: typing.Optional[dt.datetime] = pydantic.Field(default=None)
83
107
  """
84
- Project owner
108
+ Pinned date and time
85
109
  """
86
110
 
87
- created_at: dt.datetime
88
- min_annotations_to_start_training: typing.Optional[int] = pydantic.Field(default=None)
111
+ queue_done: int
112
+ queue_total: int
113
+ reveal_preannotations_interactively: typing.Optional[bool] = pydantic.Field(default=None)
89
114
  """
90
- Minimum number of completed tasks after which model training is started
115
+ Reveal pre-annotations interactively
91
116
  """
92
117
 
93
- start_training_on_annotation_update: bool = pydantic.Field()
118
+ sampling: typing.Optional[LseProjectCreateSampling] = None
119
+ show_annotation_history: typing.Optional[bool] = pydantic.Field(default=None)
94
120
  """
95
- Start model training after any annotations are submitted or updated
121
+ Show annotation history to annotator
96
122
  """
97
123
 
98
124
  show_collab_predictions: typing.Optional[bool] = pydantic.Field(default=None)
@@ -100,45 +126,29 @@ class LseProjectCreate(UncheckedBaseModel):
100
126
  If set, the annotator can view model predictions
101
127
  """
102
128
 
103
- num_tasks_with_annotations: int = pydantic.Field()
104
- """
105
- Tasks with annotations count
106
- """
107
-
108
- task_number: int = pydantic.Field()
109
- """
110
- Total task number in project
111
- """
112
-
113
- useful_annotation_number: int = pydantic.Field()
129
+ show_ground_truth_first: typing.Optional[bool] = None
130
+ show_instruction: typing.Optional[bool] = pydantic.Field(default=None)
114
131
  """
115
- Useful annotation number in project not including skipped_annotations_number and ground_truth_number. Total annotations = annotation_number + skipped_annotations_number + ground_truth_number
132
+ Show instructions to the annotator before they start
116
133
  """
117
134
 
118
- ground_truth_number: int = pydantic.Field()
135
+ show_overlap_first: typing.Optional[bool] = None
136
+ show_skip_button: typing.Optional[bool] = pydantic.Field(default=None)
119
137
  """
120
- Honeypot annotation number in project
138
+ Show a skip button in interface and allow annotators to skip the task
121
139
  """
122
140
 
141
+ skip_queue: typing.Optional[LseProjectCreateSkipQueue] = None
123
142
  skipped_annotations_number: int = pydantic.Field()
124
143
  """
125
144
  Skipped by collaborators annotation number in project
126
145
  """
127
146
 
128
- total_annotations_number: int = pydantic.Field()
129
- """
130
- Total annotations number in project including skipped_annotations_number and ground_truth_number.
131
- """
132
-
133
- total_predictions_number: int = pydantic.Field()
147
+ start_training_on_annotation_update: bool = pydantic.Field()
134
148
  """
135
- Total predictions number in project including skipped_annotations_number, ground_truth_number, and useful_annotation_number.
149
+ Start model training after any annotations are submitted or updated
136
150
  """
137
151
 
138
- sampling: typing.Optional[LseProjectCreateSampling] = None
139
- show_ground_truth_first: typing.Optional[bool] = None
140
- show_overlap_first: typing.Optional[bool] = None
141
- overlap_cohort_percentage: typing.Optional[int] = None
142
152
  task_data_login: typing.Optional[str] = pydantic.Field(default=None)
143
153
  """
144
154
  Task data credentials: login
@@ -149,39 +159,29 @@ class LseProjectCreate(UncheckedBaseModel):
149
159
  Task data credentials: password
150
160
  """
151
161
 
152
- control_weights: typing.Optional[typing.Optional[typing.Any]] = None
153
- parsed_label_config: typing.Optional[typing.Any] = None
154
- evaluate_predictions_automatically: typing.Optional[bool] = pydantic.Field(default=None)
155
- """
156
- Retrieve and display predictions when loading a task
157
- """
158
-
159
- config_has_control_tags: bool = pydantic.Field()
162
+ task_number: int = pydantic.Field()
160
163
  """
161
- Flag to detect is project ready for labeling
164
+ Total task number in project
162
165
  """
163
166
 
164
- skip_queue: typing.Optional[LseProjectCreateSkipQueue] = None
165
- reveal_preannotations_interactively: typing.Optional[bool] = pydantic.Field(default=None)
167
+ title: typing.Optional[str] = pydantic.Field(default=None)
166
168
  """
167
- Reveal pre-annotations interactively
169
+ Project name. Must be between 3 and 50 characters long.
168
170
  """
169
171
 
170
- pinned_at: typing.Optional[dt.datetime] = pydantic.Field(default=None)
172
+ total_annotations_number: int = pydantic.Field()
171
173
  """
172
- Pinned date and time
174
+ Total annotations number in project including skipped_annotations_number and ground_truth_number.
173
175
  """
174
176
 
175
- finished_task_number: int = pydantic.Field()
177
+ total_predictions_number: int = pydantic.Field()
176
178
  """
177
- Finished tasks
179
+ Total predictions number in project including skipped_annotations_number, ground_truth_number, and useful_annotation_number.
178
180
  """
179
181
 
180
- queue_total: int
181
- queue_done: int
182
- config_suitable_for_bulk_annotation: bool = pydantic.Field()
182
+ useful_annotation_number: int = pydantic.Field()
183
183
  """
184
- Flag to detect is project ready for bulk annotation
184
+ Useful annotation number in project not including skipped_annotations_number and ground_truth_number. Total annotations = annotation_number + skipped_annotations_number + ground_truth_number
185
185
  """
186
186
 
187
187
  workspace: typing.Optional[int] = None