mixpeek 0.20.20__py3-none-any.whl → 0.21.6__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 (228) hide show
  1. mixpeek/_version.py +3 -3
  2. mixpeek/{assets.py → bucketobjects.py} +309 -793
  3. mixpeek/buckets.py +1292 -0
  4. mixpeek/clusters.py +306 -0
  5. mixpeek/collectioncache.py +820 -0
  6. mixpeek/{taxonomyentities.py → collectiondocuments.py} +305 -559
  7. mixpeek/collections.py +120 -994
  8. mixpeek/features.py +45 -991
  9. mixpeek/models/__init__.py +625 -570
  10. mixpeek/models/aggregationtype.py +13 -0
  11. mixpeek/models/apikeyupdate.py +1 -1
  12. mixpeek/models/attributebasedconfig.py +21 -0
  13. mixpeek/models/automaticnaming.py +29 -0
  14. mixpeek/models/basicfeatureextractor.py +35 -0
  15. mixpeek/models/{classify_features_v1_entities_taxonomies_taxonomy_classify_postop.py → batch_delete_documents_v1_collections_collection_identifier_documents_batch_deleteop.py} +17 -15
  16. mixpeek/models/{update_collection_v1_collections_collection_putop.py → batch_update_documents_v1_collections_collection_identifier_documents_batch_putop.py} +29 -19
  17. mixpeek/models/blobdetails.py +72 -0
  18. mixpeek/models/blobmodel.py +107 -0
  19. mixpeek/models/bucketcreaterequest.py +75 -0
  20. mixpeek/models/bucketresponse.py +90 -0
  21. mixpeek/models/bucketschema_input.py +37 -0
  22. mixpeek/models/bucketschema_output.py +37 -0
  23. mixpeek/models/{featureresponse.py → bucketschemafield_input.py} +45 -18
  24. mixpeek/models/bucketschemafield_output.py +101 -0
  25. mixpeek/models/bucketschemafieldtype.py +29 -0
  26. mixpeek/models/bucketupdaterequest.py +68 -0
  27. mixpeek/models/cachestats.py +40 -0
  28. mixpeek/models/{list_collections_v1_collections_getop.py → cleanup_cache_v1_collections_cache_cleanup_postop.py} +23 -12
  29. mixpeek/models/{inputtype.py → clusteringmethod.py} +3 -5
  30. mixpeek/models/clustertype.py +9 -0
  31. mixpeek/models/collectioncacheconfig_input.py +92 -0
  32. mixpeek/models/collectioncacheconfig_output.py +92 -0
  33. mixpeek/models/collectionconfig.py +32 -0
  34. mixpeek/models/collectionmodel.py +79 -8
  35. mixpeek/models/{create_taxonomy_v1_entities_taxonomies_postop.py → create_bucket_v1_buckets_create_postop.py} +7 -7
  36. mixpeek/models/{search_assets_v1_assets_search_postop.py → create_cluster_v1_clusters_postop.py} +7 -7
  37. mixpeek/models/{create_collection_v1_collections_postop.py → create_collection_v1_collections_create_postop.py} +3 -3
  38. mixpeek/models/{ingest_video_url_v1_ingest_videos_url_postop.py → create_interaction_v1_retrievers_interactions_postop.py} +7 -7
  39. mixpeek/models/{partial_asset_update_v1_assets_asset_id_patchop.py → create_object_v1_buckets_bucket_identifier_objects_create_postop.py} +11 -9
  40. mixpeek/models/{ingest_text_v1_ingest_text_postop.py → create_retriever_v1_retrievers_retrievers_postop.py} +10 -7
  41. mixpeek/models/{ingest_image_url_v1_ingest_images_url_postop.py → create_taxonomy_v1_taxonomies_postop.py} +7 -7
  42. mixpeek/models/createblobrequest.py +80 -0
  43. mixpeek/models/createclusterrequest.py +74 -0
  44. mixpeek/models/createcollectionrequest.py +72 -3
  45. mixpeek/models/createnamespacerequest.py +14 -8
  46. mixpeek/models/createobjectrequest.py +75 -0
  47. mixpeek/models/createretrieverrequest.py +90 -0
  48. mixpeek/models/{taxonomyupdate.py → createtaxonomyrequest.py} +15 -13
  49. mixpeek/models/{delete_asset_v1_assets_asset_id_deleteop.py → delete_bucket_v1_buckets_bucket_identifier_deleteop.py} +5 -5
  50. mixpeek/models/{delete_classifications_v1_entities_taxonomies_taxonomy_classifications_classification_id_deleteop.py → delete_document_v1_collections_collection_identifier_documents_document_id_deleteop.py} +11 -11
  51. mixpeek/models/{get_taxonomy_v1_entities_taxonomies_taxonomy_getop.py → delete_interaction_v1_retrievers_interactions_interaction_id_deleteop.py} +7 -7
  52. mixpeek/models/delete_object_v1_buckets_bucket_identifier_objects_object_identifier_deleteop.py +70 -0
  53. mixpeek/models/{featureextractionembeddingrequest.py → documenthandlingconfig.py} +12 -15
  54. mixpeek/models/documentinputhandling.py +11 -0
  55. mixpeek/models/{jsontextoutputsettings.py → documentlistresponse.py} +15 -14
  56. mixpeek/models/documentoutputhandling.py +10 -0
  57. mixpeek/models/documentoutputtype.py +11 -0
  58. mixpeek/models/documentresponse.py +87 -0
  59. mixpeek/models/{nodeupdate.py → documentupdate.py} +22 -13
  60. mixpeek/models/enrichmentfield.py +25 -0
  61. mixpeek/models/errordetail.py +1 -1
  62. mixpeek/models/{update_node_v1_entities_taxonomies_nodes_node_patchop.py → execute_retriever_v1_retrievers_retrievers_retriever_id_execute_postop.py} +11 -11
  63. mixpeek/models/featureextractorconfig.py +116 -0
  64. mixpeek/models/featureextractordefinition.py +192 -0
  65. mixpeek/models/filtercondition.py +25 -25
  66. mixpeek/models/filteroperator.py +24 -0
  67. mixpeek/models/generativemodels.py +10 -0
  68. mixpeek/models/{delete_feature_v1_features_feature_id_deleteop.py → get_bucket_v1_buckets_bucket_identifier_getop.py} +5 -5
  69. mixpeek/models/{list_taxonomies_v1_entities_taxonomies_getop.py → get_cache_stats_v1_collections_cache_stats_getop.py} +16 -14
  70. mixpeek/models/get_collection_v1_collections_collection_id_getop.py +59 -0
  71. mixpeek/models/get_document_v1_collections_collection_identifier_documents_document_id_getop.py +70 -0
  72. mixpeek/models/get_feature_extractor_v1_features_extractors_feature_id_getop.py +16 -0
  73. mixpeek/models/get_interaction_v1_retrievers_interactions_interaction_id_getop.py +57 -0
  74. mixpeek/models/{delete_collection_v1_collections_collection_deleteop.py → get_object_v1_buckets_bucket_identifier_objects_object_identifier_getop.py} +16 -7
  75. mixpeek/models/get_research_v1_research_getop.py +52 -0
  76. mixpeek/models/get_retriever_stages_v1_retrievers_stages_getop.py +52 -0
  77. mixpeek/models/{delete_taxonomy_v1_entities_taxonomies_taxonomy_deleteop.py → get_retriever_v1_retrievers_retrievers_retriever_id_getop.py} +5 -7
  78. mixpeek/models/get_task_v1_tasks_task_id_getop.py +1 -1
  79. mixpeek/models/getusagerequestmodel.py +91 -0
  80. mixpeek/models/hdbscanparameters.py +26 -0
  81. mixpeek/models/interactionresponse.py +86 -0
  82. mixpeek/models/interactiontype.py +22 -0
  83. mixpeek/models/{search_features_v1_features_search_postop.py → invalidate_cache_v1_collections_cache_invalidate_postop.py} +60 -34
  84. mixpeek/models/invalidationevent.py +67 -0
  85. mixpeek/models/invalidationstrategy.py +12 -0
  86. mixpeek/models/kill_task_v1_tasks_task_id_deleteop.py +1 -1
  87. mixpeek/models/list_active_tasks_v1_tasks_getop.py +1 -1
  88. mixpeek/models/{list_assets_v1_assets_postop.py → list_buckets_v1_buckets_postop.py} +18 -18
  89. mixpeek/models/{list_features_v1_features_postop.py → list_documents_v1_collections_collection_identifier_documents_getop.py} +54 -19
  90. mixpeek/models/list_interactions_v1_retrievers_interactions_getop.py +96 -0
  91. mixpeek/models/{list_classifications_v1_entities_taxonomies_taxonomy_classifications_postop.py → list_objects_v1_buckets_bucket_identifier_objects_postop.py} +22 -29
  92. mixpeek/models/{groupbyoptionsasset.py → listbucketsrequest.py} +19 -28
  93. mixpeek/models/listbucketsresponse.py +23 -0
  94. mixpeek/models/{groupbyoptions.py → listobjectsrequest.py} +19 -28
  95. mixpeek/models/listobjectsresponse.py +25 -0
  96. mixpeek/models/listtasksresponse.py +3 -6
  97. mixpeek/models/{logicaloperator.py → logicaloperator_input.py} +42 -24
  98. mixpeek/models/logicaloperator_output.py +121 -0
  99. mixpeek/models/multivectorindex.py +25 -0
  100. mixpeek/models/namespaceresponse.py +1 -1
  101. mixpeek/models/namespaceusage.py +45 -0
  102. mixpeek/models/namingmethod.py +8 -0
  103. mixpeek/models/objectresponse.py +124 -0
  104. mixpeek/models/{db_model_paginationresponse.py → paginationresponse.py} +3 -3
  105. mixpeek/models/payloadindexconfig.py +1 -1
  106. mixpeek/models/plan.py +82 -0
  107. mixpeek/models/recomputestrategy.py +12 -0
  108. mixpeek/models/resourcetotals.py +39 -0
  109. mixpeek/models/{jsonvideooutputsettings.py → retrieverbinding.py} +19 -11
  110. mixpeek/models/{logodetectsettings.py → retrievercacheconfig.py} +20 -11
  111. mixpeek/models/retrievermodel.py +95 -0
  112. mixpeek/models/retrieverqueryrequest.py +114 -0
  113. mixpeek/models/retrieverresponse.py +24 -0
  114. mixpeek/models/searchinteraction.py +81 -0
  115. mixpeek/models/singlelineageentry.py +99 -0
  116. mixpeek/models/sortdirection.py +11 -0
  117. mixpeek/models/sortoption.py +20 -12
  118. mixpeek/models/sourceconfig_input.py +72 -0
  119. mixpeek/models/sourceconfig_output.py +75 -0
  120. mixpeek/models/sourcetype.py +11 -0
  121. mixpeek/models/stageconfig_input.py +111 -0
  122. mixpeek/models/stageconfig_output.py +114 -0
  123. mixpeek/models/stagedefinition.py +110 -0
  124. mixpeek/models/{jsonimageoutputsettings.py → stageresponse.py} +21 -11
  125. mixpeek/models/taskresponse.py +1 -1
  126. mixpeek/models/taskstatus.py +1 -0
  127. mixpeek/models/{assetfeatures.py → taxonomyapplicationconfig.py} +23 -15
  128. mixpeek/models/taxonomyconfig.py +19 -0
  129. mixpeek/models/timeseriesdatapoint.py +25 -0
  130. mixpeek/models/timeseriesusage.py +36 -0
  131. mixpeek/models/{full_asset_update_v1_assets_asset_id_putop.py → update_bucket_v1_buckets_bucket_identifier_putop.py} +9 -9
  132. mixpeek/models/{update_taxonomy_v1_entities_taxonomies_taxonomy_patchop.py → update_document_v1_collections_collection_identifier_documents_document_id_putop.py} +25 -13
  133. mixpeek/models/{full_feature_update_v1_features_feature_id_putop.py → update_object_v1_buckets_bucket_identifier_objects_object_identifier_putop.py} +20 -9
  134. mixpeek/models/updatenamespacerequest.py +1 -1
  135. mixpeek/models/updateobjectrequest.py +75 -0
  136. mixpeek/models/usageresponse.py +86 -0
  137. mixpeek/models/usagesummary.py +39 -0
  138. mixpeek/models/usagetimerange.py +16 -0
  139. mixpeek/models/usermodel_input.py +3 -0
  140. mixpeek/models/usermodel_output.py +3 -0
  141. mixpeek/models/vectorbasedconfig.py +60 -0
  142. mixpeek/models/{collectionresult.py → vectorindex.py} +20 -15
  143. mixpeek/models/vectorindexdefinition.py +43 -0
  144. mixpeek/models/vectortype.py +4 -1
  145. mixpeek/namespaces.py +26 -480
  146. mixpeek/organizationnotifications.py +214 -0
  147. mixpeek/organizations.py +6 -210
  148. mixpeek/{featureextractors.py → organizationsusage.py} +31 -39
  149. mixpeek/research.py +228 -0
  150. mixpeek/retrieverinteractions.py +1036 -0
  151. mixpeek/{ingestassets.py → retrievers.py} +209 -271
  152. mixpeek/retrieverstages.py +232 -0
  153. mixpeek/sdk.py +40 -23
  154. mixpeek/taxonomies.py +43 -513
  155. mixpeek/types/basemodel.py +3 -3
  156. mixpeek/utils/enums.py +67 -27
  157. {mixpeek-0.20.20.dist-info → mixpeek-0.21.6.dist-info}/METADATA +68 -50
  158. mixpeek-0.21.6.dist-info/RECORD +216 -0
  159. {mixpeek-0.20.20.dist-info → mixpeek-0.21.6.dist-info}/WHEEL +1 -1
  160. mixpeek/models/actionusage.py +0 -16
  161. mixpeek/models/assetresponse.py +0 -166
  162. mixpeek/models/assets_model_searchquery.py +0 -21
  163. mixpeek/models/assetupdate.py +0 -28
  164. mixpeek/models/assignmentconfig.py +0 -67
  165. mixpeek/models/assignmentmode.py +0 -11
  166. mixpeek/models/availablemodels.py +0 -16
  167. mixpeek/models/availablemodelsresponse.py +0 -27
  168. mixpeek/models/classificationmatch.py +0 -77
  169. mixpeek/models/classificationwithfeature.py +0 -73
  170. mixpeek/models/collectiondetailsresponse.py +0 -83
  171. mixpeek/models/dateusage.py +0 -22
  172. mixpeek/models/denseembedding.py +0 -16
  173. mixpeek/models/discoverrequest.py +0 -64
  174. mixpeek/models/embeddingconfig.py +0 -33
  175. mixpeek/models/embeddingrequest.py +0 -92
  176. mixpeek/models/embeddingresponse.py +0 -64
  177. mixpeek/models/entitysettings.py +0 -50
  178. mixpeek/models/featureoptions.py +0 -25
  179. mixpeek/models/features_model_paginationresponse.py +0 -59
  180. mixpeek/models/featureupdaterequest.py +0 -21
  181. mixpeek/models/get_asset_v1_assets_asset_id_getop.py +0 -73
  182. mixpeek/models/get_asset_with_features_v1_assets_asset_id_features_getop.py +0 -73
  183. mixpeek/models/get_collection_details_v1_collections_collection_details_getop.py +0 -59
  184. mixpeek/models/get_collection_details_v1_collections_collection_getop.py +0 -59
  185. mixpeek/models/get_feature_v1_features_feature_id_getop.py +0 -70
  186. mixpeek/models/get_taxonomy_node_v1_entities_taxonomies_nodes_node_getop.py +0 -59
  187. mixpeek/models/groupedassetdata.py +0 -18
  188. mixpeek/models/imagedescribesettings.py +0 -82
  189. mixpeek/models/imagedetectsettings.py +0 -47
  190. mixpeek/models/imagereadsettings.py +0 -71
  191. mixpeek/models/imagesettings.py +0 -92
  192. mixpeek/models/listassetsrequest.py +0 -75
  193. mixpeek/models/listassetsresponse.py +0 -22
  194. mixpeek/models/listclassificationsrequest.py +0 -69
  195. mixpeek/models/listclassificationsresponse.py +0 -31
  196. mixpeek/models/listcollectionsresponse.py +0 -22
  197. mixpeek/models/listfeaturesrequest.py +0 -77
  198. mixpeek/models/listfeaturesresponse.py +0 -22
  199. mixpeek/models/listtaxonomiesresponse.py +0 -24
  200. mixpeek/models/modality.py +0 -13
  201. mixpeek/models/modeldetails.py +0 -61
  202. mixpeek/models/nodeoptions.py +0 -16
  203. mixpeek/models/patch_namespace_v1_namespaces_namespace_patchop.py +0 -28
  204. mixpeek/models/payloadindextype.py +0 -17
  205. mixpeek/models/processimageurlinput.py +0 -87
  206. mixpeek/models/processtextinput.py +0 -82
  207. mixpeek/models/processvideourlinput.py +0 -87
  208. mixpeek/models/querysettings.py +0 -56
  209. mixpeek/models/rerankingoptions.py +0 -47
  210. mixpeek/models/search_model_searchquery.py +0 -76
  211. mixpeek/models/searchassetsrequest.py +0 -78
  212. mixpeek/models/searchrequestfeatures.py +0 -153
  213. mixpeek/models/sparseembedding.py +0 -21
  214. mixpeek/models/taxonomycreate.py +0 -20
  215. mixpeek/models/taxonomyextractionconfig.py +0 -26
  216. mixpeek/models/taxonomymodel.py +0 -27
  217. mixpeek/models/taxonomynode.py +0 -101
  218. mixpeek/models/taxonomynodecreate.py +0 -63
  219. mixpeek/models/textsettings.py +0 -67
  220. mixpeek/models/updateassetrequest.py +0 -60
  221. mixpeek/models/usage.py +0 -18
  222. mixpeek/models/vectormodel.py +0 -15
  223. mixpeek/models/videodescribesettings.py +0 -82
  224. mixpeek/models/videodetectsettings.py +0 -47
  225. mixpeek/models/videoreadsettings.py +0 -71
  226. mixpeek/models/videosettings.py +0 -115
  227. mixpeek/models/videotranscriptionsettings.py +0 -69
  228. mixpeek-0.20.20.dist-info/RECORD +0 -201
@@ -1,76 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .availablemodels import AvailableModels
5
- from .logicaloperator import LogicalOperator, LogicalOperatorTypedDict
6
- from .querysettings import QuerySettings, QuerySettingsTypedDict
7
- from enum import Enum
8
- from mixpeek.types import BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL
9
- from pydantic import model_serializer
10
- from typing_extensions import NotRequired, TypedDict
11
-
12
-
13
- class Type(str, Enum):
14
- r"""Type of input (text, url, or base64)"""
15
-
16
- TEXT = "text"
17
- URL = "url"
18
- BASE64 = "base64"
19
-
20
-
21
- class SearchModelSearchQueryTypedDict(TypedDict):
22
- embedding_model: AvailableModels
23
- value: str
24
- r"""Query value - can be text, URL, or base64 encoded image"""
25
- type: Type
26
- r"""Type of input (text, url, or base64)"""
27
- filters: NotRequired[Nullable[LogicalOperatorTypedDict]]
28
- r"""Optional filters for the query, this is used for filtering individual vector indexes"""
29
- settings: NotRequired[Nullable[QuerySettingsTypedDict]]
30
- r"""Optional settings for this specific query"""
31
-
32
-
33
- class SearchModelSearchQuery(BaseModel):
34
- embedding_model: AvailableModels
35
-
36
- value: str
37
- r"""Query value - can be text, URL, or base64 encoded image"""
38
-
39
- type: Type
40
- r"""Type of input (text, url, or base64)"""
41
-
42
- filters: OptionalNullable[LogicalOperator] = UNSET
43
- r"""Optional filters for the query, this is used for filtering individual vector indexes"""
44
-
45
- settings: OptionalNullable[QuerySettings] = UNSET
46
- r"""Optional settings for this specific query"""
47
-
48
- @model_serializer(mode="wrap")
49
- def serialize_model(self, handler):
50
- optional_fields = ["filters", "settings"]
51
- nullable_fields = ["filters", "settings"]
52
- null_default_fields = []
53
-
54
- serialized = handler(self)
55
-
56
- m = {}
57
-
58
- for n, f in self.model_fields.items():
59
- k = f.alias or n
60
- val = serialized.get(k)
61
- serialized.pop(k, None)
62
-
63
- optional_nullable = k in optional_fields and k in nullable_fields
64
- is_set = (
65
- self.__pydantic_fields_set__.intersection({n})
66
- or k in null_default_fields
67
- ) # pylint: disable=no-member
68
-
69
- if val is not None and val != UNSET_SENTINEL:
70
- m[k] = val
71
- elif val != UNSET_SENTINEL and (
72
- not k in optional_fields or (optional_nullable and is_set)
73
- ):
74
- m[k] = val
75
-
76
- return m
@@ -1,78 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .assets_model_searchquery import (
5
- AssetsModelSearchQuery,
6
- AssetsModelSearchQueryTypedDict,
7
- )
8
- from .logicaloperator import LogicalOperator, LogicalOperatorTypedDict
9
- from .sortoption import SortOption, SortOptionTypedDict
10
- from mixpeek.types import BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL
11
- from pydantic import model_serializer
12
- from typing import List
13
- from typing_extensions import NotRequired, TypedDict
14
-
15
-
16
- class SearchAssetsRequestTypedDict(TypedDict):
17
- collections: List[str]
18
- r"""List of Collection IDs or Names to search within, required"""
19
- query: NotRequired[Nullable[AssetsModelSearchQueryTypedDict]]
20
- r"""Structured query object specifying which fields to search in and what to search for"""
21
- filters: NotRequired[Nullable[LogicalOperatorTypedDict]]
22
- r"""Complex nested query filters"""
23
- sort: NotRequired[Nullable[SortOptionTypedDict]]
24
- r"""List of fields to sort by"""
25
- select: NotRequired[Nullable[List[str]]]
26
- r"""List of fields to return in results"""
27
- return_url: NotRequired[Nullable[bool]]
28
- r"""Return the presigned URL for the asset and preview asset, this will introduce additional latency"""
29
-
30
-
31
- class SearchAssetsRequest(BaseModel):
32
- collections: List[str]
33
- r"""List of Collection IDs or Names to search within, required"""
34
-
35
- query: OptionalNullable[AssetsModelSearchQuery] = UNSET
36
- r"""Structured query object specifying which fields to search in and what to search for"""
37
-
38
- filters: OptionalNullable[LogicalOperator] = UNSET
39
- r"""Complex nested query filters"""
40
-
41
- sort: OptionalNullable[SortOption] = UNSET
42
- r"""List of fields to sort by"""
43
-
44
- select: OptionalNullable[List[str]] = UNSET
45
- r"""List of fields to return in results"""
46
-
47
- return_url: OptionalNullable[bool] = UNSET
48
- r"""Return the presigned URL for the asset and preview asset, this will introduce additional latency"""
49
-
50
- @model_serializer(mode="wrap")
51
- def serialize_model(self, handler):
52
- optional_fields = ["query", "filters", "sort", "select", "return_url"]
53
- nullable_fields = ["query", "filters", "sort", "select", "return_url"]
54
- null_default_fields = []
55
-
56
- serialized = handler(self)
57
-
58
- m = {}
59
-
60
- for n, f in self.model_fields.items():
61
- k = f.alias or n
62
- val = serialized.get(k)
63
- serialized.pop(k, None)
64
-
65
- optional_nullable = k in optional_fields and k in nullable_fields
66
- is_set = (
67
- self.__pydantic_fields_set__.intersection({n})
68
- or k in null_default_fields
69
- ) # pylint: disable=no-member
70
-
71
- if val is not None and val != UNSET_SENTINEL:
72
- m[k] = val
73
- elif val != UNSET_SENTINEL and (
74
- not k in optional_fields or (optional_nullable and is_set)
75
- ):
76
- m[k] = val
77
-
78
- return m
@@ -1,153 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .groupbyoptions import GroupByOptions, GroupByOptionsTypedDict
5
- from .logicaloperator import LogicalOperator, LogicalOperatorTypedDict
6
- from .rerankingoptions import RerankingOptions, RerankingOptionsTypedDict
7
- from .search_model_searchquery import (
8
- SearchModelSearchQuery,
9
- SearchModelSearchQueryTypedDict,
10
- )
11
- from .sortoption import SortOption, SortOptionTypedDict
12
- from mixpeek.types import BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL
13
- from pydantic import model_serializer
14
- from typing import List
15
- from typing_extensions import NotRequired, TypedDict
16
-
17
-
18
- class SearchRequestFeaturesTypedDict(TypedDict):
19
- collections: List[str]
20
- r"""List of Collection names to search within, required"""
21
- queries: NotRequired[Nullable[List[SearchModelSearchQueryTypedDict]]]
22
- r"""List of search queries to perform.
23
-
24
- Behavior:
25
- - Single query: Results are returned directly from that query
26
- - Multiple queries: Results are combined using Reciprocal Rank Fusion (RRF)
27
-
28
- RRF combines results from multiple queries by:
29
- 1. Taking each item's rank position in each result list
30
- 2. Re-ranking all items by their combined RRF scores
31
-
32
- When merging lists from different sources,
33
- RRF considers all items that appear in any of the input lists,
34
- not just items that appear in all lists.
35
-
36
- This helps surface items that rank well across multiple queries while
37
- reducing the impact of outlier high rankings in single queries.
38
-
39
- NOTE: If query array is empty, it will return all features.
40
-
41
-
42
- """
43
- filters: NotRequired[Nullable[LogicalOperatorTypedDict]]
44
- r"""Used for filtering across all indexes"""
45
- group_by: NotRequired[Nullable[GroupByOptionsTypedDict]]
46
- r"""Grouping options for search results"""
47
- sort: NotRequired[Nullable[SortOptionTypedDict]]
48
- r"""List of fields to sort by, with direction (asc or desc). Supports dot notation for nested fields."""
49
- select: NotRequired[Nullable[List[str]]]
50
- r"""List of fields to return in results, supports dot notation. If None, all fields are returned."""
51
- reranking_options: NotRequired[Nullable[RerankingOptionsTypedDict]]
52
- r"""Options for ranking the search results, including weights and feedback application"""
53
- session_id: NotRequired[Nullable[str]]
54
- r"""Identifier for tracking search session interactions"""
55
- return_url: NotRequired[Nullable[bool]]
56
- r"""Return the presigned URL for the asset and preview asset, this will introduce additional latency"""
57
-
58
-
59
- class SearchRequestFeatures(BaseModel):
60
- collections: List[str]
61
- r"""List of Collection names to search within, required"""
62
-
63
- queries: OptionalNullable[List[SearchModelSearchQuery]] = UNSET
64
- r"""List of search queries to perform.
65
-
66
- Behavior:
67
- - Single query: Results are returned directly from that query
68
- - Multiple queries: Results are combined using Reciprocal Rank Fusion (RRF)
69
-
70
- RRF combines results from multiple queries by:
71
- 1. Taking each item's rank position in each result list
72
- 2. Re-ranking all items by their combined RRF scores
73
-
74
- When merging lists from different sources,
75
- RRF considers all items that appear in any of the input lists,
76
- not just items that appear in all lists.
77
-
78
- This helps surface items that rank well across multiple queries while
79
- reducing the impact of outlier high rankings in single queries.
80
-
81
- NOTE: If query array is empty, it will return all features.
82
-
83
-
84
- """
85
-
86
- filters: OptionalNullable[LogicalOperator] = UNSET
87
- r"""Used for filtering across all indexes"""
88
-
89
- group_by: OptionalNullable[GroupByOptions] = UNSET
90
- r"""Grouping options for search results"""
91
-
92
- sort: OptionalNullable[SortOption] = UNSET
93
- r"""List of fields to sort by, with direction (asc or desc). Supports dot notation for nested fields."""
94
-
95
- select: OptionalNullable[List[str]] = UNSET
96
- r"""List of fields to return in results, supports dot notation. If None, all fields are returned."""
97
-
98
- reranking_options: OptionalNullable[RerankingOptions] = UNSET
99
- r"""Options for ranking the search results, including weights and feedback application"""
100
-
101
- session_id: OptionalNullable[str] = UNSET
102
- r"""Identifier for tracking search session interactions"""
103
-
104
- return_url: OptionalNullable[bool] = UNSET
105
- r"""Return the presigned URL for the asset and preview asset, this will introduce additional latency"""
106
-
107
- @model_serializer(mode="wrap")
108
- def serialize_model(self, handler):
109
- optional_fields = [
110
- "queries",
111
- "filters",
112
- "group_by",
113
- "sort",
114
- "select",
115
- "reranking_options",
116
- "session_id",
117
- "return_url",
118
- ]
119
- nullable_fields = [
120
- "queries",
121
- "filters",
122
- "group_by",
123
- "sort",
124
- "select",
125
- "reranking_options",
126
- "session_id",
127
- "return_url",
128
- ]
129
- null_default_fields = []
130
-
131
- serialized = handler(self)
132
-
133
- m = {}
134
-
135
- for n, f in self.model_fields.items():
136
- k = f.alias or n
137
- val = serialized.get(k)
138
- serialized.pop(k, None)
139
-
140
- optional_nullable = k in optional_fields and k in nullable_fields
141
- is_set = (
142
- self.__pydantic_fields_set__.intersection({n})
143
- or k in null_default_fields
144
- ) # pylint: disable=no-member
145
-
146
- if val is not None and val != UNSET_SENTINEL:
147
- m[k] = val
148
- elif val != UNSET_SENTINEL and (
149
- not k in optional_fields or (optional_nullable and is_set)
150
- ):
151
- m[k] = val
152
-
153
- return m
@@ -1,21 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from mixpeek.types import BaseModel
5
- from typing import List
6
- from typing_extensions import TypedDict
7
-
8
-
9
- class SparseEmbeddingTypedDict(TypedDict):
10
- indices: List[int]
11
- r"""Indices for sparse vector"""
12
- values: List[float]
13
- r"""Values for sparse vector"""
14
-
15
-
16
- class SparseEmbedding(BaseModel):
17
- indices: List[int]
18
- r"""Indices for sparse vector"""
19
-
20
- values: List[float]
21
- r"""Values for sparse vector"""
@@ -1,20 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .taxonomynodecreate import TaxonomyNodeCreate, TaxonomyNodeCreateTypedDict
5
- from mixpeek.types import BaseModel
6
- from typing import List
7
- from typing_extensions import TypedDict
8
-
9
-
10
- class TaxonomyCreateTypedDict(TypedDict):
11
- taxonomy_name: str
12
- r"""Taxonomy name (must not contain spaces or special characters)"""
13
- nodes: List[TaxonomyNodeCreateTypedDict]
14
-
15
-
16
- class TaxonomyCreate(BaseModel):
17
- taxonomy_name: str
18
- r"""Taxonomy name (must not contain spaces or special characters)"""
19
-
20
- nodes: List[TaxonomyNodeCreate]
@@ -1,26 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .assignmentconfig import AssignmentConfig, AssignmentConfigTypedDict
5
- from mixpeek.types import BaseModel
6
- from typing import Optional
7
- from typing_extensions import NotRequired, TypedDict
8
-
9
-
10
- class TaxonomyExtractionConfigTypedDict(TypedDict):
11
- r"""Configuration for taxonomy-based entity extraction during ingestion"""
12
-
13
- taxonomy: str
14
- r"""Taxonomy name or ID to use for classification"""
15
- assignment: NotRequired[AssignmentConfigTypedDict]
16
- r"""Configuration for how classifications should be assigned to features"""
17
-
18
-
19
- class TaxonomyExtractionConfig(BaseModel):
20
- r"""Configuration for taxonomy-based entity extraction during ingestion"""
21
-
22
- taxonomy: str
23
- r"""Taxonomy name or ID to use for classification"""
24
-
25
- assignment: Optional[AssignmentConfig] = None
26
- r"""Configuration for how classifications should be assigned to features"""
@@ -1,27 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .taxonomynode import TaxonomyNode, TaxonomyNodeTypedDict
5
- from mixpeek.types import BaseModel
6
- from typing import List, Optional
7
- from typing_extensions import NotRequired, TypedDict
8
-
9
-
10
- class TaxonomyModelTypedDict(TypedDict):
11
- taxonomy_name: str
12
- r"""Taxonomy name"""
13
- nodes: List[TaxonomyNodeTypedDict]
14
- r"""Taxonomy nodes"""
15
- taxonomy_id: NotRequired[str]
16
- r"""Auto-generated taxonomy identifier"""
17
-
18
-
19
- class TaxonomyModel(BaseModel):
20
- taxonomy_name: str
21
- r"""Taxonomy name"""
22
-
23
- nodes: List[TaxonomyNode]
24
- r"""Taxonomy nodes"""
25
-
26
- taxonomy_id: Optional[str] = None
27
- r"""Auto-generated taxonomy identifier"""
@@ -1,101 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .embeddingconfig import EmbeddingConfig, EmbeddingConfigTypedDict
5
- from mixpeek.types import BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL
6
- from pydantic import model_serializer
7
- from typing import List, Optional
8
- from typing_extensions import NotRequired, TypedDict
9
-
10
-
11
- class TaxonomyNodeTypedDict(TypedDict):
12
- taxonomy_id: str
13
- r"""ID of the taxonomy this node belongs to"""
14
- node_name: str
15
- r"""Name of the taxonomy node (must be lowercase without spaces)"""
16
- embedding_configs: List[EmbeddingConfigTypedDict]
17
- r"""List of embedding configurations defining how this node should be vectorized"""
18
- node_id: NotRequired[str]
19
- r"""Unique identifier for the taxonomy node"""
20
- parent_node_id: NotRequired[Nullable[str]]
21
- r"""ID of the parent node (None if root node)"""
22
- node_description: NotRequired[Nullable[str]]
23
- r"""Optional description of what this node represents"""
24
- children: NotRequired[Nullable[List[TaxonomyNodeTypedDict]]]
25
- r"""List of child nodes under this node"""
26
- path_tokens: NotRequired[List[str]]
27
- r"""List of node names representing the path from root to this node"""
28
- order: NotRequired[List[int]]
29
- r"""Order of the node in the taxonomy"""
30
- depth: NotRequired[int]
31
- r"""Depth of the node in the taxonomy"""
32
-
33
-
34
- class TaxonomyNode(BaseModel):
35
- taxonomy_id: str
36
- r"""ID of the taxonomy this node belongs to"""
37
-
38
- node_name: str
39
- r"""Name of the taxonomy node (must be lowercase without spaces)"""
40
-
41
- embedding_configs: List[EmbeddingConfig]
42
- r"""List of embedding configurations defining how this node should be vectorized"""
43
-
44
- node_id: Optional[str] = None
45
- r"""Unique identifier for the taxonomy node"""
46
-
47
- parent_node_id: OptionalNullable[str] = UNSET
48
- r"""ID of the parent node (None if root node)"""
49
-
50
- node_description: OptionalNullable[str] = UNSET
51
- r"""Optional description of what this node represents"""
52
-
53
- children: OptionalNullable[List[TaxonomyNode]] = UNSET
54
- r"""List of child nodes under this node"""
55
-
56
- path_tokens: Optional[List[str]] = None
57
- r"""List of node names representing the path from root to this node"""
58
-
59
- order: Optional[List[int]] = None
60
- r"""Order of the node in the taxonomy"""
61
-
62
- depth: Optional[int] = 0
63
- r"""Depth of the node in the taxonomy"""
64
-
65
- @model_serializer(mode="wrap")
66
- def serialize_model(self, handler):
67
- optional_fields = [
68
- "node_id",
69
- "parent_node_id",
70
- "node_description",
71
- "children",
72
- "path_tokens",
73
- "order",
74
- "depth",
75
- ]
76
- nullable_fields = ["parent_node_id", "node_description", "children"]
77
- null_default_fields = []
78
-
79
- serialized = handler(self)
80
-
81
- m = {}
82
-
83
- for n, f in self.model_fields.items():
84
- k = f.alias or n
85
- val = serialized.get(k)
86
- serialized.pop(k, None)
87
-
88
- optional_nullable = k in optional_fields and k in nullable_fields
89
- is_set = (
90
- self.__pydantic_fields_set__.intersection({n})
91
- or k in null_default_fields
92
- ) # pylint: disable=no-member
93
-
94
- if val is not None and val != UNSET_SENTINEL:
95
- m[k] = val
96
- elif val != UNSET_SENTINEL and (
97
- not k in optional_fields or (optional_nullable and is_set)
98
- ):
99
- m[k] = val
100
-
101
- return m
@@ -1,63 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .embeddingconfig import EmbeddingConfig, EmbeddingConfigTypedDict
5
- from mixpeek.types import BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL
6
- from pydantic import model_serializer
7
- from typing import List
8
- from typing_extensions import NotRequired, TypedDict
9
-
10
-
11
- class TaxonomyNodeCreateTypedDict(TypedDict):
12
- node_name: str
13
- r"""Name of the taxonomy node (must be lowercase without spaces)"""
14
- embedding_configs: List[EmbeddingConfigTypedDict]
15
- r"""List of embedding configurations defining how this node should be vectorized"""
16
- node_description: NotRequired[Nullable[str]]
17
- r"""Optional description of what this node represents"""
18
- children: NotRequired[Nullable[List[TaxonomyNodeCreateTypedDict]]]
19
- r"""List of child nodes under this node"""
20
-
21
-
22
- class TaxonomyNodeCreate(BaseModel):
23
- node_name: str
24
- r"""Name of the taxonomy node (must be lowercase without spaces)"""
25
-
26
- embedding_configs: List[EmbeddingConfig]
27
- r"""List of embedding configurations defining how this node should be vectorized"""
28
-
29
- node_description: OptionalNullable[str] = UNSET
30
- r"""Optional description of what this node represents"""
31
-
32
- children: OptionalNullable[List[TaxonomyNodeCreate]] = UNSET
33
- r"""List of child nodes under this node"""
34
-
35
- @model_serializer(mode="wrap")
36
- def serialize_model(self, handler):
37
- optional_fields = ["node_description", "children"]
38
- nullable_fields = ["node_description", "children"]
39
- null_default_fields = []
40
-
41
- serialized = handler(self)
42
-
43
- m = {}
44
-
45
- for n, f in self.model_fields.items():
46
- k = f.alias or n
47
- val = serialized.get(k)
48
- serialized.pop(k, None)
49
-
50
- optional_nullable = k in optional_fields and k in nullable_fields
51
- is_set = (
52
- self.__pydantic_fields_set__.intersection({n})
53
- or k in null_default_fields
54
- ) # pylint: disable=no-member
55
-
56
- if val is not None and val != UNSET_SENTINEL:
57
- m[k] = val
58
- elif val != UNSET_SENTINEL and (
59
- not k in optional_fields or (optional_nullable and is_set)
60
- ):
61
- m[k] = val
62
-
63
- return m
@@ -1,67 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from __future__ import annotations
4
- from .embeddingrequest import EmbeddingRequest, EmbeddingRequestTypedDict
5
- from .entitysettings import EntitySettings, EntitySettingsTypedDict
6
- from .jsontextoutputsettings import (
7
- JSONTextOutputSettings,
8
- JSONTextOutputSettingsTypedDict,
9
- )
10
- from mixpeek.types import BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL
11
- from pydantic import model_serializer
12
- from typing import List, Optional
13
- from typing_extensions import NotRequired, TypedDict
14
-
15
-
16
- class TextSettingsTypedDict(TypedDict):
17
- embed: NotRequired[List[EmbeddingRequestTypedDict]]
18
- r"""List of embedding settings for generating multiple embeddings. field_name's provided are how the raw text will be inserted, if not provided, the field_name will be auto-generated.
19
- Default: [{type: 'text', embedding_model: 'multimodal'}] if none provided.
20
- """
21
- json_output: NotRequired[Nullable[JSONTextOutputSettingsTypedDict]]
22
- r"""Settings for structured JSON output of text analysis."""
23
- entities: NotRequired[Nullable[EntitySettingsTypedDict]]
24
- r"""Settings for extracting entities from text content"""
25
-
26
-
27
- class TextSettings(BaseModel):
28
- embed: Optional[List[EmbeddingRequest]] = None
29
- r"""List of embedding settings for generating multiple embeddings. field_name's provided are how the raw text will be inserted, if not provided, the field_name will be auto-generated.
30
- Default: [{type: 'text', embedding_model: 'multimodal'}] if none provided.
31
- """
32
-
33
- json_output: OptionalNullable[JSONTextOutputSettings] = UNSET
34
- r"""Settings for structured JSON output of text analysis."""
35
-
36
- entities: OptionalNullable[EntitySettings] = UNSET
37
- r"""Settings for extracting entities from text content"""
38
-
39
- @model_serializer(mode="wrap")
40
- def serialize_model(self, handler):
41
- optional_fields = ["embed", "json_output", "entities"]
42
- nullable_fields = ["json_output", "entities"]
43
- null_default_fields = []
44
-
45
- serialized = handler(self)
46
-
47
- m = {}
48
-
49
- for n, f in self.model_fields.items():
50
- k = f.alias or n
51
- val = serialized.get(k)
52
- serialized.pop(k, None)
53
-
54
- optional_nullable = k in optional_fields and k in nullable_fields
55
- is_set = (
56
- self.__pydantic_fields_set__.intersection({n})
57
- or k in null_default_fields
58
- ) # pylint: disable=no-member
59
-
60
- if val is not None and val != UNSET_SENTINEL:
61
- m[k] = val
62
- elif val != UNSET_SENTINEL and (
63
- not k in optional_fields or (optional_nullable and is_set)
64
- ):
65
- m[k] = val
66
-
67
- return m