adaline-api 1.0.0__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.
- adaline_api/__init__.py +193 -0
- adaline_api/api/__init__.py +5 -0
- adaline_api/api/default_api.py +1221 -0
- adaline_api/api_client.py +804 -0
- adaline_api/api_response.py +21 -0
- adaline_api/configuration.py +582 -0
- adaline_api/exceptions.py +216 -0
- adaline_api/models/__init__.py +89 -0
- adaline_api/models/api_message_content.py +113 -0
- adaline_api/models/api_message_content_type.py +113 -0
- adaline_api/models/base64_hosted_image_content_value.py +99 -0
- adaline_api/models/base64_hosted_image_content_value_type.py +99 -0
- adaline_api/models/base64_hosted_pdf_content_value.py +99 -0
- adaline_api/models/base64_hosted_pdf_content_value_type.py +99 -0
- adaline_api/models/base64_image_content_value.py +105 -0
- adaline_api/models/base64_image_content_value_type.py +105 -0
- adaline_api/models/base64_media.py +118 -0
- adaline_api/models/base64_media_type.py +118 -0
- adaline_api/models/base64_pdf_content_value.py +96 -0
- adaline_api/models/base64_pdf_content_value_type.py +96 -0
- adaline_api/models/base_entity.py +96 -0
- adaline_api/models/config_type.py +94 -0
- adaline_api/models/content.py +196 -0
- adaline_api/models/content_type.py +196 -0
- adaline_api/models/create_log_span_request.py +94 -0
- adaline_api/models/create_log_span_request_span.py +150 -0
- adaline_api/models/create_log_span_request_type.py +94 -0
- adaline_api/models/create_log_span_response.py +88 -0
- adaline_api/models/create_log_span_response_type.py +88 -0
- adaline_api/models/create_log_trace_request.py +104 -0
- adaline_api/models/create_log_trace_request_span.py +146 -0
- adaline_api/models/create_log_trace_request_trace.py +122 -0
- adaline_api/models/create_log_trace_request_type.py +104 -0
- adaline_api/models/create_log_trace_response.py +90 -0
- adaline_api/models/create_log_trace_response_type.py +90 -0
- adaline_api/models/deployment.py +107 -0
- adaline_api/models/deployment_prompt.py +121 -0
- adaline_api/models/deployment_prompt_config.py +94 -0
- adaline_api/models/deployment_prompt_config_type.py +94 -0
- adaline_api/models/deployment_prompt_type.py +121 -0
- adaline_api/models/deployment_prompt_variables.py +96 -0
- adaline_api/models/deployment_prompt_variables_type.py +96 -0
- adaline_api/models/deployment_type.py +107 -0
- adaline_api/models/deployment_type_prompt.py +121 -0
- adaline_api/models/enum_value.py +166 -0
- adaline_api/models/enum_value_type.py +166 -0
- adaline_api/models/error_response.py +91 -0
- adaline_api/models/error_response_type.py +91 -0
- adaline_api/models/function.py +101 -0
- adaline_api/models/function_parameter.py +139 -0
- adaline_api/models/function_parameter_type.py +139 -0
- adaline_api/models/function_parameters.py +115 -0
- adaline_api/models/function_parameters_type.py +115 -0
- adaline_api/models/function_request_http.py +121 -0
- adaline_api/models/function_request_http_type.py +121 -0
- adaline_api/models/function_request_retry.py +92 -0
- adaline_api/models/function_request_retry_type.py +92 -0
- adaline_api/models/function_tool.py +106 -0
- adaline_api/models/function_tool_definition.py +91 -0
- adaline_api/models/function_tool_definition_type.py +104 -0
- adaline_api/models/function_tool_type.py +106 -0
- adaline_api/models/function_tool_type_definition.py +91 -0
- adaline_api/models/function_type.py +106 -0
- adaline_api/models/image_content.py +109 -0
- adaline_api/models/image_content_type.py +109 -0
- adaline_api/models/image_content_value.py +140 -0
- adaline_api/models/image_content_value_type.py +140 -0
- adaline_api/models/image_message_content.py +111 -0
- adaline_api/models/image_message_content_type.py +111 -0
- adaline_api/models/image_message_content_type_value.py +154 -0
- adaline_api/models/image_message_content_value.py +154 -0
- adaline_api/models/image_source.py +140 -0
- adaline_api/models/image_source_type.py +140 -0
- adaline_api/models/log_attributes_value.py +160 -0
- adaline_api/models/log_feedback_comment.py +98 -0
- adaline_api/models/log_span.py +180 -0
- adaline_api/models/log_span_all_of_internal_feedback.py +98 -0
- adaline_api/models/log_span_content.py +224 -0
- adaline_api/models/log_span_embeddings_content.py +101 -0
- adaline_api/models/log_span_event.py +96 -0
- adaline_api/models/log_span_function_content.py +101 -0
- adaline_api/models/log_span_guardrail_content.py +101 -0
- adaline_api/models/log_span_model_content.py +109 -0
- adaline_api/models/log_span_model_stream_content.py +111 -0
- adaline_api/models/log_span_other_content.py +101 -0
- adaline_api/models/log_span_parsed_content.py +101 -0
- adaline_api/models/log_span_retrieval_content.py +101 -0
- adaline_api/models/log_span_tool_content.py +101 -0
- adaline_api/models/log_trace.py +132 -0
- adaline_api/models/log_trace_attributes_inner.py +102 -0
- adaline_api/models/log_trace_attributes_value.py +160 -0
- adaline_api/models/log_trace_attributes_value_type.py +160 -0
- adaline_api/models/log_trace_tags_inner.py +96 -0
- adaline_api/models/log_trace_type.py +132 -0
- adaline_api/models/log_trace_type_attributes_inner.py +102 -0
- adaline_api/models/log_trace_type_tags_inner.py +96 -0
- adaline_api/models/mcp_server.py +114 -0
- adaline_api/models/mcp_server_tool_configuration.py +90 -0
- adaline_api/models/mcp_server_tool_configuration_type.py +90 -0
- adaline_api/models/mcp_server_type.py +114 -0
- adaline_api/models/message.py +98 -0
- adaline_api/models/message_content_inner.py +182 -0
- adaline_api/models/message_content_type_inner.py +182 -0
- adaline_api/models/message_type.py +98 -0
- adaline_api/models/modality_enum.py +41 -0
- adaline_api/models/modality_enum_type.py +41 -0
- adaline_api/models/pdf_content.py +106 -0
- adaline_api/models/pdf_content_file.py +91 -0
- adaline_api/models/pdf_content_type.py +106 -0
- adaline_api/models/pdf_content_type_file.py +91 -0
- adaline_api/models/pdf_content_value.py +140 -0
- adaline_api/models/pdf_content_value_type.py +140 -0
- adaline_api/models/pdf_message_content.py +108 -0
- adaline_api/models/pdf_message_content_file.py +91 -0
- adaline_api/models/pdf_message_content_type.py +108 -0
- adaline_api/models/pdf_message_content_type_file.py +91 -0
- adaline_api/models/pdf_message_content_type_value.py +154 -0
- adaline_api/models/pdf_message_content_value.py +154 -0
- adaline_api/models/prompt_variable.py +96 -0
- adaline_api/models/prompt_variable_value.py +210 -0
- adaline_api/models/reasoning_content.py +100 -0
- adaline_api/models/reasoning_content_type.py +100 -0
- adaline_api/models/reasoning_content_value.py +98 -0
- adaline_api/models/reasoning_content_value_type.py +98 -0
- adaline_api/models/reasoning_content_value_union.py +140 -0
- adaline_api/models/reasoning_content_value_union_type.py +140 -0
- adaline_api/models/reasoning_message_content.py +102 -0
- adaline_api/models/reasoning_message_content_type.py +102 -0
- adaline_api/models/reasoning_message_content_type_value.py +140 -0
- adaline_api/models/reasoning_message_content_value.py +140 -0
- adaline_api/models/reasoning_redacted_value.py +109 -0
- adaline_api/models/reasoning_redacted_value_type.py +109 -0
- adaline_api/models/reasoning_thinking_value.py +111 -0
- adaline_api/models/reasoning_thinking_value_type.py +111 -0
- adaline_api/models/reasoning_value.py +140 -0
- adaline_api/models/reasoning_value_type.py +140 -0
- adaline_api/models/redacted_reasoning_content_value.py +96 -0
- adaline_api/models/redacted_reasoning_content_value_type.py +96 -0
- adaline_api/models/response_schema.py +105 -0
- adaline_api/models/response_schema_property.py +135 -0
- adaline_api/models/response_schema_property_enum_inner.py +166 -0
- adaline_api/models/response_schema_property_type.py +143 -0
- adaline_api/models/response_schema_property_type_enum_inner.py +166 -0
- adaline_api/models/response_schema_property_type_type.py +143 -0
- adaline_api/models/response_schema_structure.py +122 -0
- adaline_api/models/response_schema_structure_type.py +122 -0
- adaline_api/models/response_schema_type.py +105 -0
- adaline_api/models/role_enum.py +39 -0
- adaline_api/models/role_enum_type.py +39 -0
- adaline_api/models/span_content_detailed.py +112 -0
- adaline_api/models/span_content_detailed_type.py +112 -0
- adaline_api/models/span_content_detailed_type_variables_value.py +94 -0
- adaline_api/models/span_content_detailed_variables_value.py +94 -0
- adaline_api/models/span_content_minimal.py +91 -0
- adaline_api/models/span_content_minimal_type.py +91 -0
- adaline_api/models/span_log_req_attributes.py +160 -0
- adaline_api/models/span_log_req_attributes_type.py +160 -0
- adaline_api/models/span_log_req_content.py +137 -0
- adaline_api/models/span_log_req_content_type.py +137 -0
- adaline_api/models/span_log_request.py +93 -0
- adaline_api/models/span_log_request_span.py +139 -0
- adaline_api/models/span_log_request_type.py +93 -0
- adaline_api/models/span_log_request_type_span.py +139 -0
- adaline_api/models/span_log_response.py +87 -0
- adaline_api/models/span_log_response_type.py +87 -0
- adaline_api/models/spans_request_attribute_value.py +160 -0
- adaline_api/models/spans_request_attribute_value_type.py +160 -0
- adaline_api/models/spans_request_content_value.py +143 -0
- adaline_api/models/spans_request_content_value_type.py +143 -0
- adaline_api/models/text_content.py +96 -0
- adaline_api/models/text_content_type.py +96 -0
- adaline_api/models/text_message_content.py +98 -0
- adaline_api/models/text_message_content_type.py +98 -0
- adaline_api/models/tool_call_content.py +105 -0
- adaline_api/models/tool_call_content_type.py +105 -0
- adaline_api/models/tool_call_message_content.py +107 -0
- adaline_api/models/tool_call_message_content_type.py +107 -0
- adaline_api/models/tool_response_content.py +109 -0
- adaline_api/models/tool_response_content_api_response.py +88 -0
- adaline_api/models/tool_response_content_type.py +109 -0
- adaline_api/models/tool_response_content_type_api_response.py +88 -0
- adaline_api/models/tool_response_message_content.py +111 -0
- adaline_api/models/tool_response_message_content_api_response.py +87 -0
- adaline_api/models/tool_response_message_content_type.py +111 -0
- adaline_api/models/tool_response_message_content_type_api_response.py +87 -0
- adaline_api/models/tool_type.py +113 -0
- adaline_api/models/trace_log_patch_request.py +137 -0
- adaline_api/models/trace_log_patch_request_one_of.py +97 -0
- adaline_api/models/trace_log_patch_request_one_of1.py +97 -0
- adaline_api/models/trace_log_patch_request_type.py +137 -0
- adaline_api/models/trace_log_patch_request_type_one_of.py +97 -0
- adaline_api/models/trace_log_patch_request_type_one_of1.py +97 -0
- adaline_api/models/trace_log_patch_response.py +87 -0
- adaline_api/models/trace_log_patch_response_type.py +87 -0
- adaline_api/models/trace_log_request.py +103 -0
- adaline_api/models/trace_log_request_spans_inner.py +135 -0
- adaline_api/models/trace_log_request_trace.py +121 -0
- adaline_api/models/trace_log_request_type.py +103 -0
- adaline_api/models/trace_log_request_type_spans_inner.py +135 -0
- adaline_api/models/trace_log_request_type_trace.py +121 -0
- adaline_api/models/trace_log_response.py +89 -0
- adaline_api/models/trace_log_response_type.py +89 -0
- adaline_api/models/trace_request_attribute_value.py +160 -0
- adaline_api/models/trace_request_attribute_value_type.py +160 -0
- adaline_api/models/update_log_trace_request.py +98 -0
- adaline_api/models/update_log_trace_request_attribute_item.py +140 -0
- adaline_api/models/update_log_trace_request_attribute_item_one_of.py +102 -0
- adaline_api/models/update_log_trace_request_attribute_item_one_of1.py +96 -0
- adaline_api/models/update_log_trace_request_attribute_item_one_of_value.py +160 -0
- adaline_api/models/update_log_trace_request_tag_item.py +140 -0
- adaline_api/models/update_log_trace_request_tag_item_one_of.py +97 -0
- adaline_api/models/update_log_trace_request_tag_item_one_of1.py +97 -0
- adaline_api/models/update_log_trace_request_trace.py +120 -0
- adaline_api/models/update_log_trace_request_type.py +98 -0
- adaline_api/models/update_log_trace_response.py +87 -0
- adaline_api/models/update_log_trace_response_type.py +87 -0
- adaline_api/models/url_image_content_value.py +96 -0
- adaline_api/models/url_image_content_value_type.py +96 -0
- adaline_api/models/url_media.py +109 -0
- adaline_api/models/url_media_type.py +109 -0
- adaline_api/models/url_pdf_content_value.py +96 -0
- adaline_api/models/url_pdf_content_value_type.py +96 -0
- adaline_api/models/variable.py +96 -0
- adaline_api/models/variable_type.py +96 -0
- adaline_api/models/variable_type_value.py +196 -0
- adaline_api/models/variable_value.py +196 -0
- adaline_api/models/variables_type.py +96 -0
- adaline_api/py.typed +0 -0
- adaline_api/rest.py +213 -0
- adaline_api-1.0.0.dist-info/METADATA +227 -0
- adaline_api-1.0.0.dist-info/RECORD +233 -0
- adaline_api-1.0.0.dist-info/WHEEL +5 -0
- adaline_api-1.0.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Adaline API
|
|
5
|
+
|
|
6
|
+
API for managing Adaline deployments, logs, and core type definitions.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class UrlImageContentValueType(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
UrlImageContentValueType
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
type: StrictStr
|
|
30
|
+
url: StrictStr
|
|
31
|
+
__properties: ClassVar[List[str]] = ["type", "url"]
|
|
32
|
+
|
|
33
|
+
@field_validator('type')
|
|
34
|
+
def type_validate_enum(cls, value):
|
|
35
|
+
"""Validates the enum"""
|
|
36
|
+
if value not in set(['url']):
|
|
37
|
+
raise ValueError("must be one of enum values ('url')")
|
|
38
|
+
return value
|
|
39
|
+
|
|
40
|
+
model_config = ConfigDict(
|
|
41
|
+
populate_by_name=True,
|
|
42
|
+
validate_assignment=True,
|
|
43
|
+
protected_namespaces=(),
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
def to_str(self) -> str:
|
|
48
|
+
"""Returns the string representation of the model using alias"""
|
|
49
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
50
|
+
|
|
51
|
+
def to_json(self) -> str:
|
|
52
|
+
"""Returns the JSON representation of the model using alias"""
|
|
53
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
54
|
+
return json.dumps(self.to_dict())
|
|
55
|
+
|
|
56
|
+
@classmethod
|
|
57
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
58
|
+
"""Create an instance of UrlImageContentValueType from a JSON string"""
|
|
59
|
+
return cls.from_dict(json.loads(json_str))
|
|
60
|
+
|
|
61
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
62
|
+
"""Return the dictionary representation of the model using alias.
|
|
63
|
+
|
|
64
|
+
This has the following differences from calling pydantic's
|
|
65
|
+
`self.model_dump(by_alias=True)`:
|
|
66
|
+
|
|
67
|
+
* `None` is only added to the output dict for nullable fields that
|
|
68
|
+
were set at model initialization. Other fields with value `None`
|
|
69
|
+
are ignored.
|
|
70
|
+
"""
|
|
71
|
+
excluded_fields: Set[str] = set([
|
|
72
|
+
])
|
|
73
|
+
|
|
74
|
+
_dict = self.model_dump(
|
|
75
|
+
by_alias=True,
|
|
76
|
+
exclude=excluded_fields,
|
|
77
|
+
exclude_none=True,
|
|
78
|
+
)
|
|
79
|
+
return _dict
|
|
80
|
+
|
|
81
|
+
@classmethod
|
|
82
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
83
|
+
"""Create an instance of UrlImageContentValueType from a dict"""
|
|
84
|
+
if obj is None:
|
|
85
|
+
return None
|
|
86
|
+
|
|
87
|
+
if not isinstance(obj, dict):
|
|
88
|
+
return cls.model_validate(obj)
|
|
89
|
+
|
|
90
|
+
_obj = cls.model_validate({
|
|
91
|
+
"type": obj.get("type"),
|
|
92
|
+
"url": obj.get("url")
|
|
93
|
+
})
|
|
94
|
+
return _obj
|
|
95
|
+
|
|
96
|
+
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Adaline API
|
|
5
|
+
|
|
6
|
+
API for managing Adaline deployments, logs, and core type definitions.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class UrlMedia(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
UrlMedia
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
type: StrictStr = Field(description="Indicates this is a URL-based media object")
|
|
30
|
+
url: StrictStr = Field(description="The URL pointing to the media")
|
|
31
|
+
additional_properties: Dict[str, Any] = {}
|
|
32
|
+
__properties: ClassVar[List[str]] = ["type", "url"]
|
|
33
|
+
|
|
34
|
+
@field_validator('type')
|
|
35
|
+
def type_validate_enum(cls, value):
|
|
36
|
+
"""Validates the enum"""
|
|
37
|
+
if value not in set(['url']):
|
|
38
|
+
raise ValueError("must be one of enum values ('url')")
|
|
39
|
+
return value
|
|
40
|
+
|
|
41
|
+
model_config = ConfigDict(
|
|
42
|
+
populate_by_name=True,
|
|
43
|
+
validate_assignment=True,
|
|
44
|
+
protected_namespaces=(),
|
|
45
|
+
)
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
def to_str(self) -> str:
|
|
49
|
+
"""Returns the string representation of the model using alias"""
|
|
50
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
51
|
+
|
|
52
|
+
def to_json(self) -> str:
|
|
53
|
+
"""Returns the JSON representation of the model using alias"""
|
|
54
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
55
|
+
return json.dumps(self.to_dict())
|
|
56
|
+
|
|
57
|
+
@classmethod
|
|
58
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
59
|
+
"""Create an instance of UrlMedia from a JSON string"""
|
|
60
|
+
return cls.from_dict(json.loads(json_str))
|
|
61
|
+
|
|
62
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
63
|
+
"""Return the dictionary representation of the model using alias.
|
|
64
|
+
|
|
65
|
+
This has the following differences from calling pydantic's
|
|
66
|
+
`self.model_dump(by_alias=True)`:
|
|
67
|
+
|
|
68
|
+
* `None` is only added to the output dict for nullable fields that
|
|
69
|
+
were set at model initialization. Other fields with value `None`
|
|
70
|
+
are ignored.
|
|
71
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
72
|
+
"""
|
|
73
|
+
excluded_fields: Set[str] = set([
|
|
74
|
+
"additional_properties",
|
|
75
|
+
])
|
|
76
|
+
|
|
77
|
+
_dict = self.model_dump(
|
|
78
|
+
by_alias=True,
|
|
79
|
+
exclude=excluded_fields,
|
|
80
|
+
exclude_none=True,
|
|
81
|
+
)
|
|
82
|
+
# puts key-value pairs in additional_properties in the top level
|
|
83
|
+
if self.additional_properties is not None:
|
|
84
|
+
for _key, _value in self.additional_properties.items():
|
|
85
|
+
_dict[_key] = _value
|
|
86
|
+
|
|
87
|
+
return _dict
|
|
88
|
+
|
|
89
|
+
@classmethod
|
|
90
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
91
|
+
"""Create an instance of UrlMedia from a dict"""
|
|
92
|
+
if obj is None:
|
|
93
|
+
return None
|
|
94
|
+
|
|
95
|
+
if not isinstance(obj, dict):
|
|
96
|
+
return cls.model_validate(obj)
|
|
97
|
+
|
|
98
|
+
_obj = cls.model_validate({
|
|
99
|
+
"type": obj.get("type"),
|
|
100
|
+
"url": obj.get("url")
|
|
101
|
+
})
|
|
102
|
+
# store additional fields in additional_properties
|
|
103
|
+
for _key in obj.keys():
|
|
104
|
+
if _key not in cls.__properties:
|
|
105
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
106
|
+
|
|
107
|
+
return _obj
|
|
108
|
+
|
|
109
|
+
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Adaline API
|
|
5
|
+
|
|
6
|
+
API for managing Adaline deployments, logs, and core type definitions.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class UrlMediaType(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
UrlMediaType
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
type: StrictStr = Field(description="Indicates this is a URL-based media object")
|
|
30
|
+
url: StrictStr = Field(description="The URL pointing to the media")
|
|
31
|
+
additional_properties: Dict[str, Any] = {}
|
|
32
|
+
__properties: ClassVar[List[str]] = ["type", "url"]
|
|
33
|
+
|
|
34
|
+
@field_validator('type')
|
|
35
|
+
def type_validate_enum(cls, value):
|
|
36
|
+
"""Validates the enum"""
|
|
37
|
+
if value not in set(['url']):
|
|
38
|
+
raise ValueError("must be one of enum values ('url')")
|
|
39
|
+
return value
|
|
40
|
+
|
|
41
|
+
model_config = ConfigDict(
|
|
42
|
+
populate_by_name=True,
|
|
43
|
+
validate_assignment=True,
|
|
44
|
+
protected_namespaces=(),
|
|
45
|
+
)
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
def to_str(self) -> str:
|
|
49
|
+
"""Returns the string representation of the model using alias"""
|
|
50
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
51
|
+
|
|
52
|
+
def to_json(self) -> str:
|
|
53
|
+
"""Returns the JSON representation of the model using alias"""
|
|
54
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
55
|
+
return json.dumps(self.to_dict())
|
|
56
|
+
|
|
57
|
+
@classmethod
|
|
58
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
59
|
+
"""Create an instance of UrlMediaType from a JSON string"""
|
|
60
|
+
return cls.from_dict(json.loads(json_str))
|
|
61
|
+
|
|
62
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
63
|
+
"""Return the dictionary representation of the model using alias.
|
|
64
|
+
|
|
65
|
+
This has the following differences from calling pydantic's
|
|
66
|
+
`self.model_dump(by_alias=True)`:
|
|
67
|
+
|
|
68
|
+
* `None` is only added to the output dict for nullable fields that
|
|
69
|
+
were set at model initialization. Other fields with value `None`
|
|
70
|
+
are ignored.
|
|
71
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
72
|
+
"""
|
|
73
|
+
excluded_fields: Set[str] = set([
|
|
74
|
+
"additional_properties",
|
|
75
|
+
])
|
|
76
|
+
|
|
77
|
+
_dict = self.model_dump(
|
|
78
|
+
by_alias=True,
|
|
79
|
+
exclude=excluded_fields,
|
|
80
|
+
exclude_none=True,
|
|
81
|
+
)
|
|
82
|
+
# puts key-value pairs in additional_properties in the top level
|
|
83
|
+
if self.additional_properties is not None:
|
|
84
|
+
for _key, _value in self.additional_properties.items():
|
|
85
|
+
_dict[_key] = _value
|
|
86
|
+
|
|
87
|
+
return _dict
|
|
88
|
+
|
|
89
|
+
@classmethod
|
|
90
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
91
|
+
"""Create an instance of UrlMediaType from a dict"""
|
|
92
|
+
if obj is None:
|
|
93
|
+
return None
|
|
94
|
+
|
|
95
|
+
if not isinstance(obj, dict):
|
|
96
|
+
return cls.model_validate(obj)
|
|
97
|
+
|
|
98
|
+
_obj = cls.model_validate({
|
|
99
|
+
"type": obj.get("type"),
|
|
100
|
+
"url": obj.get("url")
|
|
101
|
+
})
|
|
102
|
+
# store additional fields in additional_properties
|
|
103
|
+
for _key in obj.keys():
|
|
104
|
+
if _key not in cls.__properties:
|
|
105
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
106
|
+
|
|
107
|
+
return _obj
|
|
108
|
+
|
|
109
|
+
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Adaline API
|
|
5
|
+
|
|
6
|
+
API for managing Adaline deployments, logs, and core type definitions.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class UrlPdfContentValue(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
URL reference to an externally hosted PDF document
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
type: StrictStr
|
|
30
|
+
url: StrictStr
|
|
31
|
+
__properties: ClassVar[List[str]] = ["type", "url"]
|
|
32
|
+
|
|
33
|
+
@field_validator('type')
|
|
34
|
+
def type_validate_enum(cls, value):
|
|
35
|
+
"""Validates the enum"""
|
|
36
|
+
if value not in set(['url']):
|
|
37
|
+
raise ValueError("must be one of enum values ('url')")
|
|
38
|
+
return value
|
|
39
|
+
|
|
40
|
+
model_config = ConfigDict(
|
|
41
|
+
populate_by_name=True,
|
|
42
|
+
validate_assignment=True,
|
|
43
|
+
protected_namespaces=(),
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
def to_str(self) -> str:
|
|
48
|
+
"""Returns the string representation of the model using alias"""
|
|
49
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
50
|
+
|
|
51
|
+
def to_json(self) -> str:
|
|
52
|
+
"""Returns the JSON representation of the model using alias"""
|
|
53
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
54
|
+
return json.dumps(self.to_dict())
|
|
55
|
+
|
|
56
|
+
@classmethod
|
|
57
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
58
|
+
"""Create an instance of UrlPdfContentValue from a JSON string"""
|
|
59
|
+
return cls.from_dict(json.loads(json_str))
|
|
60
|
+
|
|
61
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
62
|
+
"""Return the dictionary representation of the model using alias.
|
|
63
|
+
|
|
64
|
+
This has the following differences from calling pydantic's
|
|
65
|
+
`self.model_dump(by_alias=True)`:
|
|
66
|
+
|
|
67
|
+
* `None` is only added to the output dict for nullable fields that
|
|
68
|
+
were set at model initialization. Other fields with value `None`
|
|
69
|
+
are ignored.
|
|
70
|
+
"""
|
|
71
|
+
excluded_fields: Set[str] = set([
|
|
72
|
+
])
|
|
73
|
+
|
|
74
|
+
_dict = self.model_dump(
|
|
75
|
+
by_alias=True,
|
|
76
|
+
exclude=excluded_fields,
|
|
77
|
+
exclude_none=True,
|
|
78
|
+
)
|
|
79
|
+
return _dict
|
|
80
|
+
|
|
81
|
+
@classmethod
|
|
82
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
83
|
+
"""Create an instance of UrlPdfContentValue from a dict"""
|
|
84
|
+
if obj is None:
|
|
85
|
+
return None
|
|
86
|
+
|
|
87
|
+
if not isinstance(obj, dict):
|
|
88
|
+
return cls.model_validate(obj)
|
|
89
|
+
|
|
90
|
+
_obj = cls.model_validate({
|
|
91
|
+
"type": obj.get("type"),
|
|
92
|
+
"url": obj.get("url")
|
|
93
|
+
})
|
|
94
|
+
return _obj
|
|
95
|
+
|
|
96
|
+
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Adaline API
|
|
5
|
+
|
|
6
|
+
API for managing Adaline deployments, logs, and core type definitions.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, StrictStr, field_validator
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class UrlPdfContentValueType(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
UrlPdfContentValueType
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
type: StrictStr
|
|
30
|
+
url: StrictStr
|
|
31
|
+
__properties: ClassVar[List[str]] = ["type", "url"]
|
|
32
|
+
|
|
33
|
+
@field_validator('type')
|
|
34
|
+
def type_validate_enum(cls, value):
|
|
35
|
+
"""Validates the enum"""
|
|
36
|
+
if value not in set(['url']):
|
|
37
|
+
raise ValueError("must be one of enum values ('url')")
|
|
38
|
+
return value
|
|
39
|
+
|
|
40
|
+
model_config = ConfigDict(
|
|
41
|
+
populate_by_name=True,
|
|
42
|
+
validate_assignment=True,
|
|
43
|
+
protected_namespaces=(),
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
def to_str(self) -> str:
|
|
48
|
+
"""Returns the string representation of the model using alias"""
|
|
49
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
50
|
+
|
|
51
|
+
def to_json(self) -> str:
|
|
52
|
+
"""Returns the JSON representation of the model using alias"""
|
|
53
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
54
|
+
return json.dumps(self.to_dict())
|
|
55
|
+
|
|
56
|
+
@classmethod
|
|
57
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
58
|
+
"""Create an instance of UrlPdfContentValueType from a JSON string"""
|
|
59
|
+
return cls.from_dict(json.loads(json_str))
|
|
60
|
+
|
|
61
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
62
|
+
"""Return the dictionary representation of the model using alias.
|
|
63
|
+
|
|
64
|
+
This has the following differences from calling pydantic's
|
|
65
|
+
`self.model_dump(by_alias=True)`:
|
|
66
|
+
|
|
67
|
+
* `None` is only added to the output dict for nullable fields that
|
|
68
|
+
were set at model initialization. Other fields with value `None`
|
|
69
|
+
are ignored.
|
|
70
|
+
"""
|
|
71
|
+
excluded_fields: Set[str] = set([
|
|
72
|
+
])
|
|
73
|
+
|
|
74
|
+
_dict = self.model_dump(
|
|
75
|
+
by_alias=True,
|
|
76
|
+
exclude=excluded_fields,
|
|
77
|
+
exclude_none=True,
|
|
78
|
+
)
|
|
79
|
+
return _dict
|
|
80
|
+
|
|
81
|
+
@classmethod
|
|
82
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
83
|
+
"""Create an instance of UrlPdfContentValueType from a dict"""
|
|
84
|
+
if obj is None:
|
|
85
|
+
return None
|
|
86
|
+
|
|
87
|
+
if not isinstance(obj, dict):
|
|
88
|
+
return cls.model_validate(obj)
|
|
89
|
+
|
|
90
|
+
_obj = cls.model_validate({
|
|
91
|
+
"type": obj.get("type"),
|
|
92
|
+
"url": obj.get("url")
|
|
93
|
+
})
|
|
94
|
+
return _obj
|
|
95
|
+
|
|
96
|
+
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Adaline API
|
|
5
|
+
|
|
6
|
+
API for managing Adaline deployments, logs, and core type definitions.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from typing_extensions import Annotated
|
|
23
|
+
from adaline_api.models.variable_value import VariableValue
|
|
24
|
+
from typing import Optional, Set
|
|
25
|
+
from typing_extensions import Self
|
|
26
|
+
|
|
27
|
+
class Variable(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
Prompt variable definition with name, multi-modal value, and optional description
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
name: Annotated[str, Field(min_length=1, strict=True, max_length=200)] = Field(description="The name of the variable")
|
|
32
|
+
value: VariableValue
|
|
33
|
+
description: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=200)]] = Field(default=None, description="Optional description of the variable")
|
|
34
|
+
__properties: ClassVar[List[str]] = ["name", "value", "description"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def to_str(self) -> str:
|
|
44
|
+
"""Returns the string representation of the model using alias"""
|
|
45
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
46
|
+
|
|
47
|
+
def to_json(self) -> str:
|
|
48
|
+
"""Returns the JSON representation of the model using alias"""
|
|
49
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
50
|
+
return json.dumps(self.to_dict())
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of Variable from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
"""
|
|
67
|
+
excluded_fields: Set[str] = set([
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
# override the default output from pydantic by calling `to_dict()` of value
|
|
76
|
+
if self.value:
|
|
77
|
+
_dict['value'] = self.value.to_dict()
|
|
78
|
+
return _dict
|
|
79
|
+
|
|
80
|
+
@classmethod
|
|
81
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
82
|
+
"""Create an instance of Variable from a dict"""
|
|
83
|
+
if obj is None:
|
|
84
|
+
return None
|
|
85
|
+
|
|
86
|
+
if not isinstance(obj, dict):
|
|
87
|
+
return cls.model_validate(obj)
|
|
88
|
+
|
|
89
|
+
_obj = cls.model_validate({
|
|
90
|
+
"name": obj.get("name"),
|
|
91
|
+
"value": VariableValue.from_dict(obj["value"]) if obj.get("value") is not None else None,
|
|
92
|
+
"description": obj.get("description")
|
|
93
|
+
})
|
|
94
|
+
return _obj
|
|
95
|
+
|
|
96
|
+
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Adaline API
|
|
5
|
+
|
|
6
|
+
API for managing Adaline deployments, logs, and core type definitions.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from typing_extensions import Annotated
|
|
23
|
+
from adaline_api.models.variable_type_value import VariableTypeValue
|
|
24
|
+
from typing import Optional, Set
|
|
25
|
+
from typing_extensions import Self
|
|
26
|
+
|
|
27
|
+
class VariableType(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
VariableType
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
name: Annotated[str, Field(min_length=1, strict=True, max_length=200)] = Field(description="The name of the variable")
|
|
32
|
+
value: VariableTypeValue
|
|
33
|
+
description: Optional[Annotated[str, Field(min_length=1, strict=True, max_length=200)]] = Field(default=None, description="Optional description of the variable")
|
|
34
|
+
__properties: ClassVar[List[str]] = ["name", "value", "description"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def to_str(self) -> str:
|
|
44
|
+
"""Returns the string representation of the model using alias"""
|
|
45
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
46
|
+
|
|
47
|
+
def to_json(self) -> str:
|
|
48
|
+
"""Returns the JSON representation of the model using alias"""
|
|
49
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
50
|
+
return json.dumps(self.to_dict())
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of VariableType from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
"""
|
|
67
|
+
excluded_fields: Set[str] = set([
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
# override the default output from pydantic by calling `to_dict()` of value
|
|
76
|
+
if self.value:
|
|
77
|
+
_dict['value'] = self.value.to_dict()
|
|
78
|
+
return _dict
|
|
79
|
+
|
|
80
|
+
@classmethod
|
|
81
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
82
|
+
"""Create an instance of VariableType from a dict"""
|
|
83
|
+
if obj is None:
|
|
84
|
+
return None
|
|
85
|
+
|
|
86
|
+
if not isinstance(obj, dict):
|
|
87
|
+
return cls.model_validate(obj)
|
|
88
|
+
|
|
89
|
+
_obj = cls.model_validate({
|
|
90
|
+
"name": obj.get("name"),
|
|
91
|
+
"value": VariableTypeValue.from_dict(obj["value"]) if obj.get("value") is not None else None,
|
|
92
|
+
"description": obj.get("description")
|
|
93
|
+
})
|
|
94
|
+
return _obj
|
|
95
|
+
|
|
96
|
+
|