mistralai 1.9.1__py3-none-any.whl → 1.9.2__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.
Files changed (56) hide show
  1. mistralai/_version.py +2 -2
  2. mistralai/accesses.py +672 -0
  3. mistralai/beta.py +4 -0
  4. mistralai/documents.py +2136 -0
  5. mistralai/files.py +2 -2
  6. mistralai/libraries.py +1041 -0
  7. mistralai/models/__init__.py +232 -8
  8. mistralai/models/basemodelcard.py +5 -2
  9. mistralai/models/conversationevents.py +6 -0
  10. mistralai/models/conversationhistory.py +4 -4
  11. mistralai/models/documentout.py +105 -0
  12. mistralai/models/documenttextcontent.py +13 -0
  13. mistralai/models/documentupdatein.py +44 -0
  14. mistralai/models/entitytype.py +9 -0
  15. mistralai/models/file.py +33 -0
  16. mistralai/models/files_api_routes_upload_fileop.py +2 -27
  17. mistralai/models/ftmodelcard.py +5 -3
  18. mistralai/models/inputentries.py +4 -4
  19. mistralai/models/libraries_delete_v1op.py +16 -0
  20. mistralai/models/libraries_documents_delete_v1op.py +21 -0
  21. mistralai/models/libraries_documents_get_extracted_text_signed_url_v1op.py +21 -0
  22. mistralai/models/libraries_documents_get_signed_url_v1op.py +21 -0
  23. mistralai/models/libraries_documents_get_status_v1op.py +21 -0
  24. mistralai/models/libraries_documents_get_text_content_v1op.py +21 -0
  25. mistralai/models/libraries_documents_get_v1op.py +21 -0
  26. mistralai/models/libraries_documents_list_v1op.py +78 -0
  27. mistralai/models/libraries_documents_reprocess_v1op.py +21 -0
  28. mistralai/models/libraries_documents_update_v1op.py +28 -0
  29. mistralai/models/libraries_documents_upload_v1op.py +56 -0
  30. mistralai/models/libraries_get_v1op.py +16 -0
  31. mistralai/models/libraries_share_create_v1op.py +22 -0
  32. mistralai/models/libraries_share_delete_v1op.py +23 -0
  33. mistralai/models/libraries_share_list_v1op.py +16 -0
  34. mistralai/models/libraries_update_v1op.py +23 -0
  35. mistralai/models/libraryin.py +50 -0
  36. mistralai/models/libraryinupdate.py +47 -0
  37. mistralai/models/libraryout.py +107 -0
  38. mistralai/models/listdocumentout.py +19 -0
  39. mistralai/models/listlibraryout.py +15 -0
  40. mistralai/models/listsharingout.py +15 -0
  41. mistralai/models/messageinputentry.py +14 -4
  42. mistralai/models/paginationinfo.py +25 -0
  43. mistralai/models/processingstatusout.py +16 -0
  44. mistralai/models/shareenum.py +8 -0
  45. mistralai/models/sharingdelete.py +26 -0
  46. mistralai/models/sharingin.py +30 -0
  47. mistralai/models/sharingout.py +59 -0
  48. mistralai/models/ssetypes.py +1 -0
  49. mistralai/models/toolexecutiondeltaevent.py +34 -0
  50. mistralai/models/toolexecutionentry.py +3 -0
  51. mistralai/models/toolexecutionstartedevent.py +3 -0
  52. mistralai/models/toolreferencechunk.py +7 -4
  53. {mistralai-1.9.1.dist-info → mistralai-1.9.2.dist-info}/METADATA +29 -2
  54. {mistralai-1.9.1.dist-info → mistralai-1.9.2.dist-info}/RECORD +56 -19
  55. {mistralai-1.9.1.dist-info → mistralai-1.9.2.dist-info}/LICENSE +0 -0
  56. {mistralai-1.9.1.dist-info → mistralai-1.9.2.dist-info}/WHEEL +0 -0
@@ -129,7 +129,7 @@ if TYPE_CHECKING:
129
129
  AssistantMessageRole,
130
130
  AssistantMessageTypedDict,
131
131
  )
132
- from .basemodelcard import BaseModelCard, BaseModelCardTypedDict
132
+ from .basemodelcard import BaseModelCard, BaseModelCardTypedDict, Type
133
133
  from .batcherror import BatchError, BatchErrorTypedDict
134
134
  from .batchjobin import BatchJobIn, BatchJobInTypedDict
135
135
  from .batchjobout import BatchJobOut, BatchJobOutObject, BatchJobOutTypedDict
@@ -360,6 +360,9 @@ if TYPE_CHECKING:
360
360
  DocumentLibraryToolType,
361
361
  DocumentLibraryToolTypedDict,
362
362
  )
363
+ from .documentout import DocumentOut, DocumentOutTypedDict
364
+ from .documenttextcontent import DocumentTextContent, DocumentTextContentTypedDict
365
+ from .documentupdatein import DocumentUpdateIn, DocumentUpdateInTypedDict
363
366
  from .documenturlchunk import (
364
367
  DocumentURLChunk,
365
368
  DocumentURLChunkType,
@@ -377,7 +380,9 @@ if TYPE_CHECKING:
377
380
  EmbeddingResponseData,
378
381
  EmbeddingResponseDataTypedDict,
379
382
  )
383
+ from .entitytype import EntityType
380
384
  from .eventout import EventOut, EventOutTypedDict
385
+ from .file import File, FileTypedDict
381
386
  from .filechunk import FileChunk, FileChunkTypedDict
382
387
  from .filepurpose import FilePurpose
383
388
  from .files_api_routes_delete_fileop import (
@@ -401,8 +406,6 @@ if TYPE_CHECKING:
401
406
  FilesAPIRoutesRetrieveFileRequestTypedDict,
402
407
  )
403
408
  from .files_api_routes_upload_fileop import (
404
- File,
405
- FileTypedDict,
406
409
  FilesAPIRoutesUploadFileMultiPartBodyParams,
407
410
  FilesAPIRoutesUploadFileMultiPartBodyParamsTypedDict,
408
411
  )
@@ -430,7 +433,7 @@ if TYPE_CHECKING:
430
433
  FTModelCapabilitiesOut,
431
434
  FTModelCapabilitiesOutTypedDict,
432
435
  )
433
- from .ftmodelcard import FTModelCard, FTModelCardTypedDict
436
+ from .ftmodelcard import FTModelCard, FTModelCardType, FTModelCardTypedDict
434
437
  from .function import Function, FunctionTypedDict
435
438
  from .functioncall import (
436
439
  Arguments,
@@ -579,7 +582,79 @@ if TYPE_CHECKING:
579
582
  LegacyJobMetadataOutObject,
580
583
  LegacyJobMetadataOutTypedDict,
581
584
  )
585
+ from .libraries_delete_v1op import (
586
+ LibrariesDeleteV1Request,
587
+ LibrariesDeleteV1RequestTypedDict,
588
+ )
589
+ from .libraries_documents_delete_v1op import (
590
+ LibrariesDocumentsDeleteV1Request,
591
+ LibrariesDocumentsDeleteV1RequestTypedDict,
592
+ )
593
+ from .libraries_documents_get_extracted_text_signed_url_v1op import (
594
+ LibrariesDocumentsGetExtractedTextSignedURLV1Request,
595
+ LibrariesDocumentsGetExtractedTextSignedURLV1RequestTypedDict,
596
+ )
597
+ from .libraries_documents_get_signed_url_v1op import (
598
+ LibrariesDocumentsGetSignedURLV1Request,
599
+ LibrariesDocumentsGetSignedURLV1RequestTypedDict,
600
+ )
601
+ from .libraries_documents_get_status_v1op import (
602
+ LibrariesDocumentsGetStatusV1Request,
603
+ LibrariesDocumentsGetStatusV1RequestTypedDict,
604
+ )
605
+ from .libraries_documents_get_text_content_v1op import (
606
+ LibrariesDocumentsGetTextContentV1Request,
607
+ LibrariesDocumentsGetTextContentV1RequestTypedDict,
608
+ )
609
+ from .libraries_documents_get_v1op import (
610
+ LibrariesDocumentsGetV1Request,
611
+ LibrariesDocumentsGetV1RequestTypedDict,
612
+ )
613
+ from .libraries_documents_list_v1op import (
614
+ LibrariesDocumentsListV1Request,
615
+ LibrariesDocumentsListV1RequestTypedDict,
616
+ )
617
+ from .libraries_documents_reprocess_v1op import (
618
+ LibrariesDocumentsReprocessV1Request,
619
+ LibrariesDocumentsReprocessV1RequestTypedDict,
620
+ )
621
+ from .libraries_documents_update_v1op import (
622
+ LibrariesDocumentsUpdateV1Request,
623
+ LibrariesDocumentsUpdateV1RequestTypedDict,
624
+ )
625
+ from .libraries_documents_upload_v1op import (
626
+ LibrariesDocumentsUploadV1DocumentUpload,
627
+ LibrariesDocumentsUploadV1DocumentUploadTypedDict,
628
+ LibrariesDocumentsUploadV1Request,
629
+ LibrariesDocumentsUploadV1RequestTypedDict,
630
+ )
631
+ from .libraries_get_v1op import (
632
+ LibrariesGetV1Request,
633
+ LibrariesGetV1RequestTypedDict,
634
+ )
635
+ from .libraries_share_create_v1op import (
636
+ LibrariesShareCreateV1Request,
637
+ LibrariesShareCreateV1RequestTypedDict,
638
+ )
639
+ from .libraries_share_delete_v1op import (
640
+ LibrariesShareDeleteV1Request,
641
+ LibrariesShareDeleteV1RequestTypedDict,
642
+ )
643
+ from .libraries_share_list_v1op import (
644
+ LibrariesShareListV1Request,
645
+ LibrariesShareListV1RequestTypedDict,
646
+ )
647
+ from .libraries_update_v1op import (
648
+ LibrariesUpdateV1Request,
649
+ LibrariesUpdateV1RequestTypedDict,
650
+ )
651
+ from .libraryin import LibraryIn, LibraryInTypedDict
652
+ from .libraryinupdate import LibraryInUpdate, LibraryInUpdateTypedDict
653
+ from .libraryout import LibraryOut, LibraryOutTypedDict
654
+ from .listdocumentout import ListDocumentOut, ListDocumentOutTypedDict
582
655
  from .listfilesout import ListFilesOut, ListFilesOutTypedDict
656
+ from .listlibraryout import ListLibraryOut, ListLibraryOutTypedDict
657
+ from .listsharingout import ListSharingOut, ListSharingOutTypedDict
583
658
  from .messageentries import MessageEntries, MessageEntriesTypedDict
584
659
  from .messageinputcontentchunks import (
585
660
  MessageInputContentChunks,
@@ -590,9 +665,9 @@ if TYPE_CHECKING:
590
665
  MessageInputEntryContent,
591
666
  MessageInputEntryContentTypedDict,
592
667
  MessageInputEntryRole,
668
+ MessageInputEntryType,
593
669
  MessageInputEntryTypedDict,
594
670
  Object,
595
- Type,
596
671
  )
597
672
  from .messageoutputcontentchunks import (
598
673
  MessageOutputContentChunks,
@@ -635,7 +710,9 @@ if TYPE_CHECKING:
635
710
  from .ocrresponse import OCRResponse, OCRResponseTypedDict
636
711
  from .ocrusageinfo import OCRUsageInfo, OCRUsageInfoTypedDict
637
712
  from .outputcontentchunks import OutputContentChunks, OutputContentChunksTypedDict
713
+ from .paginationinfo import PaginationInfo, PaginationInfoTypedDict
638
714
  from .prediction import Prediction, PredictionTypedDict
715
+ from .processingstatusout import ProcessingStatusOut, ProcessingStatusOutTypedDict
639
716
  from .referencechunk import (
640
717
  ReferenceChunk,
641
718
  ReferenceChunkType,
@@ -668,6 +745,10 @@ if TYPE_CHECKING:
668
745
  from .sampletype import SampleType
669
746
  from .sdkerror import SDKError
670
747
  from .security import Security, SecurityTypedDict
748
+ from .shareenum import ShareEnum
749
+ from .sharingdelete import SharingDelete, SharingDeleteTypedDict
750
+ from .sharingin import SharingIn, SharingInTypedDict
751
+ from .sharingout import SharingOut, SharingOutTypedDict
671
752
  from .source import Source
672
753
  from .ssetypes import SSETypes
673
754
  from .systemmessage import (
@@ -682,6 +763,11 @@ if TYPE_CHECKING:
682
763
  from .toolcall import ToolCall, ToolCallTypedDict
683
764
  from .toolchoice import ToolChoice, ToolChoiceTypedDict
684
765
  from .toolchoiceenum import ToolChoiceEnum
766
+ from .toolexecutiondeltaevent import (
767
+ ToolExecutionDeltaEvent,
768
+ ToolExecutionDeltaEventType,
769
+ ToolExecutionDeltaEventTypedDict,
770
+ )
685
771
  from .toolexecutiondoneevent import (
686
772
  ToolExecutionDoneEvent,
687
773
  ToolExecutionDoneEventType,
@@ -990,10 +1076,16 @@ __all__ = [
990
1076
  "DocumentLibraryTool",
991
1077
  "DocumentLibraryToolType",
992
1078
  "DocumentLibraryToolTypedDict",
1079
+ "DocumentOut",
1080
+ "DocumentOutTypedDict",
1081
+ "DocumentTextContent",
1082
+ "DocumentTextContentTypedDict",
993
1083
  "DocumentTypedDict",
994
1084
  "DocumentURLChunk",
995
1085
  "DocumentURLChunkType",
996
1086
  "DocumentURLChunkTypedDict",
1087
+ "DocumentUpdateIn",
1088
+ "DocumentUpdateInTypedDict",
997
1089
  "EmbeddingDtype",
998
1090
  "EmbeddingRequest",
999
1091
  "EmbeddingRequestInputs",
@@ -1003,6 +1095,7 @@ __all__ = [
1003
1095
  "EmbeddingResponseData",
1004
1096
  "EmbeddingResponseDataTypedDict",
1005
1097
  "EmbeddingResponseTypedDict",
1098
+ "EntityType",
1006
1099
  "Entries",
1007
1100
  "EntriesTypedDict",
1008
1101
  "EventOut",
@@ -1021,6 +1114,7 @@ __all__ = [
1021
1114
  "FTModelCapabilitiesOut",
1022
1115
  "FTModelCapabilitiesOutTypedDict",
1023
1116
  "FTModelCard",
1117
+ "FTModelCardType",
1024
1118
  "FTModelCardTypedDict",
1025
1119
  "File",
1026
1120
  "FileChunk",
@@ -1151,8 +1245,54 @@ __all__ = [
1151
1245
  "LegacyJobMetadataOut",
1152
1246
  "LegacyJobMetadataOutObject",
1153
1247
  "LegacyJobMetadataOutTypedDict",
1248
+ "LibrariesDeleteV1Request",
1249
+ "LibrariesDeleteV1RequestTypedDict",
1250
+ "LibrariesDocumentsDeleteV1Request",
1251
+ "LibrariesDocumentsDeleteV1RequestTypedDict",
1252
+ "LibrariesDocumentsGetExtractedTextSignedURLV1Request",
1253
+ "LibrariesDocumentsGetExtractedTextSignedURLV1RequestTypedDict",
1254
+ "LibrariesDocumentsGetSignedURLV1Request",
1255
+ "LibrariesDocumentsGetSignedURLV1RequestTypedDict",
1256
+ "LibrariesDocumentsGetStatusV1Request",
1257
+ "LibrariesDocumentsGetStatusV1RequestTypedDict",
1258
+ "LibrariesDocumentsGetTextContentV1Request",
1259
+ "LibrariesDocumentsGetTextContentV1RequestTypedDict",
1260
+ "LibrariesDocumentsGetV1Request",
1261
+ "LibrariesDocumentsGetV1RequestTypedDict",
1262
+ "LibrariesDocumentsListV1Request",
1263
+ "LibrariesDocumentsListV1RequestTypedDict",
1264
+ "LibrariesDocumentsReprocessV1Request",
1265
+ "LibrariesDocumentsReprocessV1RequestTypedDict",
1266
+ "LibrariesDocumentsUpdateV1Request",
1267
+ "LibrariesDocumentsUpdateV1RequestTypedDict",
1268
+ "LibrariesDocumentsUploadV1DocumentUpload",
1269
+ "LibrariesDocumentsUploadV1DocumentUploadTypedDict",
1270
+ "LibrariesDocumentsUploadV1Request",
1271
+ "LibrariesDocumentsUploadV1RequestTypedDict",
1272
+ "LibrariesGetV1Request",
1273
+ "LibrariesGetV1RequestTypedDict",
1274
+ "LibrariesShareCreateV1Request",
1275
+ "LibrariesShareCreateV1RequestTypedDict",
1276
+ "LibrariesShareDeleteV1Request",
1277
+ "LibrariesShareDeleteV1RequestTypedDict",
1278
+ "LibrariesShareListV1Request",
1279
+ "LibrariesShareListV1RequestTypedDict",
1280
+ "LibrariesUpdateV1Request",
1281
+ "LibrariesUpdateV1RequestTypedDict",
1282
+ "LibraryIn",
1283
+ "LibraryInTypedDict",
1284
+ "LibraryInUpdate",
1285
+ "LibraryInUpdateTypedDict",
1286
+ "LibraryOut",
1287
+ "LibraryOutTypedDict",
1288
+ "ListDocumentOut",
1289
+ "ListDocumentOutTypedDict",
1154
1290
  "ListFilesOut",
1155
1291
  "ListFilesOutTypedDict",
1292
+ "ListLibraryOut",
1293
+ "ListLibraryOutTypedDict",
1294
+ "ListSharingOut",
1295
+ "ListSharingOutTypedDict",
1156
1296
  "Loc",
1157
1297
  "LocTypedDict",
1158
1298
  "MessageEntries",
@@ -1163,6 +1303,7 @@ __all__ = [
1163
1303
  "MessageInputEntryContent",
1164
1304
  "MessageInputEntryContentTypedDict",
1165
1305
  "MessageInputEntryRole",
1306
+ "MessageInputEntryType",
1166
1307
  "MessageInputEntryTypedDict",
1167
1308
  "MessageOutputContentChunks",
1168
1309
  "MessageOutputContentChunksTypedDict",
@@ -1217,8 +1358,12 @@ __all__ = [
1217
1358
  "OutputContentChunksTypedDict",
1218
1359
  "Outputs",
1219
1360
  "OutputsTypedDict",
1361
+ "PaginationInfo",
1362
+ "PaginationInfoTypedDict",
1220
1363
  "Prediction",
1221
1364
  "PredictionTypedDict",
1365
+ "ProcessingStatusOut",
1366
+ "ProcessingStatusOutTypedDict",
1222
1367
  "QueryParamStatus",
1223
1368
  "ReferenceChunk",
1224
1369
  "ReferenceChunkType",
@@ -1253,6 +1398,13 @@ __all__ = [
1253
1398
  "SampleType",
1254
1399
  "Security",
1255
1400
  "SecurityTypedDict",
1401
+ "ShareEnum",
1402
+ "SharingDelete",
1403
+ "SharingDeleteTypedDict",
1404
+ "SharingIn",
1405
+ "SharingInTypedDict",
1406
+ "SharingOut",
1407
+ "SharingOutTypedDict",
1256
1408
  "Source",
1257
1409
  "Status",
1258
1410
  "Stop",
@@ -1270,6 +1422,9 @@ __all__ = [
1270
1422
  "ToolChoice",
1271
1423
  "ToolChoiceEnum",
1272
1424
  "ToolChoiceTypedDict",
1425
+ "ToolExecutionDeltaEvent",
1426
+ "ToolExecutionDeltaEventType",
1427
+ "ToolExecutionDeltaEventTypedDict",
1273
1428
  "ToolExecutionDoneEvent",
1274
1429
  "ToolExecutionDoneEventType",
1275
1430
  "ToolExecutionDoneEventTypedDict",
@@ -1412,6 +1567,7 @@ _dynamic_imports: dict[str, str] = {
1412
1567
  "AssistantMessageTypedDict": ".assistantmessage",
1413
1568
  "BaseModelCard": ".basemodelcard",
1414
1569
  "BaseModelCardTypedDict": ".basemodelcard",
1570
+ "Type": ".basemodelcard",
1415
1571
  "BatchError": ".batcherror",
1416
1572
  "BatchErrorTypedDict": ".batcherror",
1417
1573
  "BatchJobIn": ".batchjobin",
@@ -1589,6 +1745,12 @@ _dynamic_imports: dict[str, str] = {
1589
1745
  "DocumentLibraryTool": ".documentlibrarytool",
1590
1746
  "DocumentLibraryToolType": ".documentlibrarytool",
1591
1747
  "DocumentLibraryToolTypedDict": ".documentlibrarytool",
1748
+ "DocumentOut": ".documentout",
1749
+ "DocumentOutTypedDict": ".documentout",
1750
+ "DocumentTextContent": ".documenttextcontent",
1751
+ "DocumentTextContentTypedDict": ".documenttextcontent",
1752
+ "DocumentUpdateIn": ".documentupdatein",
1753
+ "DocumentUpdateInTypedDict": ".documentupdatein",
1592
1754
  "DocumentURLChunk": ".documenturlchunk",
1593
1755
  "DocumentURLChunkType": ".documenturlchunk",
1594
1756
  "DocumentURLChunkTypedDict": ".documenturlchunk",
@@ -1601,8 +1763,11 @@ _dynamic_imports: dict[str, str] = {
1601
1763
  "EmbeddingResponseTypedDict": ".embeddingresponse",
1602
1764
  "EmbeddingResponseData": ".embeddingresponsedata",
1603
1765
  "EmbeddingResponseDataTypedDict": ".embeddingresponsedata",
1766
+ "EntityType": ".entitytype",
1604
1767
  "EventOut": ".eventout",
1605
1768
  "EventOutTypedDict": ".eventout",
1769
+ "File": ".file",
1770
+ "FileTypedDict": ".file",
1606
1771
  "FileChunk": ".filechunk",
1607
1772
  "FileChunkTypedDict": ".filechunk",
1608
1773
  "FilePurpose": ".filepurpose",
@@ -1616,8 +1781,6 @@ _dynamic_imports: dict[str, str] = {
1616
1781
  "FilesAPIRoutesListFilesRequestTypedDict": ".files_api_routes_list_filesop",
1617
1782
  "FilesAPIRoutesRetrieveFileRequest": ".files_api_routes_retrieve_fileop",
1618
1783
  "FilesAPIRoutesRetrieveFileRequestTypedDict": ".files_api_routes_retrieve_fileop",
1619
- "File": ".files_api_routes_upload_fileop",
1620
- "FileTypedDict": ".files_api_routes_upload_fileop",
1621
1784
  "FilesAPIRoutesUploadFileMultiPartBodyParams": ".files_api_routes_upload_fileop",
1622
1785
  "FilesAPIRoutesUploadFileMultiPartBodyParamsTypedDict": ".files_api_routes_upload_fileop",
1623
1786
  "FileSchema": ".fileschema",
@@ -1639,6 +1802,7 @@ _dynamic_imports: dict[str, str] = {
1639
1802
  "FTModelCapabilitiesOut": ".ftmodelcapabilitiesout",
1640
1803
  "FTModelCapabilitiesOutTypedDict": ".ftmodelcapabilitiesout",
1641
1804
  "FTModelCard": ".ftmodelcard",
1805
+ "FTModelCardType": ".ftmodelcard",
1642
1806
  "FTModelCardTypedDict": ".ftmodelcard",
1643
1807
  "Function": ".function",
1644
1808
  "FunctionTypedDict": ".function",
@@ -1747,8 +1911,54 @@ _dynamic_imports: dict[str, str] = {
1747
1911
  "LegacyJobMetadataOut": ".legacyjobmetadataout",
1748
1912
  "LegacyJobMetadataOutObject": ".legacyjobmetadataout",
1749
1913
  "LegacyJobMetadataOutTypedDict": ".legacyjobmetadataout",
1914
+ "LibrariesDeleteV1Request": ".libraries_delete_v1op",
1915
+ "LibrariesDeleteV1RequestTypedDict": ".libraries_delete_v1op",
1916
+ "LibrariesDocumentsDeleteV1Request": ".libraries_documents_delete_v1op",
1917
+ "LibrariesDocumentsDeleteV1RequestTypedDict": ".libraries_documents_delete_v1op",
1918
+ "LibrariesDocumentsGetExtractedTextSignedURLV1Request": ".libraries_documents_get_extracted_text_signed_url_v1op",
1919
+ "LibrariesDocumentsGetExtractedTextSignedURLV1RequestTypedDict": ".libraries_documents_get_extracted_text_signed_url_v1op",
1920
+ "LibrariesDocumentsGetSignedURLV1Request": ".libraries_documents_get_signed_url_v1op",
1921
+ "LibrariesDocumentsGetSignedURLV1RequestTypedDict": ".libraries_documents_get_signed_url_v1op",
1922
+ "LibrariesDocumentsGetStatusV1Request": ".libraries_documents_get_status_v1op",
1923
+ "LibrariesDocumentsGetStatusV1RequestTypedDict": ".libraries_documents_get_status_v1op",
1924
+ "LibrariesDocumentsGetTextContentV1Request": ".libraries_documents_get_text_content_v1op",
1925
+ "LibrariesDocumentsGetTextContentV1RequestTypedDict": ".libraries_documents_get_text_content_v1op",
1926
+ "LibrariesDocumentsGetV1Request": ".libraries_documents_get_v1op",
1927
+ "LibrariesDocumentsGetV1RequestTypedDict": ".libraries_documents_get_v1op",
1928
+ "LibrariesDocumentsListV1Request": ".libraries_documents_list_v1op",
1929
+ "LibrariesDocumentsListV1RequestTypedDict": ".libraries_documents_list_v1op",
1930
+ "LibrariesDocumentsReprocessV1Request": ".libraries_documents_reprocess_v1op",
1931
+ "LibrariesDocumentsReprocessV1RequestTypedDict": ".libraries_documents_reprocess_v1op",
1932
+ "LibrariesDocumentsUpdateV1Request": ".libraries_documents_update_v1op",
1933
+ "LibrariesDocumentsUpdateV1RequestTypedDict": ".libraries_documents_update_v1op",
1934
+ "LibrariesDocumentsUploadV1DocumentUpload": ".libraries_documents_upload_v1op",
1935
+ "LibrariesDocumentsUploadV1DocumentUploadTypedDict": ".libraries_documents_upload_v1op",
1936
+ "LibrariesDocumentsUploadV1Request": ".libraries_documents_upload_v1op",
1937
+ "LibrariesDocumentsUploadV1RequestTypedDict": ".libraries_documents_upload_v1op",
1938
+ "LibrariesGetV1Request": ".libraries_get_v1op",
1939
+ "LibrariesGetV1RequestTypedDict": ".libraries_get_v1op",
1940
+ "LibrariesShareCreateV1Request": ".libraries_share_create_v1op",
1941
+ "LibrariesShareCreateV1RequestTypedDict": ".libraries_share_create_v1op",
1942
+ "LibrariesShareDeleteV1Request": ".libraries_share_delete_v1op",
1943
+ "LibrariesShareDeleteV1RequestTypedDict": ".libraries_share_delete_v1op",
1944
+ "LibrariesShareListV1Request": ".libraries_share_list_v1op",
1945
+ "LibrariesShareListV1RequestTypedDict": ".libraries_share_list_v1op",
1946
+ "LibrariesUpdateV1Request": ".libraries_update_v1op",
1947
+ "LibrariesUpdateV1RequestTypedDict": ".libraries_update_v1op",
1948
+ "LibraryIn": ".libraryin",
1949
+ "LibraryInTypedDict": ".libraryin",
1950
+ "LibraryInUpdate": ".libraryinupdate",
1951
+ "LibraryInUpdateTypedDict": ".libraryinupdate",
1952
+ "LibraryOut": ".libraryout",
1953
+ "LibraryOutTypedDict": ".libraryout",
1954
+ "ListDocumentOut": ".listdocumentout",
1955
+ "ListDocumentOutTypedDict": ".listdocumentout",
1750
1956
  "ListFilesOut": ".listfilesout",
1751
1957
  "ListFilesOutTypedDict": ".listfilesout",
1958
+ "ListLibraryOut": ".listlibraryout",
1959
+ "ListLibraryOutTypedDict": ".listlibraryout",
1960
+ "ListSharingOut": ".listsharingout",
1961
+ "ListSharingOutTypedDict": ".listsharingout",
1752
1962
  "MessageEntries": ".messageentries",
1753
1963
  "MessageEntriesTypedDict": ".messageentries",
1754
1964
  "MessageInputContentChunks": ".messageinputcontentchunks",
@@ -1757,9 +1967,9 @@ _dynamic_imports: dict[str, str] = {
1757
1967
  "MessageInputEntryContent": ".messageinputentry",
1758
1968
  "MessageInputEntryContentTypedDict": ".messageinputentry",
1759
1969
  "MessageInputEntryRole": ".messageinputentry",
1970
+ "MessageInputEntryType": ".messageinputentry",
1760
1971
  "MessageInputEntryTypedDict": ".messageinputentry",
1761
1972
  "Object": ".messageinputentry",
1762
- "Type": ".messageinputentry",
1763
1973
  "MessageOutputContentChunks": ".messageoutputcontentchunks",
1764
1974
  "MessageOutputContentChunksTypedDict": ".messageoutputcontentchunks",
1765
1975
  "MessageOutputEntry": ".messageoutputentry",
@@ -1809,8 +2019,12 @@ _dynamic_imports: dict[str, str] = {
1809
2019
  "OCRUsageInfoTypedDict": ".ocrusageinfo",
1810
2020
  "OutputContentChunks": ".outputcontentchunks",
1811
2021
  "OutputContentChunksTypedDict": ".outputcontentchunks",
2022
+ "PaginationInfo": ".paginationinfo",
2023
+ "PaginationInfoTypedDict": ".paginationinfo",
1812
2024
  "Prediction": ".prediction",
1813
2025
  "PredictionTypedDict": ".prediction",
2026
+ "ProcessingStatusOut": ".processingstatusout",
2027
+ "ProcessingStatusOutTypedDict": ".processingstatusout",
1814
2028
  "ReferenceChunk": ".referencechunk",
1815
2029
  "ReferenceChunkType": ".referencechunk",
1816
2030
  "ReferenceChunkTypedDict": ".referencechunk",
@@ -1836,6 +2050,13 @@ _dynamic_imports: dict[str, str] = {
1836
2050
  "SDKError": ".sdkerror",
1837
2051
  "Security": ".security",
1838
2052
  "SecurityTypedDict": ".security",
2053
+ "ShareEnum": ".shareenum",
2054
+ "SharingDelete": ".sharingdelete",
2055
+ "SharingDeleteTypedDict": ".sharingdelete",
2056
+ "SharingIn": ".sharingin",
2057
+ "SharingInTypedDict": ".sharingin",
2058
+ "SharingOut": ".sharingout",
2059
+ "SharingOutTypedDict": ".sharingout",
1839
2060
  "Source": ".source",
1840
2061
  "SSETypes": ".ssetypes",
1841
2062
  "Role": ".systemmessage",
@@ -1853,6 +2074,9 @@ _dynamic_imports: dict[str, str] = {
1853
2074
  "ToolChoice": ".toolchoice",
1854
2075
  "ToolChoiceTypedDict": ".toolchoice",
1855
2076
  "ToolChoiceEnum": ".toolchoiceenum",
2077
+ "ToolExecutionDeltaEvent": ".toolexecutiondeltaevent",
2078
+ "ToolExecutionDeltaEventType": ".toolexecutiondeltaevent",
2079
+ "ToolExecutionDeltaEventTypedDict": ".toolexecutiondeltaevent",
1856
2080
  "ToolExecutionDoneEvent": ".toolexecutiondoneevent",
1857
2081
  "ToolExecutionDoneEventType": ".toolexecutiondoneevent",
1858
2082
  "ToolExecutionDoneEventTypedDict": ".toolexecutiondoneevent",
@@ -12,6 +12,9 @@ from typing import List, Literal, Optional
12
12
  from typing_extensions import Annotated, NotRequired, TypedDict
13
13
 
14
14
 
15
+ Type = Literal["base"]
16
+
17
+
15
18
  class BaseModelCardTypedDict(TypedDict):
16
19
  id: str
17
20
  capabilities: ModelCapabilitiesTypedDict
@@ -25,7 +28,7 @@ class BaseModelCardTypedDict(TypedDict):
25
28
  deprecation: NotRequired[Nullable[datetime]]
26
29
  deprecation_replacement_model: NotRequired[Nullable[str]]
27
30
  default_model_temperature: NotRequired[Nullable[float]]
28
- type: Literal["base"]
31
+ type: Type
29
32
 
30
33
 
31
34
  class BaseModelCard(BaseModel):
@@ -54,7 +57,7 @@ class BaseModelCard(BaseModel):
54
57
  default_model_temperature: OptionalNullable[float] = UNSET
55
58
 
56
59
  TYPE: Annotated[
57
- Annotated[Optional[Literal["base"]], AfterValidator(validate_const("base"))],
60
+ Annotated[Optional[Type], AfterValidator(validate_const("base"))],
58
61
  pydantic.Field(alias="type"),
59
62
  ] = "base"
60
63
 
@@ -12,6 +12,10 @@ from .responsedoneevent import ResponseDoneEvent, ResponseDoneEventTypedDict
12
12
  from .responseerrorevent import ResponseErrorEvent, ResponseErrorEventTypedDict
13
13
  from .responsestartedevent import ResponseStartedEvent, ResponseStartedEventTypedDict
14
14
  from .ssetypes import SSETypes
15
+ from .toolexecutiondeltaevent import (
16
+ ToolExecutionDeltaEvent,
17
+ ToolExecutionDeltaEventTypedDict,
18
+ )
15
19
  from .toolexecutiondoneevent import (
16
20
  ToolExecutionDoneEvent,
17
21
  ToolExecutionDoneEventTypedDict,
@@ -34,6 +38,7 @@ ConversationEventsDataTypedDict = TypeAliasType(
34
38
  ResponseDoneEventTypedDict,
35
39
  ResponseErrorEventTypedDict,
36
40
  ToolExecutionStartedEventTypedDict,
41
+ ToolExecutionDeltaEventTypedDict,
37
42
  ToolExecutionDoneEventTypedDict,
38
43
  AgentHandoffStartedEventTypedDict,
39
44
  AgentHandoffDoneEventTypedDict,
@@ -52,6 +57,7 @@ ConversationEventsData = Annotated[
52
57
  Annotated[ResponseStartedEvent, Tag("conversation.response.started")],
53
58
  Annotated[FunctionCallEvent, Tag("function.call.delta")],
54
59
  Annotated[MessageOutputEvent, Tag("message.output.delta")],
60
+ Annotated[ToolExecutionDeltaEvent, Tag("tool.execution.delta")],
55
61
  Annotated[ToolExecutionDoneEvent, Tag("tool.execution.done")],
56
62
  Annotated[ToolExecutionStartedEvent, Tag("tool.execution.started")],
57
63
  ],
@@ -17,10 +17,10 @@ ConversationHistoryObject = Literal["conversation.history"]
17
17
  EntriesTypedDict = TypeAliasType(
18
18
  "EntriesTypedDict",
19
19
  Union[
20
- MessageInputEntryTypedDict,
21
20
  FunctionResultEntryTypedDict,
22
- ToolExecutionEntryTypedDict,
21
+ MessageInputEntryTypedDict,
23
22
  FunctionCallEntryTypedDict,
23
+ ToolExecutionEntryTypedDict,
24
24
  MessageOutputEntryTypedDict,
25
25
  AgentHandoffEntryTypedDict,
26
26
  ],
@@ -30,10 +30,10 @@ EntriesTypedDict = TypeAliasType(
30
30
  Entries = TypeAliasType(
31
31
  "Entries",
32
32
  Union[
33
- MessageInputEntry,
34
33
  FunctionResultEntry,
35
- ToolExecutionEntry,
34
+ MessageInputEntry,
36
35
  FunctionCallEntry,
36
+ ToolExecutionEntry,
37
37
  MessageOutputEntry,
38
38
  AgentHandoffEntry,
39
39
  ],
@@ -0,0 +1,105 @@
1
+ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
+
3
+ from __future__ import annotations
4
+ from datetime import datetime
5
+ from mistralai.types import BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL
6
+ from pydantic import model_serializer
7
+ from typing_extensions import NotRequired, TypedDict
8
+
9
+
10
+ class DocumentOutTypedDict(TypedDict):
11
+ id: str
12
+ library_id: str
13
+ hash: str
14
+ mime_type: str
15
+ extension: str
16
+ size: int
17
+ name: str
18
+ created_at: datetime
19
+ processing_status: str
20
+ uploaded_by_id: str
21
+ uploaded_by_type: str
22
+ tokens_processing_total: int
23
+ summary: NotRequired[Nullable[str]]
24
+ last_processed_at: NotRequired[Nullable[datetime]]
25
+ number_of_pages: NotRequired[Nullable[int]]
26
+ tokens_processing_main_content: NotRequired[Nullable[int]]
27
+ tokens_processing_summary: NotRequired[Nullable[int]]
28
+
29
+
30
+ class DocumentOut(BaseModel):
31
+ id: str
32
+
33
+ library_id: str
34
+
35
+ hash: str
36
+
37
+ mime_type: str
38
+
39
+ extension: str
40
+
41
+ size: int
42
+
43
+ name: str
44
+
45
+ created_at: datetime
46
+
47
+ processing_status: str
48
+
49
+ uploaded_by_id: str
50
+
51
+ uploaded_by_type: str
52
+
53
+ tokens_processing_total: int
54
+
55
+ summary: OptionalNullable[str] = UNSET
56
+
57
+ last_processed_at: OptionalNullable[datetime] = UNSET
58
+
59
+ number_of_pages: OptionalNullable[int] = UNSET
60
+
61
+ tokens_processing_main_content: OptionalNullable[int] = UNSET
62
+
63
+ tokens_processing_summary: OptionalNullable[int] = UNSET
64
+
65
+ @model_serializer(mode="wrap")
66
+ def serialize_model(self, handler):
67
+ optional_fields = [
68
+ "summary",
69
+ "last_processed_at",
70
+ "number_of_pages",
71
+ "tokens_processing_main_content",
72
+ "tokens_processing_summary",
73
+ ]
74
+ nullable_fields = [
75
+ "summary",
76
+ "last_processed_at",
77
+ "number_of_pages",
78
+ "tokens_processing_main_content",
79
+ "tokens_processing_summary",
80
+ ]
81
+ null_default_fields = []
82
+
83
+ serialized = handler(self)
84
+
85
+ m = {}
86
+
87
+ for n, f in type(self).model_fields.items():
88
+ k = f.alias or n
89
+ val = serialized.get(k)
90
+ serialized.pop(k, None)
91
+
92
+ optional_nullable = k in optional_fields and k in nullable_fields
93
+ is_set = (
94
+ self.__pydantic_fields_set__.intersection({n})
95
+ or k in null_default_fields
96
+ ) # pylint: disable=no-member
97
+
98
+ if val is not None and val != UNSET_SENTINEL:
99
+ m[k] = val
100
+ elif val != UNSET_SENTINEL and (
101
+ not k in optional_fields or (optional_nullable and is_set)
102
+ ):
103
+ m[k] = val
104
+
105
+ return m
@@ -0,0 +1,13 @@
1
+ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
+
3
+ from __future__ import annotations
4
+ from mistralai.types import BaseModel
5
+ from typing_extensions import TypedDict
6
+
7
+
8
+ class DocumentTextContentTypedDict(TypedDict):
9
+ text: str
10
+
11
+
12
+ class DocumentTextContent(BaseModel):
13
+ text: str