mistralai 0.4.0__py3-none-any.whl → 0.4.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.
- mistralai/async_client.py +9 -1
- mistralai/client.py +9 -1
- mistralai/client_base.py +1 -1
- mistralai/models/models.py +6 -0
- {mistralai-0.4.0.dist-info → mistralai-0.4.1.dist-info}/METADATA +3 -3
- {mistralai-0.4.0.dist-info → mistralai-0.4.1.dist-info}/RECORD +8 -8
- {mistralai-0.4.0.dist-info → mistralai-0.4.1.dist-info}/LICENSE +0 -0
- {mistralai-0.4.0.dist-info → mistralai-0.4.1.dist-info}/WHEEL +0 -0
mistralai/async_client.py
CHANGED
|
@@ -29,7 +29,7 @@ from mistralai.models.chat_completion import (
|
|
|
29
29
|
ToolChoice,
|
|
30
30
|
)
|
|
31
31
|
from mistralai.models.embeddings import EmbeddingResponse
|
|
32
|
-
from mistralai.models.models import ModelList
|
|
32
|
+
from mistralai.models.models import ModelDeleted, ModelList
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
class MistralAsyncClient(ClientBase):
|
|
@@ -304,6 +304,14 @@ class MistralAsyncClient(ClientBase):
|
|
|
304
304
|
|
|
305
305
|
raise MistralException("No response received")
|
|
306
306
|
|
|
307
|
+
async def delete_model(self, model_id: str) -> ModelDeleted:
|
|
308
|
+
single_response = self._request("delete", {}, f"v1/models/{model_id}")
|
|
309
|
+
|
|
310
|
+
async for response in single_response:
|
|
311
|
+
return ModelDeleted(**response)
|
|
312
|
+
|
|
313
|
+
raise MistralException("No response received")
|
|
314
|
+
|
|
307
315
|
async def completion(
|
|
308
316
|
self,
|
|
309
317
|
model: str,
|
mistralai/client.py
CHANGED
|
@@ -22,7 +22,7 @@ from mistralai.models.chat_completion import (
|
|
|
22
22
|
ToolChoice,
|
|
23
23
|
)
|
|
24
24
|
from mistralai.models.embeddings import EmbeddingResponse
|
|
25
|
-
from mistralai.models.models import ModelList
|
|
25
|
+
from mistralai.models.models import ModelDeleted, ModelList
|
|
26
26
|
|
|
27
27
|
|
|
28
28
|
class MistralClient(ClientBase):
|
|
@@ -298,6 +298,14 @@ class MistralClient(ClientBase):
|
|
|
298
298
|
|
|
299
299
|
raise MistralException("No response received")
|
|
300
300
|
|
|
301
|
+
def delete_model(self, model_id: str) -> ModelDeleted:
|
|
302
|
+
single_response = self._request("delete", {}, f"v1/models/{model_id}")
|
|
303
|
+
|
|
304
|
+
for response in single_response:
|
|
305
|
+
return ModelDeleted(**response)
|
|
306
|
+
|
|
307
|
+
raise MistralException("No response received")
|
|
308
|
+
|
|
301
309
|
def completion(
|
|
302
310
|
self,
|
|
303
311
|
model: str,
|
mistralai/client_base.py
CHANGED
mistralai/models/models.py
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: mistralai
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.1
|
|
4
4
|
Summary:
|
|
5
5
|
Author: Bam4d
|
|
6
6
|
Author-email: bam4d@mistral.ai
|
|
@@ -10,9 +10,9 @@ Classifier: Programming Language :: Python :: 3.9
|
|
|
10
10
|
Classifier: Programming Language :: Python :: 3.10
|
|
11
11
|
Classifier: Programming Language :: Python :: 3.11
|
|
12
12
|
Classifier: Programming Language :: Python :: 3.12
|
|
13
|
-
Requires-Dist: httpx (>=0.25,<
|
|
13
|
+
Requires-Dist: httpx (>=0.25,<1)
|
|
14
14
|
Requires-Dist: orjson (>=3.9.10,<3.11)
|
|
15
|
-
Requires-Dist: pydantic (>=2.5.2,<3
|
|
15
|
+
Requires-Dist: pydantic (>=2.5.2,<3)
|
|
16
16
|
Description-Content-Type: text/markdown
|
|
17
17
|
|
|
18
18
|
# Mistral Python Client
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
mistralai/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
mistralai/async_client.py,sha256=
|
|
3
|
-
mistralai/client.py,sha256=
|
|
4
|
-
mistralai/client_base.py,sha256=
|
|
2
|
+
mistralai/async_client.py,sha256=nqD8iYAttILXEL0DYqps8-83VixeuQN7PQ5N1_ZfAqo,15696
|
|
3
|
+
mistralai/client.py,sha256=jrb_ucBJGPnyj1HPUBQjkUQuTTvohokjxSNPP4xnCqg,15399
|
|
4
|
+
mistralai/client_base.py,sha256=oAPqGMBLxQUGd_gTOxsFpNdpzlYNCgJ84EouZMSpdgI,6387
|
|
5
5
|
mistralai/constants.py,sha256=FvokZPfTBC-DC6-HfiV83pD3FP6huHk3SUIl0yx5jx8,84
|
|
6
6
|
mistralai/exceptions.py,sha256=R3pswvZyY5CuSbqhVklgfGPVJoz7T7l2VQKMOXK229A,1652
|
|
7
7
|
mistralai/files.py,sha256=5ZyQaozyOCGE2H2OToMNoNETPi9LIWSACJ4lOrx-DZU,2816
|
|
@@ -12,9 +12,9 @@ mistralai/models/common.py,sha256=zatP4aV_LIEpzj3_igsKkJBICwGhmXG0LX3CdO3kn-o,17
|
|
|
12
12
|
mistralai/models/embeddings.py,sha256=-VthLQBj6wrq7HXJbGmnkQEEanSemA3MAlaMFh94VBg,331
|
|
13
13
|
mistralai/models/files.py,sha256=74HzLUqrSoGj13TmC0u5sYyE7DUyDPxtL_LSDdKONl8,398
|
|
14
14
|
mistralai/models/jobs.py,sha256=hljCBiHtpMW7pLIq_GjCH8X1lpd__NoZ5st9aouMYiA,2340
|
|
15
|
-
mistralai/models/models.py,sha256=
|
|
15
|
+
mistralai/models/models.py,sha256=q7sZvEYKtaP4x_GGEHE4GUQDsLV_rOt_M_MQkgNems4,823
|
|
16
16
|
mistralai/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
17
|
-
mistralai-0.4.
|
|
18
|
-
mistralai-0.4.
|
|
19
|
-
mistralai-0.4.
|
|
20
|
-
mistralai-0.4.
|
|
17
|
+
mistralai-0.4.1.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
18
|
+
mistralai-0.4.1.dist-info/METADATA,sha256=NhUcYQKSsxjbT-ynrBq3lyBnlv3fOIpAQm9oXlG1rFI,1824
|
|
19
|
+
mistralai-0.4.1.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
|
20
|
+
mistralai-0.4.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|