craft-ai-sdk 0.62.0rc1__py3-none-any.whl → 0.62.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- craft_ai_sdk/__init__.py +1 -1
- craft_ai_sdk/core/data_store.py +2 -3
- craft_ai_sdk/core/vector_database.py +7 -2
- craft_ai_sdk/sdk.py +1 -1
- {craft_ai_sdk-0.62.0rc1.dist-info → craft_ai_sdk-0.62.1.dist-info}/METADATA +5 -4
- {craft_ai_sdk-0.62.0rc1.dist-info → craft_ai_sdk-0.62.1.dist-info}/RECORD +9 -10
- {craft_ai_sdk-0.62.0rc1.dist-info → craft_ai_sdk-0.62.1.dist-info}/WHEEL +1 -1
- documentation.pdf +0 -0
- {craft_ai_sdk-0.62.0rc1.dist-info → craft_ai_sdk-0.62.1.dist-info}/LICENSE +0 -0
- {craft_ai_sdk-0.62.0rc1.dist-info → craft_ai_sdk-0.62.1.dist-info}/entry_points.txt +0 -0
craft_ai_sdk/__init__.py
CHANGED
craft_ai_sdk/core/data_store.py
CHANGED
|
@@ -47,12 +47,11 @@ def list_data_store_objects(sdk: BaseCraftAiSdk):
|
|
|
47
47
|
* ``"size"`` (:obj:`int`): The size of the object in bytes.
|
|
48
48
|
"""
|
|
49
49
|
url = f"{sdk.base_environment_api_url}/data-store/list"
|
|
50
|
-
query = {"include_continuation_token": "t"}
|
|
51
50
|
|
|
52
|
-
result = sdk._get(
|
|
51
|
+
result = sdk._get(url)
|
|
53
52
|
all_items = result["items"]
|
|
54
53
|
while result.get("continuation_token", None):
|
|
55
|
-
query
|
|
54
|
+
query = {"continuation_token": result["continuation_token"]}
|
|
56
55
|
result = sdk._get(f"{url}?{urllib.parse.urlencode(query)}")
|
|
57
56
|
all_items.extend(result["items"])
|
|
58
57
|
|
|
@@ -3,8 +3,6 @@ from craft_ai_sdk.shared.environments import get_environment_id
|
|
|
3
3
|
from ..sdk import BaseCraftAiSdk
|
|
4
4
|
from ..shared.logger import log_action, log_func_result
|
|
5
5
|
|
|
6
|
-
import weaviate
|
|
7
|
-
|
|
8
6
|
|
|
9
7
|
def get_vector_database_credentials(sdk: BaseCraftAiSdk):
|
|
10
8
|
"""Get the credentials of the vector database.
|
|
@@ -31,6 +29,13 @@ def get_weaviate_client(sdk: BaseCraftAiSdk):
|
|
|
31
29
|
Returns:
|
|
32
30
|
:obj:`weaviate.WeaviateClient`: The Weaviate client.
|
|
33
31
|
"""
|
|
32
|
+
try:
|
|
33
|
+
import weaviate
|
|
34
|
+
except ModuleNotFoundError:
|
|
35
|
+
raise ModuleNotFoundError(
|
|
36
|
+
"The 'weaviate' package is required to use the vector database. "
|
|
37
|
+
"You can install it with 'pip install weaviate-client'."
|
|
38
|
+
)
|
|
34
39
|
credentials = get_vector_database_credentials(sdk)
|
|
35
40
|
|
|
36
41
|
is_secure = credentials["vector_database_url"].startswith("https://")
|
craft_ai_sdk/sdk.py
CHANGED
|
@@ -136,7 +136,7 @@ class CraftAiSdk(BaseCraftAiSdk):
|
|
|
136
136
|
os.environ.get("CRAFT_AI__MULTIPART_PART_SIZE__B", str(38 * 256 * 1024))
|
|
137
137
|
)
|
|
138
138
|
_access_token_margin = timedelta(seconds=30)
|
|
139
|
-
_version = "0.62.
|
|
139
|
+
_version = "0.62.1" # Would be better to share it somewhere
|
|
140
140
|
|
|
141
141
|
def __init__(
|
|
142
142
|
self,
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.3
|
|
2
2
|
Name: craft-ai-sdk
|
|
3
|
-
Version: 0.62.
|
|
3
|
+
Version: 0.62.1
|
|
4
4
|
Summary: Craft AI MLOps platform SDK
|
|
5
|
-
Home-page: https://www.craft.ai/
|
|
6
5
|
License: Apache-2.0
|
|
7
6
|
Author: Craft AI
|
|
8
7
|
Author-email: contact@craft.ai
|
|
@@ -13,10 +12,12 @@ Classifier: Programming Language :: Python :: 3.9
|
|
|
13
12
|
Classifier: Programming Language :: Python :: 3.10
|
|
14
13
|
Classifier: Programming Language :: Python :: 3.11
|
|
15
14
|
Classifier: Programming Language :: Python :: 3.12
|
|
16
|
-
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
17
16
|
Requires-Dist: PyJWT (>=2.3.0,<3.0.0)
|
|
18
17
|
Requires-Dist: StrEnum (>=0.4.9,<0.5.0)
|
|
19
18
|
Requires-Dist: requests (>=2.27.1,<3.0.0)
|
|
19
|
+
Requires-Dist: weaviate-client (>=4.10.4,<5.0.0)
|
|
20
|
+
Project-URL: Homepage, https://www.craft.ai/
|
|
20
21
|
Description-Content-Type: text/markdown
|
|
21
22
|
|
|
22
23
|
# Craft AI Python SDK
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
craft_ai_sdk/__init__.py,sha256=
|
|
1
|
+
craft_ai_sdk/__init__.py,sha256=HmsS0beJdUKSM3p1WkX_ZTazY-wWR_YjvZIBJtvrpdo,363
|
|
2
2
|
craft_ai_sdk/constants.py,sha256=rH4JrGlTpbjjjNRrKhk5oScbj5G5INrcVza6Bb6kIzY,980
|
|
3
|
-
craft_ai_sdk/core/data_store.py,sha256=
|
|
3
|
+
craft_ai_sdk/core/data_store.py,sha256=e2dfemMGZEQvVpL-tMOVa4IT-5lJaDVwAhWFBjdAxSM,8477
|
|
4
4
|
craft_ai_sdk/core/deployments.py,sha256=k3Eb3axVlZKJigOMy6PAozWxOzd0pZDy2d5nkGwSz34,34803
|
|
5
5
|
craft_ai_sdk/core/endpoints.py,sha256=eZMBGj7RCIdCr2IBXPyR2hsargmkzcZGoKL6sgs5xlc,5194
|
|
6
6
|
craft_ai_sdk/core/environment_variables.py,sha256=H1fo5RKQXNSQ8JAgtxZ9AdrdSQGrUtt7QPHbfkr0zTI,2053
|
|
@@ -10,10 +10,10 @@ craft_ai_sdk/core/pipelines.py,sha256=-lGP6ynV_rGJf4fi9dzKNNl5JfMgsylOjBeE2Y0iuY
|
|
|
10
10
|
craft_ai_sdk/core/resource_metrics.py,sha256=DsvlHNFabXobYnt52w7FS_V95KRGqZu9HWFpkpYsb6Y,2333
|
|
11
11
|
craft_ai_sdk/core/steps.py,sha256=qOyULKzYfiyLwOxRU0Z6Zz--PYLJxK4RkTLC3RrP8ZU,20953
|
|
12
12
|
craft_ai_sdk/core/users.py,sha256=Qi3xg7Vzk_0MepccNIZbFzjI0bBqouqkFStTuejUY6s,509
|
|
13
|
-
craft_ai_sdk/core/vector_database.py,sha256=
|
|
13
|
+
craft_ai_sdk/core/vector_database.py,sha256=9zgu9WFHYgSoBm_CYuI02-1mAE_y03IXNEk1D4ZIKks,2134
|
|
14
14
|
craft_ai_sdk/exceptions.py,sha256=IC-JfZmmmaTsbMCgirOEByRmWnatQLjKe8BErRkuwM0,1075
|
|
15
15
|
craft_ai_sdk/io.py,sha256=dbXAa6T1dR3V93PA_ctLY-UWzxfeI6pz2nDooLO58b0,12656
|
|
16
|
-
craft_ai_sdk/sdk.py,sha256=
|
|
16
|
+
craft_ai_sdk/sdk.py,sha256=XLhdnUI6HN1I2gfblmGvLTyeQ_Mc6vSYjM82cSvxb6M,10612
|
|
17
17
|
craft_ai_sdk/shared/authentication.py,sha256=z0wVkl1P-P8Hod06T4vYLq0P2o0ZCxStpX2dEaHANWs,774
|
|
18
18
|
craft_ai_sdk/shared/environments.py,sha256=IjLZYcL3eyOn_H0j3c05KZBCWcZJVlHf4-N3BupOOTc,494
|
|
19
19
|
craft_ai_sdk/shared/execution_context.py,sha256=B2Ghq-wiUvq81q5mhsm79Oc59c8c00uQxMIpApFD03o,585
|
|
@@ -25,9 +25,8 @@ craft_ai_sdk/utils/__init__.py,sha256=A0sLCXSPD1Z3q2GP1uLDjvif4ivOr__Hzg9RQysEuq
|
|
|
25
25
|
craft_ai_sdk/utils/datetime_utils.py,sha256=QpI2YgHDKbp7yHqvImDuZeSbtQWZDlGDGKR1AehA6x0,650
|
|
26
26
|
craft_ai_sdk/utils/dict_utils.py,sha256=geLcoBg5CPNqrPRm4jSf7MFym5r882QFyNz-4xKzYz8,742
|
|
27
27
|
craft_ai_sdk/utils/file_utils.py,sha256=rspzONrXhiaKYvkY54m0_yKDAYnaun09jvglzsZt0ro,2117
|
|
28
|
-
|
|
29
|
-
craft_ai_sdk-0.62.
|
|
30
|
-
craft_ai_sdk-0.62.
|
|
31
|
-
craft_ai_sdk-0.62.
|
|
32
|
-
craft_ai_sdk-0.62.
|
|
33
|
-
craft_ai_sdk-0.62.0rc1.dist-info/RECORD,,
|
|
28
|
+
craft_ai_sdk-0.62.1.dist-info/LICENSE,sha256=_2oYRJic9lZK05LceuJ9aZZw5mPHYc1WQhJiVS-oGFU,10754
|
|
29
|
+
craft_ai_sdk-0.62.1.dist-info/METADATA,sha256=ww0N-0PARXB-86JxYuY_Wpd6ahIBQdB2twbD3w44hT4,1676
|
|
30
|
+
craft_ai_sdk-0.62.1.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
|
|
31
|
+
craft_ai_sdk-0.62.1.dist-info/entry_points.txt,sha256=eV9YD0zCAb88_wNMDV99sRxVKVC-WOQF3b1Pepaytcg,385
|
|
32
|
+
craft_ai_sdk-0.62.1.dist-info/RECORD,,
|
documentation.pdf
DELETED
|
Binary file
|
|
File without changes
|
|
File without changes
|