orq-ai-sdk 4.2.0rc28__py3-none-any.whl → 4.3.0rc7__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.
- orq_ai_sdk/_version.py +3 -3
- orq_ai_sdk/agents.py +186 -186
- orq_ai_sdk/audio.py +30 -0
- orq_ai_sdk/basesdk.py +20 -6
- orq_ai_sdk/chat.py +22 -0
- orq_ai_sdk/completions.py +438 -0
- orq_ai_sdk/contacts.py +43 -855
- orq_ai_sdk/deployments.py +61 -0
- orq_ai_sdk/edits.py +364 -0
- orq_ai_sdk/embeddings.py +344 -0
- orq_ai_sdk/generations.py +370 -0
- orq_ai_sdk/identities.py +1037 -0
- orq_ai_sdk/images.py +28 -0
- orq_ai_sdk/models/__init__.py +5746 -737
- orq_ai_sdk/models/actionreviewedstreamingevent.py +18 -1
- orq_ai_sdk/models/actionreviewrequestedstreamingevent.py +44 -1
- orq_ai_sdk/models/agenterroredstreamingevent.py +18 -1
- orq_ai_sdk/models/agentinactivestreamingevent.py +168 -70
- orq_ai_sdk/models/agentmessagecreatedstreamingevent.py +18 -2
- orq_ai_sdk/models/agentresponsemessage.py +18 -2
- orq_ai_sdk/models/agentstartedstreamingevent.py +127 -2
- orq_ai_sdk/models/agentthoughtstreamingevent.py +178 -211
- orq_ai_sdk/models/conversationresponse.py +31 -20
- orq_ai_sdk/models/conversationwithmessagesresponse.py +31 -20
- orq_ai_sdk/models/createagentrequestop.py +1945 -383
- orq_ai_sdk/models/createagentresponse.py +147 -91
- orq_ai_sdk/models/createagentresponserequestop.py +111 -2
- orq_ai_sdk/models/createchatcompletionop.py +1381 -861
- orq_ai_sdk/models/createchunkop.py +46 -19
- orq_ai_sdk/models/createcompletionop.py +2078 -0
- orq_ai_sdk/models/createcontactop.py +45 -56
- orq_ai_sdk/models/createconversationop.py +61 -39
- orq_ai_sdk/models/createconversationresponseop.py +68 -4
- orq_ai_sdk/models/createdatasetitemop.py +424 -80
- orq_ai_sdk/models/createdatasetop.py +19 -2
- orq_ai_sdk/models/createdatasourceop.py +92 -26
- orq_ai_sdk/models/createembeddingop.py +579 -0
- orq_ai_sdk/models/createevalop.py +552 -24
- orq_ai_sdk/models/createidentityop.py +176 -0
- orq_ai_sdk/models/createimageeditop.py +715 -0
- orq_ai_sdk/models/createimageop.py +407 -128
- orq_ai_sdk/models/createimagevariationop.py +706 -0
- orq_ai_sdk/models/createknowledgeop.py +186 -121
- orq_ai_sdk/models/creatememorydocumentop.py +50 -1
- orq_ai_sdk/models/creatememoryop.py +34 -21
- orq_ai_sdk/models/creatememorystoreop.py +34 -1
- orq_ai_sdk/models/createmoderationop.py +521 -0
- orq_ai_sdk/models/createpromptop.py +2759 -1251
- orq_ai_sdk/models/creatererankop.py +608 -0
- orq_ai_sdk/models/createresponseop.py +2567 -0
- orq_ai_sdk/models/createspeechop.py +466 -0
- orq_ai_sdk/models/createtoolop.py +537 -12
- orq_ai_sdk/models/createtranscriptionop.py +732 -0
- orq_ai_sdk/models/createtranslationop.py +702 -0
- orq_ai_sdk/models/datapart.py +18 -1
- orq_ai_sdk/models/deletechunksop.py +34 -1
- orq_ai_sdk/models/{deletecontactop.py → deleteidentityop.py} +9 -9
- orq_ai_sdk/models/deletepromptop.py +26 -0
- orq_ai_sdk/models/deploymentcreatemetricop.py +362 -76
- orq_ai_sdk/models/deploymentgetconfigop.py +635 -194
- orq_ai_sdk/models/deploymentinvokeop.py +168 -173
- orq_ai_sdk/models/deploymentsop.py +195 -58
- orq_ai_sdk/models/deploymentstreamop.py +652 -304
- orq_ai_sdk/models/errorpart.py +18 -1
- orq_ai_sdk/models/filecontentpartschema.py +18 -1
- orq_ai_sdk/models/filegetop.py +19 -2
- orq_ai_sdk/models/filelistop.py +35 -2
- orq_ai_sdk/models/filepart.py +50 -1
- orq_ai_sdk/models/fileuploadop.py +51 -2
- orq_ai_sdk/models/generateconversationnameop.py +31 -20
- orq_ai_sdk/models/get_v2_evaluators_id_versionsop.py +34 -1
- orq_ai_sdk/models/get_v2_tools_tool_id_versions_version_id_op.py +18 -1
- orq_ai_sdk/models/get_v2_tools_tool_id_versionsop.py +34 -1
- orq_ai_sdk/models/getallmemoriesop.py +34 -21
- orq_ai_sdk/models/getallmemorydocumentsop.py +42 -1
- orq_ai_sdk/models/getallmemorystoresop.py +34 -1
- orq_ai_sdk/models/getallpromptsop.py +1696 -230
- orq_ai_sdk/models/getalltoolsop.py +325 -8
- orq_ai_sdk/models/getchunkscountop.py +34 -1
- orq_ai_sdk/models/getevalsop.py +395 -43
- orq_ai_sdk/models/getonechunkop.py +14 -19
- orq_ai_sdk/models/getoneknowledgeop.py +116 -96
- orq_ai_sdk/models/getonepromptop.py +1679 -230
- orq_ai_sdk/models/getpromptversionop.py +1676 -216
- orq_ai_sdk/models/imagecontentpartschema.py +50 -1
- orq_ai_sdk/models/internal/globals.py +18 -1
- orq_ai_sdk/models/invokeagentop.py +140 -2
- orq_ai_sdk/models/invokedeploymentrequest.py +418 -80
- orq_ai_sdk/models/invokeevalop.py +160 -131
- orq_ai_sdk/models/listagentsop.py +805 -166
- orq_ai_sdk/models/listchunksop.py +32 -19
- orq_ai_sdk/models/listchunkspaginatedop.py +46 -19
- orq_ai_sdk/models/listconversationsop.py +18 -1
- orq_ai_sdk/models/listdatasetdatapointsop.py +252 -42
- orq_ai_sdk/models/listdatasetsop.py +35 -2
- orq_ai_sdk/models/listdatasourcesop.py +35 -26
- orq_ai_sdk/models/{listcontactsop.py → listidentitiesop.py} +89 -79
- orq_ai_sdk/models/listknowledgebasesop.py +132 -96
- orq_ai_sdk/models/listmodelsop.py +1 -0
- orq_ai_sdk/models/listpromptversionsop.py +1690 -216
- orq_ai_sdk/models/parseop.py +161 -17
- orq_ai_sdk/models/partdoneevent.py +19 -2
- orq_ai_sdk/models/post_v2_router_ocrop.py +408 -0
- orq_ai_sdk/models/publiccontact.py +27 -4
- orq_ai_sdk/models/publicidentity.py +62 -0
- orq_ai_sdk/models/reasoningpart.py +19 -2
- orq_ai_sdk/models/refusalpartschema.py +18 -1
- orq_ai_sdk/models/remoteconfigsgetconfigop.py +34 -1
- orq_ai_sdk/models/responsedoneevent.py +114 -84
- orq_ai_sdk/models/responsestartedevent.py +18 -1
- orq_ai_sdk/models/retrieveagentrequestop.py +799 -166
- orq_ai_sdk/models/retrievedatapointop.py +236 -42
- orq_ai_sdk/models/retrievedatasetop.py +19 -2
- orq_ai_sdk/models/retrievedatasourceop.py +17 -26
- orq_ai_sdk/models/{retrievecontactop.py → retrieveidentityop.py} +38 -41
- orq_ai_sdk/models/retrievememorydocumentop.py +18 -1
- orq_ai_sdk/models/retrievememoryop.py +18 -21
- orq_ai_sdk/models/retrievememorystoreop.py +18 -1
- orq_ai_sdk/models/retrievetoolop.py +309 -8
- orq_ai_sdk/models/runagentop.py +1462 -196
- orq_ai_sdk/models/searchknowledgeop.py +108 -1
- orq_ai_sdk/models/security.py +18 -1
- orq_ai_sdk/models/streamagentop.py +93 -2
- orq_ai_sdk/models/streamrunagentop.py +1439 -194
- orq_ai_sdk/models/textcontentpartschema.py +34 -1
- orq_ai_sdk/models/thinkingconfigenabledschema.py +18 -1
- orq_ai_sdk/models/toolcallpart.py +18 -1
- orq_ai_sdk/models/tooldoneevent.py +18 -1
- orq_ai_sdk/models/toolexecutionfailedstreamingevent.py +50 -1
- orq_ai_sdk/models/toolexecutionfinishedstreamingevent.py +34 -1
- orq_ai_sdk/models/toolexecutionstartedstreamingevent.py +34 -1
- orq_ai_sdk/models/toolresultpart.py +18 -1
- orq_ai_sdk/models/toolreviewrequestedevent.py +18 -1
- orq_ai_sdk/models/toolstartedevent.py +18 -1
- orq_ai_sdk/models/updateagentop.py +1968 -397
- orq_ai_sdk/models/updatechunkop.py +46 -19
- orq_ai_sdk/models/updateconversationop.py +61 -39
- orq_ai_sdk/models/updatedatapointop.py +424 -80
- orq_ai_sdk/models/updatedatasetop.py +51 -2
- orq_ai_sdk/models/updatedatasourceop.py +17 -26
- orq_ai_sdk/models/updateevalop.py +577 -16
- orq_ai_sdk/models/{updatecontactop.py → updateidentityop.py} +78 -68
- orq_ai_sdk/models/updateknowledgeop.py +234 -190
- orq_ai_sdk/models/updatememorydocumentop.py +50 -1
- orq_ai_sdk/models/updatememoryop.py +50 -21
- orq_ai_sdk/models/updatememorystoreop.py +66 -1
- orq_ai_sdk/models/updatepromptop.py +2854 -1448
- orq_ai_sdk/models/updatetoolop.py +592 -9
- orq_ai_sdk/models/usermessagerequest.py +18 -2
- orq_ai_sdk/moderations.py +218 -0
- orq_ai_sdk/orq_completions.py +666 -0
- orq_ai_sdk/orq_responses.py +398 -0
- orq_ai_sdk/prompts.py +28 -36
- orq_ai_sdk/rerank.py +330 -0
- orq_ai_sdk/router.py +89 -641
- orq_ai_sdk/sdk.py +3 -0
- orq_ai_sdk/speech.py +333 -0
- orq_ai_sdk/transcriptions.py +416 -0
- orq_ai_sdk/translations.py +384 -0
- orq_ai_sdk/utils/__init__.py +13 -1
- orq_ai_sdk/variations.py +364 -0
- {orq_ai_sdk-4.2.0rc28.dist-info → orq_ai_sdk-4.3.0rc7.dist-info}/METADATA +169 -148
- orq_ai_sdk-4.3.0rc7.dist-info/RECORD +263 -0
- {orq_ai_sdk-4.2.0rc28.dist-info → orq_ai_sdk-4.3.0rc7.dist-info}/WHEEL +2 -1
- orq_ai_sdk-4.3.0rc7.dist-info/top_level.txt +1 -0
- orq_ai_sdk-4.2.0rc28.dist-info/RECORD +0 -233
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from orq_ai_sdk.types import (
|
|
6
|
+
BaseModel,
|
|
7
|
+
Nullable,
|
|
8
|
+
OptionalNullable,
|
|
9
|
+
UNSET,
|
|
10
|
+
UNSET_SENTINEL,
|
|
11
|
+
)
|
|
12
|
+
from orq_ai_sdk.utils import parse_datetime
|
|
13
|
+
import pydantic
|
|
14
|
+
from pydantic import model_serializer
|
|
15
|
+
from typing import Any, Dict, List, Optional
|
|
16
|
+
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class CreateIdentityRequestBodyTypedDict(TypedDict):
|
|
20
|
+
r"""Identity profile information"""
|
|
21
|
+
|
|
22
|
+
external_id: str
|
|
23
|
+
r"""Unique string value to identify the contact user in the customer's system. This should be the same ID you use in your system to reference this user."""
|
|
24
|
+
display_name: NotRequired[Nullable[str]]
|
|
25
|
+
r"""Display name or nickname of the contact user. This is typically shown in user interfaces."""
|
|
26
|
+
email: NotRequired[Nullable[str]]
|
|
27
|
+
r"""Email address of the contact user"""
|
|
28
|
+
avatar_url: NotRequired[Nullable[str]]
|
|
29
|
+
r"""URL linking to the contact user's avatar image"""
|
|
30
|
+
tags: NotRequired[List[str]]
|
|
31
|
+
r"""Array of tags associated with the contact. Useful for organizing and filtering contacts by categories, departments, or custom classifications."""
|
|
32
|
+
metadata: NotRequired[Dict[str, Any]]
|
|
33
|
+
r"""Additional custom metadata associated with the contact as key-value pairs. Use this to store any extra information specific to your application."""
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
class CreateIdentityRequestBody(BaseModel):
|
|
37
|
+
r"""Identity profile information"""
|
|
38
|
+
|
|
39
|
+
external_id: str
|
|
40
|
+
r"""Unique string value to identify the contact user in the customer's system. This should be the same ID you use in your system to reference this user."""
|
|
41
|
+
|
|
42
|
+
display_name: OptionalNullable[str] = UNSET
|
|
43
|
+
r"""Display name or nickname of the contact user. This is typically shown in user interfaces."""
|
|
44
|
+
|
|
45
|
+
email: OptionalNullable[str] = UNSET
|
|
46
|
+
r"""Email address of the contact user"""
|
|
47
|
+
|
|
48
|
+
avatar_url: OptionalNullable[str] = UNSET
|
|
49
|
+
r"""URL linking to the contact user's avatar image"""
|
|
50
|
+
|
|
51
|
+
tags: Optional[List[str]] = None
|
|
52
|
+
r"""Array of tags associated with the contact. Useful for organizing and filtering contacts by categories, departments, or custom classifications."""
|
|
53
|
+
|
|
54
|
+
metadata: Optional[Dict[str, Any]] = None
|
|
55
|
+
r"""Additional custom metadata associated with the contact as key-value pairs. Use this to store any extra information specific to your application."""
|
|
56
|
+
|
|
57
|
+
@model_serializer(mode="wrap")
|
|
58
|
+
def serialize_model(self, handler):
|
|
59
|
+
optional_fields = set(
|
|
60
|
+
["display_name", "email", "avatar_url", "tags", "metadata"]
|
|
61
|
+
)
|
|
62
|
+
nullable_fields = set(["display_name", "email", "avatar_url"])
|
|
63
|
+
serialized = handler(self)
|
|
64
|
+
m = {}
|
|
65
|
+
|
|
66
|
+
for n, f in type(self).model_fields.items():
|
|
67
|
+
k = f.alias or n
|
|
68
|
+
val = serialized.get(k)
|
|
69
|
+
is_nullable_and_explicitly_set = (
|
|
70
|
+
k in nullable_fields
|
|
71
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
72
|
+
)
|
|
73
|
+
|
|
74
|
+
if val != UNSET_SENTINEL:
|
|
75
|
+
if (
|
|
76
|
+
val is not None
|
|
77
|
+
or k not in optional_fields
|
|
78
|
+
or is_nullable_and_explicitly_set
|
|
79
|
+
):
|
|
80
|
+
m[k] = val
|
|
81
|
+
|
|
82
|
+
return m
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
class CreateIdentityResponseBodyTypedDict(TypedDict):
|
|
86
|
+
r"""Created Identity"""
|
|
87
|
+
|
|
88
|
+
id: str
|
|
89
|
+
r"""Unique ULID (Universally Unique Lexicographically Sortable Identifier) for the contact"""
|
|
90
|
+
external_id: str
|
|
91
|
+
r"""Unique string value to identify the contact user in the customer's system. This should be the same ID you use in your system to reference this user."""
|
|
92
|
+
workspace_id: str
|
|
93
|
+
r"""Unique identifier for the workspace to which the contact belongs"""
|
|
94
|
+
display_name: NotRequired[Nullable[str]]
|
|
95
|
+
r"""Display name or nickname of the contact user. This is typically shown in user interfaces."""
|
|
96
|
+
email: NotRequired[Nullable[str]]
|
|
97
|
+
r"""Email address of the contact user"""
|
|
98
|
+
avatar_url: NotRequired[Nullable[str]]
|
|
99
|
+
r"""URL linking to the contact user's avatar image"""
|
|
100
|
+
tags: NotRequired[List[str]]
|
|
101
|
+
r"""Array of tags associated with the contact. Useful for organizing and filtering contacts by categories, departments, or custom classifications."""
|
|
102
|
+
metadata: NotRequired[Dict[str, Any]]
|
|
103
|
+
r"""Additional custom metadata associated with the contact as key-value pairs. Use this to store any extra information specific to your application."""
|
|
104
|
+
created: NotRequired[datetime]
|
|
105
|
+
r"""The date and time the resource was created"""
|
|
106
|
+
updated: NotRequired[datetime]
|
|
107
|
+
r"""The date and time the resource was last updated"""
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
class CreateIdentityResponseBody(BaseModel):
|
|
111
|
+
r"""Created Identity"""
|
|
112
|
+
|
|
113
|
+
id: Annotated[str, pydantic.Field(alias="_id")]
|
|
114
|
+
r"""Unique ULID (Universally Unique Lexicographically Sortable Identifier) for the contact"""
|
|
115
|
+
|
|
116
|
+
external_id: str
|
|
117
|
+
r"""Unique string value to identify the contact user in the customer's system. This should be the same ID you use in your system to reference this user."""
|
|
118
|
+
|
|
119
|
+
workspace_id: str
|
|
120
|
+
r"""Unique identifier for the workspace to which the contact belongs"""
|
|
121
|
+
|
|
122
|
+
display_name: OptionalNullable[str] = UNSET
|
|
123
|
+
r"""Display name or nickname of the contact user. This is typically shown in user interfaces."""
|
|
124
|
+
|
|
125
|
+
email: OptionalNullable[str] = UNSET
|
|
126
|
+
r"""Email address of the contact user"""
|
|
127
|
+
|
|
128
|
+
avatar_url: OptionalNullable[str] = UNSET
|
|
129
|
+
r"""URL linking to the contact user's avatar image"""
|
|
130
|
+
|
|
131
|
+
tags: Optional[List[str]] = None
|
|
132
|
+
r"""Array of tags associated with the contact. Useful for organizing and filtering contacts by categories, departments, or custom classifications."""
|
|
133
|
+
|
|
134
|
+
metadata: Optional[Dict[str, Any]] = None
|
|
135
|
+
r"""Additional custom metadata associated with the contact as key-value pairs. Use this to store any extra information specific to your application."""
|
|
136
|
+
|
|
137
|
+
created: Optional[datetime] = None
|
|
138
|
+
r"""The date and time the resource was created"""
|
|
139
|
+
|
|
140
|
+
updated: Optional[datetime] = parse_datetime("2026-01-28T17:03:47.548Z")
|
|
141
|
+
r"""The date and time the resource was last updated"""
|
|
142
|
+
|
|
143
|
+
@model_serializer(mode="wrap")
|
|
144
|
+
def serialize_model(self, handler):
|
|
145
|
+
optional_fields = set(
|
|
146
|
+
[
|
|
147
|
+
"display_name",
|
|
148
|
+
"email",
|
|
149
|
+
"avatar_url",
|
|
150
|
+
"tags",
|
|
151
|
+
"metadata",
|
|
152
|
+
"created",
|
|
153
|
+
"updated",
|
|
154
|
+
]
|
|
155
|
+
)
|
|
156
|
+
nullable_fields = set(["display_name", "email", "avatar_url"])
|
|
157
|
+
serialized = handler(self)
|
|
158
|
+
m = {}
|
|
159
|
+
|
|
160
|
+
for n, f in type(self).model_fields.items():
|
|
161
|
+
k = f.alias or n
|
|
162
|
+
val = serialized.get(k)
|
|
163
|
+
is_nullable_and_explicitly_set = (
|
|
164
|
+
k in nullable_fields
|
|
165
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
166
|
+
)
|
|
167
|
+
|
|
168
|
+
if val != UNSET_SENTINEL:
|
|
169
|
+
if (
|
|
170
|
+
val is not None
|
|
171
|
+
or k not in optional_fields
|
|
172
|
+
or is_nullable_and_explicitly_set
|
|
173
|
+
):
|
|
174
|
+
m[k] = val
|
|
175
|
+
|
|
176
|
+
return m
|