orq-ai-sdk 4.2.0rc28__py3-none-any.whl → 4.2.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.
- orq_ai_sdk/_hooks/globalhook.py +0 -1
- orq_ai_sdk/_version.py +3 -3
- 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 +332 -0
- orq_ai_sdk/contacts.py +43 -855
- orq_ai_sdk/deployments.py +61 -0
- orq_ai_sdk/edits.py +258 -0
- orq_ai_sdk/embeddings.py +238 -0
- orq_ai_sdk/generations.py +272 -0
- orq_ai_sdk/identities.py +1037 -0
- orq_ai_sdk/images.py +28 -0
- orq_ai_sdk/models/__init__.py +5341 -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 +1922 -384
- orq_ai_sdk/models/createagentresponse.py +147 -91
- orq_ai_sdk/models/createagentresponserequestop.py +111 -2
- orq_ai_sdk/models/createchatcompletionop.py +1375 -861
- orq_ai_sdk/models/createchunkop.py +46 -19
- orq_ai_sdk/models/createcompletionop.py +1890 -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 +384 -0
- orq_ai_sdk/models/createevalop.py +552 -24
- orq_ai_sdk/models/createidentityop.py +176 -0
- orq_ai_sdk/models/createimageeditop.py +504 -0
- orq_ai_sdk/models/createimageop.py +208 -117
- orq_ai_sdk/models/createimagevariationop.py +486 -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 +2748 -1252
- orq_ai_sdk/models/creatererankop.py +416 -0
- orq_ai_sdk/models/createresponseop.py +2567 -0
- orq_ai_sdk/models/createspeechop.py +316 -0
- orq_ai_sdk/models/createtoolop.py +537 -12
- orq_ai_sdk/models/createtranscriptionop.py +562 -0
- orq_ai_sdk/models/createtranslationop.py +540 -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 +1690 -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 +1673 -230
- orq_ai_sdk/models/getpromptversionop.py +1670 -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 +793 -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 +1684 -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 +787 -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 +1451 -197
- 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 +1428 -195
- 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 +1951 -404
- 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 +2844 -1450
- 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 +660 -0
- orq_ai_sdk/orq_responses.py +398 -0
- orq_ai_sdk/prompts.py +28 -36
- orq_ai_sdk/rerank.py +232 -0
- orq_ai_sdk/router.py +89 -641
- orq_ai_sdk/sdk.py +3 -0
- orq_ai_sdk/speech.py +251 -0
- orq_ai_sdk/transcriptions.py +326 -0
- orq_ai_sdk/translations.py +298 -0
- orq_ai_sdk/utils/__init__.py +13 -1
- orq_ai_sdk/variations.py +254 -0
- orq_ai_sdk-4.2.6.dist-info/METADATA +888 -0
- orq_ai_sdk-4.2.6.dist-info/RECORD +263 -0
- {orq_ai_sdk-4.2.0rc28.dist-info → orq_ai_sdk-4.2.6.dist-info}/WHEEL +2 -1
- orq_ai_sdk-4.2.6.dist-info/top_level.txt +1 -0
- orq_ai_sdk-4.2.0rc28.dist-info/METADATA +0 -867
- orq_ai_sdk-4.2.0rc28.dist-info/RECORD +0 -233
orq_ai_sdk/models/getevalsop.py
CHANGED
|
@@ -4,10 +4,10 @@ from __future__ import annotations
|
|
|
4
4
|
from dataclasses import dataclass, field
|
|
5
5
|
import httpx
|
|
6
6
|
from orq_ai_sdk.models import OrqError
|
|
7
|
-
from orq_ai_sdk.types import BaseModel
|
|
7
|
+
from orq_ai_sdk.types import BaseModel, UNSET_SENTINEL
|
|
8
8
|
from orq_ai_sdk.utils import FieldMetadata, QueryParamMetadata, get_discriminator
|
|
9
9
|
import pydantic
|
|
10
|
-
from pydantic import Discriminator, Tag
|
|
10
|
+
from pydantic import Discriminator, Tag, model_serializer
|
|
11
11
|
from typing import Any, Dict, List, Literal, Optional, Union
|
|
12
12
|
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
13
13
|
|
|
@@ -40,6 +40,22 @@ class GetEvalsRequest(BaseModel):
|
|
|
40
40
|
] = None
|
|
41
41
|
r"""A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 20 objects, starting with `01JJ1HDHN79XAS7A01WB3HYSDB`, your subsequent call can include `before=01JJ1HDHN79XAS7A01WB3HYSDB` in order to fetch the previous page of the list."""
|
|
42
42
|
|
|
43
|
+
@model_serializer(mode="wrap")
|
|
44
|
+
def serialize_model(self, handler):
|
|
45
|
+
optional_fields = set(["limit", "starting_after", "ending_before"])
|
|
46
|
+
serialized = handler(self)
|
|
47
|
+
m = {}
|
|
48
|
+
|
|
49
|
+
for n, f in type(self).model_fields.items():
|
|
50
|
+
k = f.alias or n
|
|
51
|
+
val = serialized.get(k)
|
|
52
|
+
|
|
53
|
+
if val != UNSET_SENTINEL:
|
|
54
|
+
if val is not None or k not in optional_fields:
|
|
55
|
+
m[k] = val
|
|
56
|
+
|
|
57
|
+
return m
|
|
58
|
+
|
|
43
59
|
|
|
44
60
|
class GetEvalsEvalsResponseBodyData(BaseModel):
|
|
45
61
|
message: str
|
|
@@ -63,7 +79,7 @@ class GetEvalsEvalsResponseBody(OrqError):
|
|
|
63
79
|
object.__setattr__(self, "data", data)
|
|
64
80
|
|
|
65
81
|
|
|
66
|
-
|
|
82
|
+
Object = Literal["list",]
|
|
67
83
|
|
|
68
84
|
|
|
69
85
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData72Type = Literal[
|
|
@@ -100,6 +116,22 @@ class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONNumber(BaseModel):
|
|
|
100
116
|
|
|
101
117
|
alert_on_failure: Optional[bool] = False
|
|
102
118
|
|
|
119
|
+
@model_serializer(mode="wrap")
|
|
120
|
+
def serialize_model(self, handler):
|
|
121
|
+
optional_fields = set(["alert_on_failure"])
|
|
122
|
+
serialized = handler(self)
|
|
123
|
+
m = {}
|
|
124
|
+
|
|
125
|
+
for n, f in type(self).model_fields.items():
|
|
126
|
+
k = f.alias or n
|
|
127
|
+
val = serialized.get(k)
|
|
128
|
+
|
|
129
|
+
if val != UNSET_SENTINEL:
|
|
130
|
+
if val is not None or k not in optional_fields:
|
|
131
|
+
m[k] = val
|
|
132
|
+
|
|
133
|
+
return m
|
|
134
|
+
|
|
103
135
|
|
|
104
136
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData7Type = Literal[
|
|
105
137
|
"boolean",
|
|
@@ -122,6 +154,22 @@ class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONBoolean(BaseModel):
|
|
|
122
154
|
|
|
123
155
|
alert_on_failure: Optional[bool] = False
|
|
124
156
|
|
|
157
|
+
@model_serializer(mode="wrap")
|
|
158
|
+
def serialize_model(self, handler):
|
|
159
|
+
optional_fields = set(["alert_on_failure"])
|
|
160
|
+
serialized = handler(self)
|
|
161
|
+
m = {}
|
|
162
|
+
|
|
163
|
+
for n, f in type(self).model_fields.items():
|
|
164
|
+
k = f.alias or n
|
|
165
|
+
val = serialized.get(k)
|
|
166
|
+
|
|
167
|
+
if val != UNSET_SENTINEL:
|
|
168
|
+
if val is not None or k not in optional_fields:
|
|
169
|
+
m[k] = val
|
|
170
|
+
|
|
171
|
+
return m
|
|
172
|
+
|
|
125
173
|
|
|
126
174
|
GetEvalsDataEvalsResponse200ApplicationJSONGuardrailConfigTypedDict = TypeAliasType(
|
|
127
175
|
"GetEvalsDataEvalsResponse200ApplicationJSONGuardrailConfigTypedDict",
|
|
@@ -173,14 +221,30 @@ class DataTypescript(BaseModel):
|
|
|
173
221
|
|
|
174
222
|
key: str
|
|
175
223
|
|
|
176
|
-
created: Optional[str] = "2026-01-
|
|
224
|
+
created: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
177
225
|
|
|
178
|
-
updated: Optional[str] = "2026-01-
|
|
226
|
+
updated: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
179
227
|
|
|
180
228
|
guardrail_config: Optional[
|
|
181
229
|
GetEvalsDataEvalsResponse200ApplicationJSONGuardrailConfig
|
|
182
230
|
] = None
|
|
183
231
|
|
|
232
|
+
@model_serializer(mode="wrap")
|
|
233
|
+
def serialize_model(self, handler):
|
|
234
|
+
optional_fields = set(["created", "updated", "guardrail_config"])
|
|
235
|
+
serialized = handler(self)
|
|
236
|
+
m = {}
|
|
237
|
+
|
|
238
|
+
for n, f in type(self).model_fields.items():
|
|
239
|
+
k = f.alias or n
|
|
240
|
+
val = serialized.get(k)
|
|
241
|
+
|
|
242
|
+
if val != UNSET_SENTINEL:
|
|
243
|
+
if val is not None or k not in optional_fields:
|
|
244
|
+
m[k] = val
|
|
245
|
+
|
|
246
|
+
return m
|
|
247
|
+
|
|
184
248
|
|
|
185
249
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData62Type = Literal[
|
|
186
250
|
"number",
|
|
@@ -216,6 +280,22 @@ class GetEvalsGuardrailConfigEvalsResponse200Number(BaseModel):
|
|
|
216
280
|
|
|
217
281
|
alert_on_failure: Optional[bool] = False
|
|
218
282
|
|
|
283
|
+
@model_serializer(mode="wrap")
|
|
284
|
+
def serialize_model(self, handler):
|
|
285
|
+
optional_fields = set(["alert_on_failure"])
|
|
286
|
+
serialized = handler(self)
|
|
287
|
+
m = {}
|
|
288
|
+
|
|
289
|
+
for n, f in type(self).model_fields.items():
|
|
290
|
+
k = f.alias or n
|
|
291
|
+
val = serialized.get(k)
|
|
292
|
+
|
|
293
|
+
if val != UNSET_SENTINEL:
|
|
294
|
+
if val is not None or k not in optional_fields:
|
|
295
|
+
m[k] = val
|
|
296
|
+
|
|
297
|
+
return m
|
|
298
|
+
|
|
219
299
|
|
|
220
300
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData6Type = Literal[
|
|
221
301
|
"boolean",
|
|
@@ -238,6 +318,22 @@ class GetEvalsGuardrailConfigEvalsResponse200Boolean(BaseModel):
|
|
|
238
318
|
|
|
239
319
|
alert_on_failure: Optional[bool] = False
|
|
240
320
|
|
|
321
|
+
@model_serializer(mode="wrap")
|
|
322
|
+
def serialize_model(self, handler):
|
|
323
|
+
optional_fields = set(["alert_on_failure"])
|
|
324
|
+
serialized = handler(self)
|
|
325
|
+
m = {}
|
|
326
|
+
|
|
327
|
+
for n, f in type(self).model_fields.items():
|
|
328
|
+
k = f.alias or n
|
|
329
|
+
val = serialized.get(k)
|
|
330
|
+
|
|
331
|
+
if val != UNSET_SENTINEL:
|
|
332
|
+
if val is not None or k not in optional_fields:
|
|
333
|
+
m[k] = val
|
|
334
|
+
|
|
335
|
+
return m
|
|
336
|
+
|
|
241
337
|
|
|
242
338
|
GetEvalsDataEvalsResponse200GuardrailConfigTypedDict = TypeAliasType(
|
|
243
339
|
"GetEvalsDataEvalsResponse200GuardrailConfigTypedDict",
|
|
@@ -301,12 +397,28 @@ class DataRagas(BaseModel):
|
|
|
301
397
|
|
|
302
398
|
model: str
|
|
303
399
|
|
|
304
|
-
created: Optional[str] = "2026-01-
|
|
400
|
+
created: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
305
401
|
|
|
306
|
-
updated: Optional[str] = "2026-01-
|
|
402
|
+
updated: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
307
403
|
|
|
308
404
|
guardrail_config: Optional[GetEvalsDataEvalsResponse200GuardrailConfig] = None
|
|
309
405
|
|
|
406
|
+
@model_serializer(mode="wrap")
|
|
407
|
+
def serialize_model(self, handler):
|
|
408
|
+
optional_fields = set(["created", "updated", "guardrail_config"])
|
|
409
|
+
serialized = handler(self)
|
|
410
|
+
m = {}
|
|
411
|
+
|
|
412
|
+
for n, f in type(self).model_fields.items():
|
|
413
|
+
k = f.alias or n
|
|
414
|
+
val = serialized.get(k)
|
|
415
|
+
|
|
416
|
+
if val != UNSET_SENTINEL:
|
|
417
|
+
if val is not None or k not in optional_fields:
|
|
418
|
+
m[k] = val
|
|
419
|
+
|
|
420
|
+
return m
|
|
421
|
+
|
|
310
422
|
|
|
311
423
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData52Type = Literal[
|
|
312
424
|
"number",
|
|
@@ -342,6 +454,22 @@ class GetEvalsGuardrailConfigEvalsResponseNumber(BaseModel):
|
|
|
342
454
|
|
|
343
455
|
alert_on_failure: Optional[bool] = False
|
|
344
456
|
|
|
457
|
+
@model_serializer(mode="wrap")
|
|
458
|
+
def serialize_model(self, handler):
|
|
459
|
+
optional_fields = set(["alert_on_failure"])
|
|
460
|
+
serialized = handler(self)
|
|
461
|
+
m = {}
|
|
462
|
+
|
|
463
|
+
for n, f in type(self).model_fields.items():
|
|
464
|
+
k = f.alias or n
|
|
465
|
+
val = serialized.get(k)
|
|
466
|
+
|
|
467
|
+
if val != UNSET_SENTINEL:
|
|
468
|
+
if val is not None or k not in optional_fields:
|
|
469
|
+
m[k] = val
|
|
470
|
+
|
|
471
|
+
return m
|
|
472
|
+
|
|
345
473
|
|
|
346
474
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData5Type = Literal[
|
|
347
475
|
"boolean",
|
|
@@ -364,6 +492,22 @@ class GetEvalsGuardrailConfigEvalsResponseBoolean(BaseModel):
|
|
|
364
492
|
|
|
365
493
|
alert_on_failure: Optional[bool] = False
|
|
366
494
|
|
|
495
|
+
@model_serializer(mode="wrap")
|
|
496
|
+
def serialize_model(self, handler):
|
|
497
|
+
optional_fields = set(["alert_on_failure"])
|
|
498
|
+
serialized = handler(self)
|
|
499
|
+
m = {}
|
|
500
|
+
|
|
501
|
+
for n, f in type(self).model_fields.items():
|
|
502
|
+
k = f.alias or n
|
|
503
|
+
val = serialized.get(k)
|
|
504
|
+
|
|
505
|
+
if val != UNSET_SENTINEL:
|
|
506
|
+
if val is not None or k not in optional_fields:
|
|
507
|
+
m[k] = val
|
|
508
|
+
|
|
509
|
+
return m
|
|
510
|
+
|
|
367
511
|
|
|
368
512
|
GetEvalsDataEvalsResponseGuardrailConfigTypedDict = TypeAliasType(
|
|
369
513
|
"GetEvalsDataEvalsResponseGuardrailConfigTypedDict",
|
|
@@ -928,12 +1072,28 @@ class DataFunction(BaseModel):
|
|
|
928
1072
|
|
|
929
1073
|
key: str
|
|
930
1074
|
|
|
931
|
-
created: Optional[str] = "2026-01-
|
|
1075
|
+
created: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
932
1076
|
|
|
933
|
-
updated: Optional[str] = "2026-01-
|
|
1077
|
+
updated: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
934
1078
|
|
|
935
1079
|
guardrail_config: Optional[GetEvalsDataEvalsResponseGuardrailConfig] = None
|
|
936
1080
|
|
|
1081
|
+
@model_serializer(mode="wrap")
|
|
1082
|
+
def serialize_model(self, handler):
|
|
1083
|
+
optional_fields = set(["created", "updated", "guardrail_config"])
|
|
1084
|
+
serialized = handler(self)
|
|
1085
|
+
m = {}
|
|
1086
|
+
|
|
1087
|
+
for n, f in type(self).model_fields.items():
|
|
1088
|
+
k = f.alias or n
|
|
1089
|
+
val = serialized.get(k)
|
|
1090
|
+
|
|
1091
|
+
if val != UNSET_SENTINEL:
|
|
1092
|
+
if val is not None or k not in optional_fields:
|
|
1093
|
+
m[k] = val
|
|
1094
|
+
|
|
1095
|
+
return m
|
|
1096
|
+
|
|
937
1097
|
|
|
938
1098
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyDataType = Literal[
|
|
939
1099
|
"number",
|
|
@@ -969,6 +1129,22 @@ class GetEvalsGuardrailConfigEvalsNumber(BaseModel):
|
|
|
969
1129
|
|
|
970
1130
|
alert_on_failure: Optional[bool] = False
|
|
971
1131
|
|
|
1132
|
+
@model_serializer(mode="wrap")
|
|
1133
|
+
def serialize_model(self, handler):
|
|
1134
|
+
optional_fields = set(["alert_on_failure"])
|
|
1135
|
+
serialized = handler(self)
|
|
1136
|
+
m = {}
|
|
1137
|
+
|
|
1138
|
+
for n, f in type(self).model_fields.items():
|
|
1139
|
+
k = f.alias or n
|
|
1140
|
+
val = serialized.get(k)
|
|
1141
|
+
|
|
1142
|
+
if val != UNSET_SENTINEL:
|
|
1143
|
+
if val is not None or k not in optional_fields:
|
|
1144
|
+
m[k] = val
|
|
1145
|
+
|
|
1146
|
+
return m
|
|
1147
|
+
|
|
972
1148
|
|
|
973
1149
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyType = Literal[
|
|
974
1150
|
"boolean",
|
|
@@ -991,6 +1167,22 @@ class GetEvalsGuardrailConfigEvalsBoolean(BaseModel):
|
|
|
991
1167
|
|
|
992
1168
|
alert_on_failure: Optional[bool] = False
|
|
993
1169
|
|
|
1170
|
+
@model_serializer(mode="wrap")
|
|
1171
|
+
def serialize_model(self, handler):
|
|
1172
|
+
optional_fields = set(["alert_on_failure"])
|
|
1173
|
+
serialized = handler(self)
|
|
1174
|
+
m = {}
|
|
1175
|
+
|
|
1176
|
+
for n, f in type(self).model_fields.items():
|
|
1177
|
+
k = f.alias or n
|
|
1178
|
+
val = serialized.get(k)
|
|
1179
|
+
|
|
1180
|
+
if val != UNSET_SENTINEL:
|
|
1181
|
+
if val is not None or k not in optional_fields:
|
|
1182
|
+
m[k] = val
|
|
1183
|
+
|
|
1184
|
+
return m
|
|
1185
|
+
|
|
994
1186
|
|
|
995
1187
|
GetEvalsDataEvalsGuardrailConfigTypedDict = TypeAliasType(
|
|
996
1188
|
"GetEvalsDataEvalsGuardrailConfigTypedDict",
|
|
@@ -1035,12 +1227,28 @@ class DataPython(BaseModel):
|
|
|
1035
1227
|
|
|
1036
1228
|
key: str
|
|
1037
1229
|
|
|
1038
|
-
created: Optional[str] = "2026-01-
|
|
1230
|
+
created: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1039
1231
|
|
|
1040
|
-
updated: Optional[str] = "2026-01-
|
|
1232
|
+
updated: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1041
1233
|
|
|
1042
1234
|
guardrail_config: Optional[GetEvalsDataEvalsGuardrailConfig] = None
|
|
1043
1235
|
|
|
1236
|
+
@model_serializer(mode="wrap")
|
|
1237
|
+
def serialize_model(self, handler):
|
|
1238
|
+
optional_fields = set(["created", "updated", "guardrail_config"])
|
|
1239
|
+
serialized = handler(self)
|
|
1240
|
+
m = {}
|
|
1241
|
+
|
|
1242
|
+
for n, f in type(self).model_fields.items():
|
|
1243
|
+
k = f.alias or n
|
|
1244
|
+
val = serialized.get(k)
|
|
1245
|
+
|
|
1246
|
+
if val != UNSET_SENTINEL:
|
|
1247
|
+
if val is not None or k not in optional_fields:
|
|
1248
|
+
m[k] = val
|
|
1249
|
+
|
|
1250
|
+
return m
|
|
1251
|
+
|
|
1044
1252
|
|
|
1045
1253
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONType = Literal["number",]
|
|
1046
1254
|
|
|
@@ -1074,6 +1282,22 @@ class GetEvalsGuardrailConfigNumber(BaseModel):
|
|
|
1074
1282
|
|
|
1075
1283
|
alert_on_failure: Optional[bool] = False
|
|
1076
1284
|
|
|
1285
|
+
@model_serializer(mode="wrap")
|
|
1286
|
+
def serialize_model(self, handler):
|
|
1287
|
+
optional_fields = set(["alert_on_failure"])
|
|
1288
|
+
serialized = handler(self)
|
|
1289
|
+
m = {}
|
|
1290
|
+
|
|
1291
|
+
for n, f in type(self).model_fields.items():
|
|
1292
|
+
k = f.alias or n
|
|
1293
|
+
val = serialized.get(k)
|
|
1294
|
+
|
|
1295
|
+
if val != UNSET_SENTINEL:
|
|
1296
|
+
if val is not None or k not in optional_fields:
|
|
1297
|
+
m[k] = val
|
|
1298
|
+
|
|
1299
|
+
return m
|
|
1300
|
+
|
|
1077
1301
|
|
|
1078
1302
|
GetEvalsGuardrailConfigEvalsResponse200Type = Literal["boolean",]
|
|
1079
1303
|
|
|
@@ -1094,6 +1318,22 @@ class GetEvalsGuardrailConfigBoolean(BaseModel):
|
|
|
1094
1318
|
|
|
1095
1319
|
alert_on_failure: Optional[bool] = False
|
|
1096
1320
|
|
|
1321
|
+
@model_serializer(mode="wrap")
|
|
1322
|
+
def serialize_model(self, handler):
|
|
1323
|
+
optional_fields = set(["alert_on_failure"])
|
|
1324
|
+
serialized = handler(self)
|
|
1325
|
+
m = {}
|
|
1326
|
+
|
|
1327
|
+
for n, f in type(self).model_fields.items():
|
|
1328
|
+
k = f.alias or n
|
|
1329
|
+
val = serialized.get(k)
|
|
1330
|
+
|
|
1331
|
+
if val != UNSET_SENTINEL:
|
|
1332
|
+
if val is not None or k not in optional_fields:
|
|
1333
|
+
m[k] = val
|
|
1334
|
+
|
|
1335
|
+
return m
|
|
1336
|
+
|
|
1097
1337
|
|
|
1098
1338
|
GetEvalsDataGuardrailConfigTypedDict = TypeAliasType(
|
|
1099
1339
|
"GetEvalsDataGuardrailConfigTypedDict",
|
|
@@ -1152,12 +1392,28 @@ class DataHTTP(BaseModel):
|
|
|
1152
1392
|
|
|
1153
1393
|
key: str
|
|
1154
1394
|
|
|
1155
|
-
created: Optional[str] = "2026-01-
|
|
1395
|
+
created: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1156
1396
|
|
|
1157
|
-
updated: Optional[str] = "2026-01-
|
|
1397
|
+
updated: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1158
1398
|
|
|
1159
1399
|
guardrail_config: Optional[GetEvalsDataGuardrailConfig] = None
|
|
1160
1400
|
|
|
1401
|
+
@model_serializer(mode="wrap")
|
|
1402
|
+
def serialize_model(self, handler):
|
|
1403
|
+
optional_fields = set(["created", "updated", "guardrail_config"])
|
|
1404
|
+
serialized = handler(self)
|
|
1405
|
+
m = {}
|
|
1406
|
+
|
|
1407
|
+
for n, f in type(self).model_fields.items():
|
|
1408
|
+
k = f.alias or n
|
|
1409
|
+
val = serialized.get(k)
|
|
1410
|
+
|
|
1411
|
+
if val != UNSET_SENTINEL:
|
|
1412
|
+
if val is not None or k not in optional_fields:
|
|
1413
|
+
m[k] = val
|
|
1414
|
+
|
|
1415
|
+
return m
|
|
1416
|
+
|
|
1161
1417
|
|
|
1162
1418
|
GetEvalsGuardrailConfigEvalsResponseType = Literal["number",]
|
|
1163
1419
|
|
|
@@ -1201,6 +1457,22 @@ class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyDataNumb
|
|
|
1201
1457
|
|
|
1202
1458
|
alert_on_failure: Optional[bool] = False
|
|
1203
1459
|
|
|
1460
|
+
@model_serializer(mode="wrap")
|
|
1461
|
+
def serialize_model(self, handler):
|
|
1462
|
+
optional_fields = set(["alert_on_failure"])
|
|
1463
|
+
serialized = handler(self)
|
|
1464
|
+
m = {}
|
|
1465
|
+
|
|
1466
|
+
for n, f in type(self).model_fields.items():
|
|
1467
|
+
k = f.alias or n
|
|
1468
|
+
val = serialized.get(k)
|
|
1469
|
+
|
|
1470
|
+
if val != UNSET_SENTINEL:
|
|
1471
|
+
if val is not None or k not in optional_fields:
|
|
1472
|
+
m[k] = val
|
|
1473
|
+
|
|
1474
|
+
return m
|
|
1475
|
+
|
|
1204
1476
|
|
|
1205
1477
|
GetEvalsGuardrailConfigEvalsType = Literal["boolean",]
|
|
1206
1478
|
|
|
@@ -1225,6 +1497,62 @@ class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyDataBool
|
|
|
1225
1497
|
|
|
1226
1498
|
alert_on_failure: Optional[bool] = False
|
|
1227
1499
|
|
|
1500
|
+
@model_serializer(mode="wrap")
|
|
1501
|
+
def serialize_model(self, handler):
|
|
1502
|
+
optional_fields = set(["alert_on_failure"])
|
|
1503
|
+
serialized = handler(self)
|
|
1504
|
+
m = {}
|
|
1505
|
+
|
|
1506
|
+
for n, f in type(self).model_fields.items():
|
|
1507
|
+
k = f.alias or n
|
|
1508
|
+
val = serialized.get(k)
|
|
1509
|
+
|
|
1510
|
+
if val != UNSET_SENTINEL:
|
|
1511
|
+
if val is not None or k not in optional_fields:
|
|
1512
|
+
m[k] = val
|
|
1513
|
+
|
|
1514
|
+
return m
|
|
1515
|
+
|
|
1516
|
+
|
|
1517
|
+
class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyNumberTypedDict(
|
|
1518
|
+
TypedDict
|
|
1519
|
+
):
|
|
1520
|
+
enabled: bool
|
|
1521
|
+
type: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData1Type
|
|
1522
|
+
value: float
|
|
1523
|
+
operator: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyOperator
|
|
1524
|
+
alert_on_failure: NotRequired[bool]
|
|
1525
|
+
|
|
1526
|
+
|
|
1527
|
+
class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyNumber(
|
|
1528
|
+
BaseModel
|
|
1529
|
+
):
|
|
1530
|
+
enabled: bool
|
|
1531
|
+
|
|
1532
|
+
type: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData1Type
|
|
1533
|
+
|
|
1534
|
+
value: float
|
|
1535
|
+
|
|
1536
|
+
operator: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyOperator
|
|
1537
|
+
|
|
1538
|
+
alert_on_failure: Optional[bool] = False
|
|
1539
|
+
|
|
1540
|
+
@model_serializer(mode="wrap")
|
|
1541
|
+
def serialize_model(self, handler):
|
|
1542
|
+
optional_fields = set(["alert_on_failure"])
|
|
1543
|
+
serialized = handler(self)
|
|
1544
|
+
m = {}
|
|
1545
|
+
|
|
1546
|
+
for n, f in type(self).model_fields.items():
|
|
1547
|
+
k = f.alias or n
|
|
1548
|
+
val = serialized.get(k)
|
|
1549
|
+
|
|
1550
|
+
if val != UNSET_SENTINEL:
|
|
1551
|
+
if val is not None or k not in optional_fields:
|
|
1552
|
+
m[k] = val
|
|
1553
|
+
|
|
1554
|
+
return m
|
|
1555
|
+
|
|
1228
1556
|
|
|
1229
1557
|
DataGuardrailConfigTypedDict = TypeAliasType(
|
|
1230
1558
|
"DataGuardrailConfigTypedDict",
|
|
@@ -1275,12 +1603,28 @@ class DataJSON(BaseModel):
|
|
|
1275
1603
|
|
|
1276
1604
|
key: str
|
|
1277
1605
|
|
|
1278
|
-
created: Optional[str] = "2026-01-
|
|
1606
|
+
created: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1279
1607
|
|
|
1280
|
-
updated: Optional[str] = "2026-01-
|
|
1608
|
+
updated: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1281
1609
|
|
|
1282
1610
|
guardrail_config: Optional[DataGuardrailConfig] = None
|
|
1283
1611
|
|
|
1612
|
+
@model_serializer(mode="wrap")
|
|
1613
|
+
def serialize_model(self, handler):
|
|
1614
|
+
optional_fields = set(["created", "updated", "guardrail_config"])
|
|
1615
|
+
serialized = handler(self)
|
|
1616
|
+
m = {}
|
|
1617
|
+
|
|
1618
|
+
for n, f in type(self).model_fields.items():
|
|
1619
|
+
k = f.alias or n
|
|
1620
|
+
val = serialized.get(k)
|
|
1621
|
+
|
|
1622
|
+
if val != UNSET_SENTINEL:
|
|
1623
|
+
if val is not None or k not in optional_fields:
|
|
1624
|
+
m[k] = val
|
|
1625
|
+
|
|
1626
|
+
return m
|
|
1627
|
+
|
|
1284
1628
|
|
|
1285
1629
|
GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData1Type = Literal[
|
|
1286
1630
|
"number",
|
|
@@ -1297,30 +1641,6 @@ GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyOperator = Lit
|
|
|
1297
1641
|
]
|
|
1298
1642
|
|
|
1299
1643
|
|
|
1300
|
-
class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyNumberTypedDict(
|
|
1301
|
-
TypedDict
|
|
1302
|
-
):
|
|
1303
|
-
enabled: bool
|
|
1304
|
-
type: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData1Type
|
|
1305
|
-
value: float
|
|
1306
|
-
operator: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyOperator
|
|
1307
|
-
alert_on_failure: NotRequired[bool]
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyNumber(
|
|
1311
|
-
BaseModel
|
|
1312
|
-
):
|
|
1313
|
-
enabled: bool
|
|
1314
|
-
|
|
1315
|
-
type: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyData1Type
|
|
1316
|
-
|
|
1317
|
-
value: float
|
|
1318
|
-
|
|
1319
|
-
operator: GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyOperator
|
|
1320
|
-
|
|
1321
|
-
alert_on_failure: Optional[bool] = False
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
1644
|
GetEvalsGuardrailConfigType = Literal["boolean",]
|
|
1325
1645
|
|
|
1326
1646
|
|
|
@@ -1344,6 +1664,22 @@ class GetEvalsGuardrailConfigEvalsResponse200ApplicationJSONResponseBodyBoolean(
|
|
|
1344
1664
|
|
|
1345
1665
|
alert_on_failure: Optional[bool] = False
|
|
1346
1666
|
|
|
1667
|
+
@model_serializer(mode="wrap")
|
|
1668
|
+
def serialize_model(self, handler):
|
|
1669
|
+
optional_fields = set(["alert_on_failure"])
|
|
1670
|
+
serialized = handler(self)
|
|
1671
|
+
m = {}
|
|
1672
|
+
|
|
1673
|
+
for n, f in type(self).model_fields.items():
|
|
1674
|
+
k = f.alias or n
|
|
1675
|
+
val = serialized.get(k)
|
|
1676
|
+
|
|
1677
|
+
if val != UNSET_SENTINEL:
|
|
1678
|
+
if val is not None or k not in optional_fields:
|
|
1679
|
+
m[k] = val
|
|
1680
|
+
|
|
1681
|
+
return m
|
|
1682
|
+
|
|
1347
1683
|
|
|
1348
1684
|
GetEvalsDataEvalsResponse200ApplicationJSONResponseBodyGuardrailConfigTypedDict = TypeAliasType(
|
|
1349
1685
|
"GetEvalsDataEvalsResponse200ApplicationJSONResponseBodyGuardrailConfigTypedDict",
|
|
@@ -1399,14 +1735,30 @@ class DataLLM(BaseModel):
|
|
|
1399
1735
|
|
|
1400
1736
|
model: str
|
|
1401
1737
|
|
|
1402
|
-
created: Optional[str] = "2026-01-
|
|
1738
|
+
created: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1403
1739
|
|
|
1404
|
-
updated: Optional[str] = "2026-01-
|
|
1740
|
+
updated: Optional[str] = "2026-01-25T15:02:08.775Z"
|
|
1405
1741
|
|
|
1406
1742
|
guardrail_config: Optional[
|
|
1407
1743
|
GetEvalsDataEvalsResponse200ApplicationJSONResponseBodyGuardrailConfig
|
|
1408
1744
|
] = None
|
|
1409
1745
|
|
|
1746
|
+
@model_serializer(mode="wrap")
|
|
1747
|
+
def serialize_model(self, handler):
|
|
1748
|
+
optional_fields = set(["created", "updated", "guardrail_config"])
|
|
1749
|
+
serialized = handler(self)
|
|
1750
|
+
m = {}
|
|
1751
|
+
|
|
1752
|
+
for n, f in type(self).model_fields.items():
|
|
1753
|
+
k = f.alias or n
|
|
1754
|
+
val = serialized.get(k)
|
|
1755
|
+
|
|
1756
|
+
if val != UNSET_SENTINEL:
|
|
1757
|
+
if val is not None or k not in optional_fields:
|
|
1758
|
+
m[k] = val
|
|
1759
|
+
|
|
1760
|
+
return m
|
|
1761
|
+
|
|
1410
1762
|
|
|
1411
1763
|
GetEvalsDataTypedDict = TypeAliasType(
|
|
1412
1764
|
"GetEvalsDataTypedDict",
|
|
@@ -1439,7 +1791,7 @@ GetEvalsData = Annotated[
|
|
|
1439
1791
|
class GetEvalsResponseBodyTypedDict(TypedDict):
|
|
1440
1792
|
r"""Returns a list of evals"""
|
|
1441
1793
|
|
|
1442
|
-
object:
|
|
1794
|
+
object: Object
|
|
1443
1795
|
data: List[GetEvalsDataTypedDict]
|
|
1444
1796
|
has_more: bool
|
|
1445
1797
|
|
|
@@ -1447,7 +1799,7 @@ class GetEvalsResponseBodyTypedDict(TypedDict):
|
|
|
1447
1799
|
class GetEvalsResponseBody(BaseModel):
|
|
1448
1800
|
r"""Returns a list of evals"""
|
|
1449
1801
|
|
|
1450
|
-
object:
|
|
1802
|
+
object: Object
|
|
1451
1803
|
|
|
1452
1804
|
data: List[GetEvalsData]
|
|
1453
1805
|
|
|
@@ -114,30 +114,25 @@ class GetOneChunkResponseBody(BaseModel):
|
|
|
114
114
|
|
|
115
115
|
@model_serializer(mode="wrap")
|
|
116
116
|
def serialize_model(self, handler):
|
|
117
|
-
optional_fields = ["metadata", "created_by_id", "update_by_id"]
|
|
118
|
-
nullable_fields = ["created_by_id", "update_by_id"]
|
|
119
|
-
null_default_fields = []
|
|
120
|
-
|
|
117
|
+
optional_fields = set(["metadata", "created_by_id", "update_by_id"])
|
|
118
|
+
nullable_fields = set(["created_by_id", "update_by_id"])
|
|
121
119
|
serialized = handler(self)
|
|
122
|
-
|
|
123
120
|
m = {}
|
|
124
121
|
|
|
125
122
|
for n, f in type(self).model_fields.items():
|
|
126
123
|
k = f.alias or n
|
|
127
124
|
val = serialized.get(k)
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
):
|
|
141
|
-
m[k] = val
|
|
125
|
+
is_nullable_and_explicitly_set = (
|
|
126
|
+
k in nullable_fields
|
|
127
|
+
and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member
|
|
128
|
+
)
|
|
129
|
+
|
|
130
|
+
if val != UNSET_SENTINEL:
|
|
131
|
+
if (
|
|
132
|
+
val is not None
|
|
133
|
+
or k not in optional_fields
|
|
134
|
+
or is_nullable_and_explicitly_set
|
|
135
|
+
):
|
|
136
|
+
m[k] = val
|
|
142
137
|
|
|
143
138
|
return m
|