rapidata 2.40.4__py3-none-any.whl → 2.40.5__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 CHANGED
@@ -1,4 +1,4 @@
1
- __version__ = "2.40.4"
1
+ __version__ = "2.40.5"
2
2
 
3
3
  from .rapidata_client import (
4
4
  RapidataClient,
@@ -92,6 +92,11 @@ class RapidataOrderManager:
92
92
  if media_contexts and len(media_contexts) != len(assets):
93
93
  raise ValueError("Number of media contexts must match number of datapoints")
94
94
 
95
+ if media_contexts:
96
+ for media_context in media_contexts:
97
+ if not media_context.startswith("http"):
98
+ raise ValueError("Media contexts must all be URLs")
99
+
95
100
  if sentences and len(sentences) != len(assets):
96
101
  raise ValueError("Number of sentences must match number of datapoints")
97
102
 
@@ -419,6 +424,9 @@ class RapidataOrderManager:
419
424
  """
420
425
 
421
426
  with tracer.start_as_current_span("RapidataOrderManager.create_ranking_order"):
427
+ if len(datapoints) < 2:
428
+ raise ValueError("At least two datapoints are required")
429
+
422
430
  if data_type == "media":
423
431
  assets = [MediaAsset(path=path) for path in datapoints]
424
432
  elif data_type == "text":
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: rapidata
3
- Version: 2.40.4
3
+ Version: 2.40.5
4
4
  Summary: Rapidata package containing the Rapidata Python Client to interact with the Rapidata Web API in an easy way.
5
5
  License: Apache-2.0
6
6
  Author: Rapidata AG
@@ -1,4 +1,4 @@
1
- rapidata/__init__.py,sha256=eYKN-_zLrN6w3N-Mnd0w7MckYzcZC1w_nm9yq-O8xTY,917
1
+ rapidata/__init__.py,sha256=bmnaWulsFcvMQ08yPv4qNBuAeGDtJXCbMlHQrtjibmY,917
2
2
  rapidata/api_client/__init__.py,sha256=utY2iWepKJQO_iGz6aIg_qSoqoDkV9pBMAA58pIFE4M,36016
3
3
  rapidata/api_client/api/__init__.py,sha256=07qqwzQiBYt5V2BtnzbXhZL2cmVHATyZmCSGshIXLck,1603
4
4
  rapidata/api_client/api/benchmark_api.py,sha256=Mlx2qDDJcgPjWvaBnps9dxvVd0re1knG0SyoLUiHKSc,119756
@@ -635,7 +635,7 @@ rapidata/rapidata_client/order/_rapidata_order_builder.py,sha256=C-TbKELNuLjQiZt
635
635
  rapidata/rapidata_client/order/dataset/_progress_tracker.py,sha256=2e9aVMwpdBSO9P3LYn5lygNbtIGzOaJD3b9J7jYaxko,3570
636
636
  rapidata/rapidata_client/order/dataset/_rapidata_dataset.py,sha256=ONH56htEvoVZvkSItuTi3_88kaDWohmYYABSoAPEn4Q,10724
637
637
  rapidata/rapidata_client/order/rapidata_order.py,sha256=FvZi3t4dARRNsKWvYiNxVvM50AzPwQYR3AzI4utD6OI,14497
638
- rapidata/rapidata_client/order/rapidata_order_manager.py,sha256=XiV_BpJxG6d8o0rFDYhnB3_mb576CQG5hY-qVXlJZKY,42592
638
+ rapidata/rapidata_client/order/rapidata_order_manager.py,sha256=_liKhfS7vH0tilkSOeGJV5Mq3-8Nc8Vw1auXJeP7MyM,42908
639
639
  rapidata/rapidata_client/order/rapidata_results.py,sha256=weL4S14fzug3ZOJbQk9Oj-4tv2jx5aZAMp7VJ-a6Qq4,8437
640
640
  rapidata/rapidata_client/rapidata_client.py,sha256=yEwUsxR0OZbCb2B6QXS23WEVfNZPxRTMi2Hxto2hynw,5687
641
641
  rapidata/rapidata_client/referee/__init__.py,sha256=J8oZJNUduPr-Tmn8iJwR-qBiSv7owhUFcEzXTRETecw,155
@@ -690,7 +690,7 @@ rapidata/service/credential_manager.py,sha256=T3yL4tXVnibRytxjQkOC-ex3kFGQR5KcKU
690
690
  rapidata/service/local_file_service.py,sha256=0Q4LdoEtPFKzgXK2oZ1cQ-X7FipakscjGnnBH8dRFRQ,855
691
691
  rapidata/service/openapi_service.py,sha256=k3V4eMNcAjBcxEv17lDivK8LV5TEjRTL9B_5KBlhcas,5482
692
692
  rapidata/types/__init__.py,sha256=gSGrmWV5gEA6pPfAR5vwSy_DvibO5IjCZDiB7LtlMOQ,6134
693
- rapidata-2.40.4.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
694
- rapidata-2.40.4.dist-info/METADATA,sha256=VWYYAZVvVOsnGQ3LytBR37ttKupkFH_Xo9acIWN-IRo,1406
695
- rapidata-2.40.4.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
696
- rapidata-2.40.4.dist-info/RECORD,,
693
+ rapidata-2.40.5.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
694
+ rapidata-2.40.5.dist-info/METADATA,sha256=fg4jX_993ZJhN7pVU31RYnQn7D_l1Wu21KJ_OSU3iug,1406
695
+ rapidata-2.40.5.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
696
+ rapidata-2.40.5.dist-info/RECORD,,