superannotate 4.4.28__tar.gz → 4.4.29.dev1__tar.gz

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.
Files changed (142) hide show
  1. {superannotate-4.4.28/src/superannotate.egg-info → superannotate-4.4.29.dev1}/PKG-INFO +1 -1
  2. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/__init__.py +1 -1
  3. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/sdk_interface.py +59 -4
  4. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/controller.py +12 -1
  5. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/item_service.py +1 -1
  6. {superannotate-4.4.28 → superannotate-4.4.29.dev1/src/superannotate.egg-info}/PKG-INFO +1 -1
  7. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/LICENSE +0 -0
  8. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/MANIFEST.in +0 -0
  9. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/README.rst +0 -0
  10. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/requirements.txt +0 -0
  11. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/setup.cfg +0 -0
  12. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/setup.py +0 -0
  13. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/__init__.py +0 -0
  14. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/__init__.py +0 -0
  15. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/analytics/__init__.py +0 -0
  16. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/analytics/aggregators.py +0 -0
  17. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/analytics/common.py +0 -0
  18. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/bin/__init__.py +0 -0
  19. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/bin/superannotate.py +0 -0
  20. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/common.py +0 -0
  21. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/exceptions.py +0 -0
  22. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/helpers.py +0 -0
  23. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/__init__.py +0 -0
  24. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/conversion.py +0 -0
  25. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/__init__.py +0 -0
  26. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/baseStrategy.py +0 -0
  27. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/__init__.py +0 -0
  28. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/coco_api.py +0 -0
  29. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/coco_converter.py +0 -0
  30. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/coco_strategies.py +0 -0
  31. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/coco_to_sa_pixel.py +0 -0
  32. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/coco_to_sa_vector.py +0 -0
  33. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/sa_pixel_to_coco.py +0 -0
  34. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/coco_converters/sa_vector_to_coco.py +0 -0
  35. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/converters.py +0 -0
  36. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/dataloop_converters/__init__.py +0 -0
  37. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/dataloop_converters/dataloop_helper.py +0 -0
  38. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/dataloop_converters/dataloop_strategies.py +0 -0
  39. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/dataloop_converters/dataloop_to_sa_vector.py +0 -0
  40. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/googlecloud_converters/__init__.py +0 -0
  41. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/googlecloud_converters/googlecloud_strategies.py +0 -0
  42. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/googlecloud_converters/googlecloud_to_sa_vector.py +0 -0
  43. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/labelbox_converters/__init__.py +0 -0
  44. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/labelbox_converters/labelbox_helper.py +0 -0
  45. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/labelbox_converters/labelbox_strategies.py +0 -0
  46. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/labelbox_converters/labelbox_to_sa_pixel.py +0 -0
  47. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/labelbox_converters/labelbox_to_sa_vector.py +0 -0
  48. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/sa_json_helper.py +0 -0
  49. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/sagemaker_converters/__init__.py +0 -0
  50. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/sagemaker_converters/sagemaker_strategies.py +0 -0
  51. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/sagemaker_converters/sagemaker_to_sa_pixel.py +0 -0
  52. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/sagemaker_converters/sagemaker_to_sa_vector.py +0 -0
  53. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/supervisely_converters/__init__.py +0 -0
  54. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/supervisely_converters/supervisely_helper.py +0 -0
  55. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/supervisely_converters/supervisely_strategies.py +0 -0
  56. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/supervisely_converters/supervisely_to_sa_pixel.py +0 -0
  57. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/supervisely_converters/supervisely_to_sa_vector.py +0 -0
  58. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/vgg_converters/__init__.py +0 -0
  59. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/vgg_converters/vgg_helper.py +0 -0
  60. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/vgg_converters/vgg_strategies.py +0 -0
  61. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/vgg_converters/vgg_to_sa_vector.py +0 -0
  62. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/voc_converters/__init__.py +0 -0
  63. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/voc_converters/voc_helper.py +0 -0
  64. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/voc_converters/voc_strategies.py +0 -0
  65. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/voc_converters/voc_to_sa_pixel.py +0 -0
  66. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/voc_converters/voc_to_sa_vector.py +0 -0
  67. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/vott_converters/__init__.py +0 -0
  68. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/vott_converters/vott_strategies.py +0 -0
  69. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/vott_converters/vott_to_sa_vector.py +0 -0
  70. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/yolo_converters/__init__.py +0 -0
  71. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/yolo_converters/yolo_strategies.py +0 -0
  72. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/converters/yolo_converters/yolo_to_sa_vector.py +0 -0
  73. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/export_from_sa_conversions.py +0 -0
  74. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/import_to_sa_conversions.py +0 -0
  75. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/input_converters/sa_conversion.py +0 -0
  76. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/__init__.py +0 -0
  77. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/base_interface.py +0 -0
  78. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/cli_interface.py +0 -0
  79. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/sdk/__init__.py +0 -0
  80. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/sdk/folders.py +0 -0
  81. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/sdk/project.py +0 -0
  82. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/interface/types.py +0 -0
  83. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/app/serializers.py +0 -0
  84. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/__init__.py +0 -0
  85. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/base_usecases.py +0 -0
  86. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/conditions.py +0 -0
  87. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/config.py +0 -0
  88. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/__init__.py +0 -0
  89. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/base.py +0 -0
  90. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/classes.py +0 -0
  91. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/folder.py +0 -0
  92. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/integrations.py +0 -0
  93. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/items.py +0 -0
  94. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/project.py +0 -0
  95. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/entities/project_entities.py +0 -0
  96. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/enums.py +0 -0
  97. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/exceptions.py +0 -0
  98. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/jsx_conditions.py +0 -0
  99. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/plugin.py +0 -0
  100. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/pydantic_v1.py +0 -0
  101. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/reporter.py +0 -0
  102. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/repositories.py +0 -0
  103. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/response.py +0 -0
  104. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/service_types.py +0 -0
  105. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/serviceproviders.py +0 -0
  106. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/types.py +0 -0
  107. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/__init__.py +0 -0
  108. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/annotations.py +0 -0
  109. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/base.py +0 -0
  110. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/classes.py +0 -0
  111. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/custom_fields.py +0 -0
  112. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/folders.py +0 -0
  113. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/images.py +0 -0
  114. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/integrations.py +0 -0
  115. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/items.py +0 -0
  116. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/models.py +0 -0
  117. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/usecases/projects.py +0 -0
  118. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/utils.py +0 -0
  119. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/core/video_convertor.py +0 -0
  120. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/__init__.py +0 -0
  121. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/annotation_adapter.py +0 -0
  122. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/helpers.py +0 -0
  123. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/repositories.py +0 -0
  124. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/serviceprovider.py +0 -0
  125. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/__init__.py +0 -0
  126. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/annotation.py +0 -0
  127. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/annotation_class.py +0 -0
  128. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/explore.py +0 -0
  129. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/folder.py +0 -0
  130. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/http_client.py +0 -0
  131. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/integration.py +0 -0
  132. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/item.py +0 -0
  133. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/project.py +0 -0
  134. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/services/work_management.py +0 -0
  135. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/stream_data_handler.py +0 -0
  136. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/utils.py +0 -0
  137. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate/lib/infrastructure/validators.py +0 -0
  138. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate.egg-info/SOURCES.txt +0 -0
  139. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate.egg-info/dependency_links.txt +0 -0
  140. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate.egg-info/entry_points.txt +0 -0
  141. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate.egg-info/requires.txt +0 -0
  142. {superannotate-4.4.28 → superannotate-4.4.29.dev1}/src/superannotate.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: superannotate
3
- Version: 4.4.28
3
+ Version: 4.4.29.dev1
4
4
  Summary: Python SDK to SuperAnnotate platform
5
5
  Home-page: https://github.com/superannotateai/superannotate-python-sdk
6
6
  Author: SuperAnnotate AI
@@ -3,7 +3,7 @@ import os
3
3
  import sys
4
4
 
5
5
 
6
- __version__ = "4.4.28"
6
+ __version__ = "4.4.29dev1"
7
7
 
8
8
  os.environ.update({"sa_version": __version__})
9
9
  sys.path.append(os.path.split(os.path.realpath(__file__))[0])
@@ -5,6 +5,7 @@ import json
5
5
  import logging
6
6
  import os
7
7
  import sys
8
+ import typing
8
9
  import warnings
9
10
  from pathlib import Path
10
11
  from typing import Any
@@ -277,6 +278,55 @@ class SAClient(BaseInterfaceFacade, metaclass=TrackableMeta):
277
278
  response = self.controller.get_team()
278
279
  return TeamSerializer(response.data).serialize()
279
280
 
281
+ def get_component_config(self, project: Union[NotEmptyStr, int], component_id: str):
282
+ """
283
+ Retrieves the configuration for a given project and component ID.
284
+
285
+ :param project: The identifier of the project, which can be a string or an integer representing the project ID.
286
+ :type project: Union[str, int]
287
+
288
+ :param component_id: The ID of the component for which the context is to be retrieved.
289
+ :type component_id: str
290
+
291
+ :return: The context associated with the `webComponent`.
292
+ :rtype: Any
293
+
294
+ :raises AppException: If the project type is not `MULTIMODAL` or no `webComponent` context is found.
295
+ """
296
+
297
+ def retrieve_context(
298
+ component_data: List[dict], component_pk: str
299
+ ) -> Tuple[bool, typing.Any]:
300
+ for component in component_data:
301
+ if (
302
+ component["type"] == "webComponent"
303
+ and component["id"] == component_pk
304
+ ):
305
+ return True, component.get("context")
306
+ if component["type"] == "group" and "children" in component:
307
+ found, val = retrieve_context(component["children"], component_pk)
308
+ if found:
309
+ return found, val
310
+ return False, None
311
+
312
+ project = (
313
+ self.controller.get_project_by_id(project).data
314
+ if isinstance(project, int)
315
+ else self.controller.get_project(project)
316
+ )
317
+ if project.type != ProjectType.MULTIMODAL:
318
+ raise AppException(
319
+ "This function is only supported for Multimodal projects."
320
+ )
321
+
322
+ editor_template = self.controller.projects.get_editor_template(project)
323
+ components = editor_template.get("components", [])
324
+
325
+ _found, _context = retrieve_context(components, component_id)
326
+ if not _found:
327
+ raise AppException("No component context found for project.")
328
+ return _context
329
+
280
330
  def search_team_contributors(
281
331
  self,
282
332
  email: EmailStr = None,
@@ -2700,7 +2750,7 @@ class SAClient(BaseInterfaceFacade, metaclass=TrackableMeta):
2700
2750
  ]
2701
2751
  """
2702
2752
  project, folder = self.controller.get_project_folder_by_path(project)
2703
- query_kwargs = {}
2753
+ query_kwargs = {"include": ["assignments"]}
2704
2754
  if name_contains:
2705
2755
  query_kwargs["name__contains"] = name_contains
2706
2756
  if annotation_status:
@@ -2718,7 +2768,9 @@ class SAClient(BaseInterfaceFacade, metaclass=TrackableMeta):
2718
2768
  f"{project.name}{f'/{folder.name}' if not folder.is_root else ''}"
2719
2769
  )
2720
2770
  _items = self.controller.items.list_items(
2721
- project, folder, **query_kwargs
2771
+ project,
2772
+ folder,
2773
+ **query_kwargs,
2722
2774
  )
2723
2775
  for i in _items:
2724
2776
  i.path = path
@@ -2864,7 +2916,10 @@ class SAClient(BaseInterfaceFacade, metaclass=TrackableMeta):
2864
2916
  ).data
2865
2917
  else:
2866
2918
  folder = self.controller.get_folder(project, folder)
2867
- include = include or []
2919
+ _include = {"assignments"}
2920
+ if include:
2921
+ _include.update(set(include))
2922
+ include = list(_include)
2868
2923
  include_custom_metadata = "custom_metadata" in include
2869
2924
  if include_custom_metadata:
2870
2925
  include.remove("custom_metadata")
@@ -2876,7 +2931,7 @@ class SAClient(BaseInterfaceFacade, metaclass=TrackableMeta):
2876
2931
  project=project, item_ids=[i.id for i in res]
2877
2932
  )
2878
2933
  for i in res:
2879
- i["custom_metadata"] = item_custom_fields[i.id]
2934
+ i.custom_metadata = item_custom_fields[i.id]
2880
2935
  exclude = {"meta", "annotator_email", "qa_email"}
2881
2936
  if include:
2882
2937
  if "custom_metadata" not in include:
@@ -88,6 +88,10 @@ class BaseManager:
88
88
 
89
89
 
90
90
  class ProjectManager(BaseManager):
91
+ def __init__(self, service_provider: ServiceProvider, team: TeamEntity):
92
+ super().__init__(service_provider)
93
+ self._team = team
94
+
91
95
  def get_by_id(self, project_id):
92
96
  use_case = usecases.GetProjectByIDUseCase(
93
97
  project_id=project_id, service_provider=self.service_provider
@@ -239,6 +243,13 @@ class ProjectManager(BaseManager):
239
243
  )
240
244
  return use_case.execute()
241
245
 
246
+ def get_editor_template(self, project: ProjectEntity) -> dict:
247
+ response = self.service_provider.projects.get_editor_template(
248
+ team=self._team, project=project
249
+ )
250
+ response.raise_for_status()
251
+ return response.data
252
+
242
253
 
243
254
  class AnnotationClassManager(BaseManager):
244
255
  @timed_lru_cache(seconds=3600)
@@ -974,7 +985,7 @@ class BaseController(metaclass=ABCMeta):
974
985
  self._user = self.get_current_user()
975
986
  self._team = self.get_team().data
976
987
  self.annotation_classes = AnnotationClassManager(self.service_provider)
977
- self.projects = ProjectManager(self.service_provider)
988
+ self.projects = ProjectManager(self.service_provider, team=self._team)
978
989
  self.folders = FolderManager(self.service_provider)
979
990
  self.items = ItemManager(self.service_provider)
980
991
  self.annotations = AnnotationManager(self.service_provider, config)
@@ -14,7 +14,7 @@ from superannotate import AppException
14
14
 
15
15
 
16
16
  class ItemService(SuperannotateServiceProvider):
17
- MAX_URI_LENGTH = 16_000
17
+ MAX_URI_LENGTH = 15_000
18
18
  URL_LIST = "items"
19
19
  URL_GET = "items/{item_id}"
20
20
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: superannotate
3
- Version: 4.4.28
3
+ Version: 4.4.29.dev1
4
4
  Summary: Python SDK to SuperAnnotate platform
5
5
  Home-page: https://github.com/superannotateai/superannotate-python-sdk
6
6
  Author: SuperAnnotate AI