mixpeek 0.1.2__py3-none-any.whl → 0.3__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 (180) hide show
  1. mixpeek/__init__.py +70 -6
  2. mixpeek-0.3.dist-info/LICENSE.rst +20 -0
  3. mixpeek-0.3.dist-info/METADATA +12 -0
  4. mixpeek-0.3.dist-info/RECORD +6 -0
  5. {mixpeek-0.1.2.dist-info → mixpeek-0.3.dist-info}/WHEEL +2 -1
  6. mixpeek-0.3.dist-info/top_level.txt +1 -0
  7. mixpeek/_hooks/__init__.py +0 -5
  8. mixpeek/_hooks/registration.py +0 -13
  9. mixpeek/_hooks/sdkhooks.py +0 -76
  10. mixpeek/_hooks/types.py +0 -94
  11. mixpeek/_version.py +0 -12
  12. mixpeek/assets.py +0 -1561
  13. mixpeek/basesdk.py +0 -350
  14. mixpeek/collections.py +0 -1029
  15. mixpeek/featureextractors.py +0 -205
  16. mixpeek/features.py +0 -1181
  17. mixpeek/health.py +0 -167
  18. mixpeek/httpclient.py +0 -84
  19. mixpeek/ingest.py +0 -831
  20. mixpeek/interactions.py +0 -221
  21. mixpeek/models/__init__.py +0 -751
  22. mixpeek/models/actionusage.py +0 -16
  23. mixpeek/models/apierror.py +0 -22
  24. mixpeek/models/apikey.py +0 -25
  25. mixpeek/models/apikeyupdate.py +0 -49
  26. mixpeek/models/assetfeatures.py +0 -55
  27. mixpeek/models/assetresponse.py +0 -166
  28. mixpeek/models/assets_model_searchquery.py +0 -21
  29. mixpeek/models/assetupdate.py +0 -28
  30. mixpeek/models/availableindexesresponse.py +0 -23
  31. mixpeek/models/availablemodels.py +0 -12
  32. mixpeek/models/boolindexparams.py +0 -18
  33. mixpeek/models/collectionmodel.py +0 -70
  34. mixpeek/models/collectionresult.py +0 -73
  35. mixpeek/models/create_api_key_organizations_users_user_email_api_keys_postop.py +0 -23
  36. mixpeek/models/create_collection_collections_postop.py +0 -62
  37. mixpeek/models/create_interaction_features_search_interactions_postop.py +0 -59
  38. mixpeek/models/createcollectionrequest.py +0 -59
  39. mixpeek/models/createnamespacerequest.py +0 -62
  40. mixpeek/models/datetimeindexparams.py +0 -18
  41. mixpeek/models/dateusage.py +0 -22
  42. mixpeek/models/db_model_paginationresponse.py +0 -59
  43. mixpeek/models/db_model_taskresponse.py +0 -20
  44. mixpeek/models/delete_api_key_organizations_users_user_email_api_keys_key_name_deleteop.py +0 -23
  45. mixpeek/models/delete_asset_assets_asset_id_deleteop.py +0 -57
  46. mixpeek/models/delete_collection_collections_collection_deleteop.py +0 -59
  47. mixpeek/models/delete_feature_features_feature_id_deleteop.py +0 -57
  48. mixpeek/models/delete_interaction_features_search_interactions_interaction_id_deleteop.py +0 -59
  49. mixpeek/models/delete_namespace_namespaces_namespace_deleteop.py +0 -18
  50. mixpeek/models/delete_user_organizations_users_user_email_deleteop.py +0 -16
  51. mixpeek/models/denseembedding.py +0 -16
  52. mixpeek/models/embeddingrequest.py +0 -59
  53. mixpeek/models/embeddingresponse.py +0 -64
  54. mixpeek/models/errormessage.py +0 -13
  55. mixpeek/models/errorresponse.py +0 -21
  56. mixpeek/models/facedetectsettings.py +0 -52
  57. mixpeek/models/featureextractionembeddingrequest.py +0 -54
  58. mixpeek/models/featureresponse.py +0 -74
  59. mixpeek/models/features_model_paginationresponse.py +0 -59
  60. mixpeek/models/featureupdaterequest.py +0 -21
  61. mixpeek/models/filtercondition.py +0 -74
  62. mixpeek/models/floatindexparams.py +0 -18
  63. mixpeek/models/full_asset_update_assets_asset_id_putop.py +0 -69
  64. mixpeek/models/full_feature_update_features_feature_id_putop.py +0 -69
  65. mixpeek/models/geoindexparams.py +0 -18
  66. mixpeek/models/get_asset_assets_asset_id_getop.py +0 -73
  67. mixpeek/models/get_asset_with_features_assets_asset_id_features_getop.py +0 -73
  68. mixpeek/models/get_collection_collections_collection_getop.py +0 -59
  69. mixpeek/models/get_feature_features_feature_id_getop.py +0 -70
  70. mixpeek/models/get_interaction_features_search_interactions_interaction_id_getop.py +0 -59
  71. mixpeek/models/get_namespace_namespaces_namespace_getop.py +0 -18
  72. mixpeek/models/get_task_tasks_task_id_getop.py +0 -57
  73. mixpeek/models/get_user_organizations_users_user_email_getop.py +0 -16
  74. mixpeek/models/groupbyoptions.py +0 -71
  75. mixpeek/models/groupbyoptionsasset.py +0 -71
  76. mixpeek/models/groupedassetdata.py +0 -18
  77. mixpeek/models/healthcheckresponse.py +0 -13
  78. mixpeek/models/httpvalidationerror.py +0 -21
  79. mixpeek/models/imagedescribesettings.py +0 -82
  80. mixpeek/models/imagedetectsettings.py +0 -53
  81. mixpeek/models/imagereadsettings.py +0 -71
  82. mixpeek/models/imagesettings.py +0 -79
  83. mixpeek/models/ingest_image_url_ingest_images_url_postop.py +0 -59
  84. mixpeek/models/ingest_text_ingest_text_postop.py +0 -59
  85. mixpeek/models/ingest_video_url_ingest_videos_url_postop.py +0 -59
  86. mixpeek/models/inputtype.py +0 -11
  87. mixpeek/models/integerindexparams.py +0 -24
  88. mixpeek/models/interactionresponse.py +0 -87
  89. mixpeek/models/interactiontype.py +0 -11
  90. mixpeek/models/jsonimageoutputsettings.py +0 -55
  91. mixpeek/models/jsontextoutputsettings.py +0 -55
  92. mixpeek/models/jsonvideooutputsettings.py +0 -55
  93. mixpeek/models/keywordindexparams.py +0 -21
  94. mixpeek/models/kill_task_tasks_task_id_deleteop.py +0 -57
  95. mixpeek/models/list_assets_assets_postop.py +0 -77
  96. mixpeek/models/list_collections_collections_getop.py +0 -65
  97. mixpeek/models/list_features_features_postop.py +0 -79
  98. mixpeek/models/list_interactions_features_search_interactions_getop.py +0 -96
  99. mixpeek/models/listassetsrequest.py +0 -75
  100. mixpeek/models/listassetsresponse.py +0 -22
  101. mixpeek/models/listcollectionsresponse.py +0 -22
  102. mixpeek/models/listfeaturesrequest.py +0 -77
  103. mixpeek/models/listfeaturesresponse.py +0 -22
  104. mixpeek/models/logicaloperator_input.py +0 -88
  105. mixpeek/models/logicaloperator_output.py +0 -103
  106. mixpeek/models/logodetectsettings.py +0 -52
  107. mixpeek/models/modality.py +0 -13
  108. mixpeek/models/modeldetails.py +0 -57
  109. mixpeek/models/namespaceresponse.py +0 -54
  110. mixpeek/models/organizationmodel.py +0 -45
  111. mixpeek/models/partial_asset_update_assets_asset_id_patchop.py +0 -69
  112. mixpeek/models/payloadindexconfig.py +0 -94
  113. mixpeek/models/payloadindextype.py +0 -17
  114. mixpeek/models/payloadschematype.py +0 -15
  115. mixpeek/models/percolaterequest.py +0 -57
  116. mixpeek/models/permission.py +0 -10
  117. mixpeek/models/processimageurlinput.py +0 -99
  118. mixpeek/models/processtextinput.py +0 -94
  119. mixpeek/models/processvideourlinput.py +0 -99
  120. mixpeek/models/querysettings.py +0 -56
  121. mixpeek/models/rerankingoptions.py +0 -47
  122. mixpeek/models/search_assets_assets_search_postop.py +0 -59
  123. mixpeek/models/search_features_features_search_postop.py +0 -96
  124. mixpeek/models/search_model_searchquery_input.py +0 -76
  125. mixpeek/models/searchassetsrequest.py +0 -78
  126. mixpeek/models/searchinteraction.py +0 -82
  127. mixpeek/models/searchquery_output.py +0 -79
  128. mixpeek/models/searchrequestfeatures_input.py +0 -151
  129. mixpeek/models/searchrequestfeatures_output.py +0 -151
  130. mixpeek/models/sortoption.py +0 -28
  131. mixpeek/models/sparseembedding.py +0 -21
  132. mixpeek/models/tasks_model_taskresponse.py +0 -24
  133. mixpeek/models/taskstatus.py +0 -16
  134. mixpeek/models/textindexparams.py +0 -31
  135. mixpeek/models/textsettings.py +0 -61
  136. mixpeek/models/tokenizertype.py +0 -11
  137. mixpeek/models/update_api_key_organizations_users_user_email_api_keys_key_name_patchop.py +0 -30
  138. mixpeek/models/update_collection_collections_collection_putop.py +0 -74
  139. mixpeek/models/update_namespace_namespaces_namespace_putop.py +0 -28
  140. mixpeek/models/updateassetrequest.py +0 -60
  141. mixpeek/models/updatenamespacerequest.py +0 -26
  142. mixpeek/models/usage.py +0 -18
  143. mixpeek/models/usermodel_input.py +0 -36
  144. mixpeek/models/usermodel_output.py +0 -36
  145. mixpeek/models/uuidindexparams.py +0 -21
  146. mixpeek/models/validationerror.py +0 -26
  147. mixpeek/models/vectormodel.py +0 -11
  148. mixpeek/models/vectortype.py +0 -9
  149. mixpeek/models/videodescribesettings.py +0 -82
  150. mixpeek/models/videodetectsettings.py +0 -53
  151. mixpeek/models/videoreadsettings.py +0 -71
  152. mixpeek/models/videosettings.py +0 -101
  153. mixpeek/models/videotranscriptionsettings.py +0 -69
  154. mixpeek/namespaces.py +0 -1143
  155. mixpeek/organizations.py +0 -1508
  156. mixpeek/py.typed +0 -1
  157. mixpeek/sdk.py +0 -135
  158. mixpeek/sdkconfiguration.py +0 -45
  159. mixpeek/searchinteractions.py +0 -647
  160. mixpeek/tasks.py +0 -387
  161. mixpeek/types/__init__.py +0 -21
  162. mixpeek/types/basemodel.py +0 -39
  163. mixpeek/utils/__init__.py +0 -97
  164. mixpeek/utils/annotations.py +0 -55
  165. mixpeek/utils/enums.py +0 -34
  166. mixpeek/utils/eventstreaming.py +0 -238
  167. mixpeek/utils/forms.py +0 -202
  168. mixpeek/utils/headers.py +0 -136
  169. mixpeek/utils/logger.py +0 -27
  170. mixpeek/utils/metadata.py +0 -118
  171. mixpeek/utils/queryparams.py +0 -205
  172. mixpeek/utils/requestbodies.py +0 -66
  173. mixpeek/utils/retries.py +0 -217
  174. mixpeek/utils/security.py +0 -174
  175. mixpeek/utils/serializers.py +0 -215
  176. mixpeek/utils/url.py +0 -155
  177. mixpeek/utils/values.py +0 -134
  178. mixpeek-0.1.2.dist-info/METADATA +0 -439
  179. mixpeek-0.1.2.dist-info/RECORD +0 -176
  180. py.typed +0 -1
@@ -1,205 +0,0 @@
1
- """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
2
-
3
- from .basesdk import BaseSDK
4
- from mixpeek import models, utils
5
- from mixpeek._hooks import HookContext
6
- from mixpeek.types import OptionalNullable, UNSET
7
- from typing import Any, Mapping, Optional
8
-
9
-
10
- class FeatureExtractors(BaseSDK):
11
- def extract_embeddings(
12
- self,
13
- *,
14
- type_: models.InputType,
15
- vector_index: models.VectorModel,
16
- value: OptionalNullable[str] = UNSET,
17
- retries: OptionalNullable[utils.RetryConfig] = UNSET,
18
- server_url: Optional[str] = None,
19
- timeout_ms: Optional[int] = None,
20
- http_headers: Optional[Mapping[str, str]] = None,
21
- ) -> models.EmbeddingResponse:
22
- r"""Extract Embeddings
23
-
24
- :param type:
25
- :param vector_index:
26
- :param value: The input content to embed. Could be a URL, text content, file path, or base64 encoded string
27
- :param retries: Override the default retry configuration for this method
28
- :param server_url: Override the default server URL for this method
29
- :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
30
- :param http_headers: Additional headers to set or replace on requests.
31
- """
32
- base_url = None
33
- url_variables = None
34
- if timeout_ms is None:
35
- timeout_ms = self.sdk_configuration.timeout_ms
36
-
37
- if server_url is not None:
38
- base_url = server_url
39
-
40
- request = models.FeatureExtractionEmbeddingRequest(
41
- type=type_,
42
- value=value,
43
- vector_index=vector_index,
44
- )
45
-
46
- req = self.build_request(
47
- method="POST",
48
- path="/features/extractors/embed",
49
- base_url=base_url,
50
- url_variables=url_variables,
51
- request=request,
52
- request_body_required=True,
53
- request_has_path_params=False,
54
- request_has_query_params=False,
55
- user_agent_header="user-agent",
56
- accept_header_value="application/json",
57
- http_headers=http_headers,
58
- get_serialized_body=lambda: utils.serialize_request_body(
59
- request, False, False, "json", models.FeatureExtractionEmbeddingRequest
60
- ),
61
- timeout_ms=timeout_ms,
62
- )
63
-
64
- if retries == UNSET:
65
- if self.sdk_configuration.retry_config is not UNSET:
66
- retries = self.sdk_configuration.retry_config
67
-
68
- retry_config = None
69
- if isinstance(retries, utils.RetryConfig):
70
- retry_config = (retries, ["429", "500", "502", "503", "504"])
71
-
72
- http_res = self.do_request(
73
- hook_ctx=HookContext(
74
- operation_id="extract_embeddings_features_extractors_embed_post",
75
- oauth2_scopes=[],
76
- security_source=None,
77
- ),
78
- request=req,
79
- error_status_codes=["400", "401", "403", "404", "422", "4XX", "500", "5XX"],
80
- retry_config=retry_config,
81
- )
82
-
83
- data: Any = None
84
- if utils.match_response(http_res, "200", "application/json"):
85
- return utils.unmarshal_json(http_res.text, models.EmbeddingResponse)
86
- if utils.match_response(
87
- http_res, ["400", "401", "403", "404", "500"], "application/json"
88
- ):
89
- data = utils.unmarshal_json(http_res.text, models.ErrorResponseData)
90
- raise models.ErrorResponse(data=data)
91
- if utils.match_response(http_res, "422", "application/json"):
92
- data = utils.unmarshal_json(http_res.text, models.HTTPValidationErrorData)
93
- raise models.HTTPValidationError(data=data)
94
- if utils.match_response(http_res, ["4XX", "5XX"], "*"):
95
- http_res_text = utils.stream_to_text(http_res)
96
- raise models.APIError(
97
- "API error occurred", http_res.status_code, http_res_text, http_res
98
- )
99
-
100
- content_type = http_res.headers.get("Content-Type")
101
- http_res_text = utils.stream_to_text(http_res)
102
- raise models.APIError(
103
- f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
104
- http_res.status_code,
105
- http_res_text,
106
- http_res,
107
- )
108
-
109
- async def extract_embeddings_async(
110
- self,
111
- *,
112
- type_: models.InputType,
113
- vector_index: models.VectorModel,
114
- value: OptionalNullable[str] = UNSET,
115
- retries: OptionalNullable[utils.RetryConfig] = UNSET,
116
- server_url: Optional[str] = None,
117
- timeout_ms: Optional[int] = None,
118
- http_headers: Optional[Mapping[str, str]] = None,
119
- ) -> models.EmbeddingResponse:
120
- r"""Extract Embeddings
121
-
122
- :param type:
123
- :param vector_index:
124
- :param value: The input content to embed. Could be a URL, text content, file path, or base64 encoded string
125
- :param retries: Override the default retry configuration for this method
126
- :param server_url: Override the default server URL for this method
127
- :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
128
- :param http_headers: Additional headers to set or replace on requests.
129
- """
130
- base_url = None
131
- url_variables = None
132
- if timeout_ms is None:
133
- timeout_ms = self.sdk_configuration.timeout_ms
134
-
135
- if server_url is not None:
136
- base_url = server_url
137
-
138
- request = models.FeatureExtractionEmbeddingRequest(
139
- type=type_,
140
- value=value,
141
- vector_index=vector_index,
142
- )
143
-
144
- req = self.build_request_async(
145
- method="POST",
146
- path="/features/extractors/embed",
147
- base_url=base_url,
148
- url_variables=url_variables,
149
- request=request,
150
- request_body_required=True,
151
- request_has_path_params=False,
152
- request_has_query_params=False,
153
- user_agent_header="user-agent",
154
- accept_header_value="application/json",
155
- http_headers=http_headers,
156
- get_serialized_body=lambda: utils.serialize_request_body(
157
- request, False, False, "json", models.FeatureExtractionEmbeddingRequest
158
- ),
159
- timeout_ms=timeout_ms,
160
- )
161
-
162
- if retries == UNSET:
163
- if self.sdk_configuration.retry_config is not UNSET:
164
- retries = self.sdk_configuration.retry_config
165
-
166
- retry_config = None
167
- if isinstance(retries, utils.RetryConfig):
168
- retry_config = (retries, ["429", "500", "502", "503", "504"])
169
-
170
- http_res = await self.do_request_async(
171
- hook_ctx=HookContext(
172
- operation_id="extract_embeddings_features_extractors_embed_post",
173
- oauth2_scopes=[],
174
- security_source=None,
175
- ),
176
- request=req,
177
- error_status_codes=["400", "401", "403", "404", "422", "4XX", "500", "5XX"],
178
- retry_config=retry_config,
179
- )
180
-
181
- data: Any = None
182
- if utils.match_response(http_res, "200", "application/json"):
183
- return utils.unmarshal_json(http_res.text, models.EmbeddingResponse)
184
- if utils.match_response(
185
- http_res, ["400", "401", "403", "404", "500"], "application/json"
186
- ):
187
- data = utils.unmarshal_json(http_res.text, models.ErrorResponseData)
188
- raise models.ErrorResponse(data=data)
189
- if utils.match_response(http_res, "422", "application/json"):
190
- data = utils.unmarshal_json(http_res.text, models.HTTPValidationErrorData)
191
- raise models.HTTPValidationError(data=data)
192
- if utils.match_response(http_res, ["4XX", "5XX"], "*"):
193
- http_res_text = await utils.stream_to_text_async(http_res)
194
- raise models.APIError(
195
- "API error occurred", http_res.status_code, http_res_text, http_res
196
- )
197
-
198
- content_type = http_res.headers.get("Content-Type")
199
- http_res_text = await utils.stream_to_text_async(http_res)
200
- raise models.APIError(
201
- f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
202
- http_res.status_code,
203
- http_res_text,
204
- http_res,
205
- )