swarmauri-core 0.9.2.dev7__py3-none-any.whl → 0.9.2.dev9__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.
- swarmauri_core/storage/IStorageAdapter.py +43 -0
- {swarmauri_core-0.9.2.dev7.dist-info → swarmauri_core-0.9.2.dev9.dist-info}/METADATA +2 -2
- {swarmauri_core-0.9.2.dev7.dist-info → swarmauri_core-0.9.2.dev9.dist-info}/RECORD +5 -5
- {swarmauri_core-0.9.2.dev7.dist-info → swarmauri_core-0.9.2.dev9.dist-info}/WHEEL +0 -0
- {swarmauri_core-0.9.2.dev7.dist-info → swarmauri_core-0.9.2.dev9.dist-info}/licenses/LICENSE +0 -0
|
@@ -56,6 +56,49 @@ class IStorageAdapter(ABC):
|
|
|
56
56
|
"""Convenience wrapper to download a directory tree."""
|
|
57
57
|
raise NotImplementedError
|
|
58
58
|
|
|
59
|
+
@abstractmethod
|
|
60
|
+
async def ensure_bucket(self) -> None: # pragma: no cover - interface
|
|
61
|
+
"""Ensure the backing storage container exists."""
|
|
62
|
+
raise NotImplementedError
|
|
63
|
+
|
|
64
|
+
@abstractmethod
|
|
65
|
+
async def put_bytes(
|
|
66
|
+
self, object_key: str, data: bytes, content_type: str
|
|
67
|
+
) -> None: # pragma: no cover - interface
|
|
68
|
+
"""Store raw bytes under *object_key*."""
|
|
69
|
+
raise NotImplementedError
|
|
70
|
+
|
|
71
|
+
@abstractmethod
|
|
72
|
+
async def get_bytes(self, object_key: str) -> bytes: # pragma: no cover - interface
|
|
73
|
+
"""Retrieve the stored object as bytes."""
|
|
74
|
+
raise NotImplementedError
|
|
75
|
+
|
|
76
|
+
@abstractmethod
|
|
77
|
+
async def get_range(
|
|
78
|
+
self, object_key: str, start: int, length: int
|
|
79
|
+
) -> bytes: # pragma: no cover - interface
|
|
80
|
+
"""Retrieve a byte range from a stored object."""
|
|
81
|
+
raise NotImplementedError
|
|
82
|
+
|
|
83
|
+
@abstractmethod
|
|
84
|
+
def _parse_range(self, start: int, length: int, total: int) -> tuple[int, int]:
|
|
85
|
+
"""Normalize and validate byte range values."""
|
|
86
|
+
raise NotImplementedError
|
|
87
|
+
|
|
88
|
+
@abstractmethod
|
|
89
|
+
def _parse_range_header(
|
|
90
|
+
self, range_header: str, total_size: int
|
|
91
|
+
) -> tuple[int, int]:
|
|
92
|
+
"""Parse an HTTP Range header and return inclusive ``(start, end)``."""
|
|
93
|
+
raise NotImplementedError
|
|
94
|
+
|
|
95
|
+
@abstractmethod
|
|
96
|
+
async def remove_object(
|
|
97
|
+
self, object_key: str
|
|
98
|
+
) -> None: # pragma: no cover - interface
|
|
99
|
+
"""Delete an object from storage if it exists."""
|
|
100
|
+
raise NotImplementedError
|
|
101
|
+
|
|
59
102
|
@classmethod
|
|
60
103
|
@abstractmethod
|
|
61
104
|
def from_uri(cls, uri: str) -> "IStorageAdapter": # pragma: no cover - interface
|
|
@@ -162,7 +162,7 @@ swarmauri_core/sst/IPredict.py,sha256=SG4b-1xK-z2CR8hxLH7ULGZsD_G9M65-26obMg1H2E
|
|
|
162
162
|
swarmauri_core/sst/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
163
163
|
swarmauri_core/state/IState.py,sha256=uCnvOMXixR7ycOoNbRil8ErIeBYuGxqd-5o4rLG4C_w,646
|
|
164
164
|
swarmauri_core/state/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
165
|
-
swarmauri_core/storage/IStorageAdapter.py,sha256=
|
|
165
|
+
swarmauri_core/storage/IStorageAdapter.py,sha256=WwohjBIp6cW7I5mtAH5RmKIzCnU3CFBH4_y5vzz2EPU,3700
|
|
166
166
|
swarmauri_core/storage/__init__.py,sha256=gBetjmhdxQYScWngIaUxvbXJF1FaEFnf8tVuNaT95DE,76
|
|
167
167
|
swarmauri_core/swarm_apis/IAgentRegistrationAPI.py,sha256=oCSEXEhfnzpnaDst0xr-5SlIPINtlZfsC9pqIpXcKIQ,2171
|
|
168
168
|
swarmauri_core/swarm_apis/ISwarmAPI.py,sha256=RZzsl-USSjPy_HmgvtqSfxYuWXqHeBqukeCTOYl0Btg,665
|
|
@@ -220,7 +220,7 @@ swarmauri_core/vlms/IPredictVision.py,sha256=Wjm_49kTQIcEtvSddURH3-VdIMWiv1aiv21
|
|
|
220
220
|
swarmauri_core/vlms/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
221
221
|
swarmauri_core/xmp/IEmbedXMP.py,sha256=CN8WYqX1OTODq-1y-RBO7CLXlTwO2LHEC6TCZ3JrSf4,837
|
|
222
222
|
swarmauri_core/xmp/__init__.py,sha256=7-68mC1dItufhAfmM6Y3n1PqRK9msi4OMQyH6l7e6HE,118
|
|
223
|
-
swarmauri_core-0.9.2.
|
|
224
|
-
swarmauri_core-0.9.2.
|
|
225
|
-
swarmauri_core-0.9.2.
|
|
226
|
-
swarmauri_core-0.9.2.
|
|
223
|
+
swarmauri_core-0.9.2.dev9.dist-info/METADATA,sha256=8TzBU1m_lbvlQwbRdartup4vZacvF-QVQbIdS9msnB8,6071
|
|
224
|
+
swarmauri_core-0.9.2.dev9.dist-info/WHEEL,sha256=kJCRJT_g0adfAJzTx2GUMmS80rTJIVHRCfG0DQgLq3o,88
|
|
225
|
+
swarmauri_core-0.9.2.dev9.dist-info/licenses/LICENSE,sha256=djUXOlCxLVszShEpZXshZ7v33G-2qIC_j9KXpWKZSzQ,11359
|
|
226
|
+
swarmauri_core-0.9.2.dev9.dist-info/RECORD,,
|
|
File without changes
|
{swarmauri_core-0.9.2.dev7.dist-info → swarmauri_core-0.9.2.dev9.dist-info}/licenses/LICENSE
RENAMED
|
File without changes
|