airia 0.1.6__py3-none-any.whl → 0.1.8__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.
- airia/client/base_client.py +1 -1
- airia/types/api/get_pipeline_config.py +138 -53
- {airia-0.1.6.dist-info → airia-0.1.8.dist-info}/METADATA +2 -6
- {airia-0.1.6.dist-info → airia-0.1.8.dist-info}/RECORD +7 -7
- {airia-0.1.6.dist-info → airia-0.1.8.dist-info}/WHEEL +0 -0
- {airia-0.1.6.dist-info → airia-0.1.8.dist-info}/licenses/LICENSE +0 -0
- {airia-0.1.6.dist-info → airia-0.1.8.dist-info}/top_level.txt +0 -0
airia/client/base_client.py
CHANGED
|
@@ -212,7 +212,7 @@ class AiriaBaseClient:
|
|
|
212
212
|
raise ValueError(
|
|
213
213
|
f"Invalid API version: {api_version}. Valid versions are: {', '.join(ApiVersion.as_list())}"
|
|
214
214
|
)
|
|
215
|
-
url = urljoin(self.base_url, f"{api_version}/PipelinesConfig/{pipeline_id}")
|
|
215
|
+
url = urljoin(self.base_url, f"{api_version}/PipelinesConfig/export/{pipeline_id}")
|
|
216
216
|
request_data = self._prepare_request(url, correlation_id=correlation_id)
|
|
217
217
|
|
|
218
218
|
return request_data
|
|
@@ -1,65 +1,150 @@
|
|
|
1
|
-
from datetime import datetime
|
|
2
1
|
from typing import Any, Dict, List, Optional
|
|
3
2
|
|
|
4
3
|
from pydantic import BaseModel, Field
|
|
5
4
|
|
|
6
5
|
|
|
7
|
-
class
|
|
8
|
-
pipeline_id: str = Field(alias="pipelineId")
|
|
9
|
-
major_version: int = Field(alias="majorVersion")
|
|
10
|
-
minor_version: int = Field(alias="minorVersion")
|
|
11
|
-
version_number: str = Field(alias="versionNumber")
|
|
12
|
-
is_draft_version: bool = Field(alias="isDraftVersion")
|
|
13
|
-
is_latest: bool = Field(alias="isLatest")
|
|
14
|
-
steps: Optional[List[Dict[str, Any]]] = None
|
|
15
|
-
alignment: str
|
|
6
|
+
class Metadata(BaseModel):
|
|
16
7
|
id: str
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
8
|
+
export_version: str = Field(alias="exportVersion")
|
|
9
|
+
tagline: Optional[str] = None
|
|
10
|
+
agent_description: Optional[str] = Field(alias="agentDescription", default=None)
|
|
11
|
+
industry: Optional[str] = None
|
|
12
|
+
tasks: Optional[str] = None
|
|
13
|
+
credential_export_option: str = Field(alias="credentialExportOption")
|
|
14
|
+
data_source_export_option: str = Field(alias="dataSourceExportOption")
|
|
15
|
+
version_information: str = Field(alias="versionInformation")
|
|
16
|
+
state: str
|
|
22
17
|
|
|
23
18
|
|
|
24
|
-
class
|
|
25
|
-
|
|
26
|
-
|
|
19
|
+
class Agent(BaseModel):
|
|
20
|
+
name: str
|
|
21
|
+
execution_name: str = Field(alias="executionName")
|
|
22
|
+
agent_description: Optional[str] = Field(alias="agentDescription", default=None)
|
|
23
|
+
video_link: Optional[str] = Field(alias="videoLink", default=None)
|
|
24
|
+
industry: Optional[str] = None
|
|
25
|
+
sub_industries: List[str] = Field(alias="subIndustries", default_factory=list)
|
|
26
|
+
agent_details: Dict[str, Any] = Field(alias="agentDetails", default_factory=dict)
|
|
27
|
+
id: str
|
|
28
|
+
agent_icon: Optional[str] = Field(alias="agentIcon", default=None)
|
|
29
|
+
steps: List[Dict[str, Any]]
|
|
27
30
|
|
|
28
31
|
|
|
29
|
-
class
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
agent_icon: Optional[str] = Field(alias="agentIcon")
|
|
36
|
-
external: bool
|
|
37
|
-
active_version_id: str = Field(alias="activeVersionId")
|
|
32
|
+
class PromptMessage(BaseModel):
|
|
33
|
+
text: str
|
|
34
|
+
order: int
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
class Prompt(BaseModel):
|
|
38
38
|
name: str
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
library_imported_version: Optional[str] = Field(alias="libraryImportedVersion")
|
|
55
|
-
is_deleted: Optional[bool] = Field(alias="isDeleted")
|
|
56
|
-
agent_trigger: Optional[Any] = Field(alias="agentTrigger")
|
|
57
|
-
api_key_id: Optional[str] = Field(alias="apiKeyId")
|
|
58
|
-
is_seeded: bool = Field(alias="isSeeded")
|
|
59
|
-
behaviours: List[Any]
|
|
39
|
+
version_change_description: str = Field(alias="versionChangeDescription")
|
|
40
|
+
prompt_message_list: List[PromptMessage] = Field(alias="promptMessageList")
|
|
41
|
+
id: str
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
class CredentialData(BaseModel):
|
|
45
|
+
key: str
|
|
46
|
+
value: str
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
class CredentialsDefinition(BaseModel):
|
|
50
|
+
name: str
|
|
51
|
+
credential_type: str = Field(alias="credentialType")
|
|
52
|
+
source_type: str = Field(alias="sourceType")
|
|
53
|
+
credential_data_list: List[CredentialData] = Field(alias="credentialDataList")
|
|
60
54
|
id: str
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
class HeaderDefinition(BaseModel):
|
|
58
|
+
key: str
|
|
59
|
+
value: str
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
class ParameterDefinition(BaseModel):
|
|
63
|
+
name: str
|
|
64
|
+
parameter_type: str = Field(alias="parameterType")
|
|
65
|
+
parameter_description: str = Field(alias="parameterDescription")
|
|
66
|
+
default: str
|
|
67
|
+
valid_options: List[str] = Field(alias="validOptions", default_factory=list)
|
|
68
|
+
id: str
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
class Tool(BaseModel):
|
|
72
|
+
tool_type: str = Field(alias="toolType")
|
|
73
|
+
name: str
|
|
74
|
+
standardized_name: str = Field(alias="standardizedName")
|
|
75
|
+
tool_description: str = Field(alias="toolDescription")
|
|
76
|
+
purpose: str
|
|
77
|
+
api_endpoint: str = Field(alias="apiEndpoint")
|
|
78
|
+
credentials_definition: Optional[CredentialsDefinition] = Field(
|
|
79
|
+
alias="credentialsDefinition"
|
|
80
|
+
)
|
|
81
|
+
headers_definition: List[HeaderDefinition] = Field(alias="headersDefinition")
|
|
82
|
+
body: str
|
|
83
|
+
parameters_definition: List[ParameterDefinition] = Field(
|
|
84
|
+
alias="parametersDefinition"
|
|
85
|
+
)
|
|
86
|
+
method_type: str = Field(alias="methodType")
|
|
87
|
+
route_through_acc: bool = Field(alias="routeThroughACC")
|
|
88
|
+
use_user_credentials: bool = Field(alias="useUserCredentials")
|
|
89
|
+
use_user_credentials_type: str = Field(alias="useUserCredentialsType")
|
|
90
|
+
id: str
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
class Model(BaseModel):
|
|
94
|
+
id: str
|
|
95
|
+
display_name: str = Field(alias="displayName")
|
|
96
|
+
model_name: str = Field(alias="modelName")
|
|
97
|
+
prompt_id: Optional[str] = Field(alias="promptId", default=None)
|
|
98
|
+
system_prompt_definition: Optional[Any] = Field(
|
|
99
|
+
alias="systemPromptDefinition", default=None
|
|
100
|
+
)
|
|
101
|
+
url: str
|
|
102
|
+
input_type: str = Field(alias="inputType")
|
|
103
|
+
provider: str
|
|
104
|
+
credentials_definition: CredentialsDefinition = Field(alias="credentialsDefinition")
|
|
105
|
+
deployment_type: str = Field(alias="deploymentType")
|
|
106
|
+
source_type: str = Field(alias="sourceType")
|
|
107
|
+
connection_string: Optional[str] = Field(alias="connectionString", default=None)
|
|
108
|
+
container_name: Optional[str] = Field(alias="containerName", default=None)
|
|
109
|
+
deployed_key: Optional[str] = Field(alias="deployedKey", default=None)
|
|
110
|
+
deployed_url: Optional[str] = Field(alias="deployedUrl", default=None)
|
|
111
|
+
state: Optional[str] = None
|
|
112
|
+
uploaded_container_id: Optional[str] = Field(
|
|
113
|
+
alias="uploadedContainerId", default=None
|
|
114
|
+
)
|
|
115
|
+
library_model_id: Optional[str] = Field(alias="libraryModelId")
|
|
116
|
+
input_token_price: str = Field(alias="inputTokenPrice")
|
|
117
|
+
output_token_price: str = Field(alias="outputTokenPrice")
|
|
118
|
+
token_units: int = Field(alias="tokenUnits")
|
|
119
|
+
has_tool_support: bool = Field(alias="hasToolSupport")
|
|
120
|
+
allow_airia_credentials: bool = Field(alias="allowAiriaCredentials")
|
|
121
|
+
allow_byok_credentials: bool = Field(alias="allowBYOKCredentials")
|
|
122
|
+
author: Optional[str]
|
|
123
|
+
price_type: str = Field(alias="priceType")
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
class PythonCodeBlock(BaseModel):
|
|
127
|
+
id: str
|
|
128
|
+
code: str
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
class Router(BaseModel):
|
|
132
|
+
id: str
|
|
133
|
+
model_id: str = Field(alias="modelId")
|
|
134
|
+
model: Optional[Any] = None
|
|
135
|
+
router_config: Dict[str, Dict[str, Any]] = Field(alias="routerConfig")
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
class GetPipelineConfigResponse(BaseModel):
|
|
139
|
+
metadata: Metadata
|
|
140
|
+
agent: Agent
|
|
141
|
+
data_sources: Optional[List[Any]] = Field(alias="dataSources", default_factory=list)
|
|
142
|
+
prompts: Optional[List[Prompt]] = Field(default_factory=list)
|
|
143
|
+
tools: Optional[List[Tool]] = Field(default_factory=list)
|
|
144
|
+
models: Optional[List[Model]] = Field(default_factory=list)
|
|
145
|
+
memories: Optional[Any] = None
|
|
146
|
+
python_code_blocks: Optional[List[PythonCodeBlock]] = Field(
|
|
147
|
+
alias="pythonCodeBlocks", default_factory=list
|
|
148
|
+
)
|
|
149
|
+
routers: Optional[List[Router]] = Field(default_factory=list)
|
|
150
|
+
deployment: Optional[Any] = None
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: airia
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.8
|
|
4
4
|
Summary: Python SDK for Airia API
|
|
5
5
|
Author-email: Airia LLC <support@airia.com>
|
|
6
6
|
License: MIT
|
|
@@ -348,11 +348,7 @@ client = AiriaClient(api_key="your_api_key")
|
|
|
348
348
|
config = client.get_pipeline_config(pipeline_id="your_pipeline_id")
|
|
349
349
|
|
|
350
350
|
# Access configuration details
|
|
351
|
-
print(f"Pipeline Name: {config.
|
|
352
|
-
print(f"Description: {config.deployment_description}")
|
|
353
|
-
print(f"Active Version: {config.active_version.version_number}")
|
|
354
|
-
print(f"Success Count: {config.execution_stats.success_count}")
|
|
355
|
-
print(f"Failure Count: {config.execution_stats.failure_count}")
|
|
351
|
+
print(f"Pipeline Name: {config.agent.name}")
|
|
356
352
|
```
|
|
357
353
|
|
|
358
354
|
## Gateway Usage
|
|
@@ -3,17 +3,17 @@ airia/exceptions.py,sha256=4Z55n-cRJrtTa5-pZBIK2oZD4-Z99aUtKx_kfTFYY5o,1146
|
|
|
3
3
|
airia/logs.py,sha256=17YZ4IuzOF0m5bgofj9-QYlJ2BYR2kRZbBVQfFSLFEk,5441
|
|
4
4
|
airia/client/__init__.py,sha256=6gSQ9bl7j79q1HPE0o5py3IRdkwWWuU_7J4h05Dd2o8,127
|
|
5
5
|
airia/client/async_client.py,sha256=QtnH1MNfF_ONx2YHsTz7Y4pFBTrggHWz0LLJiITREwc,23694
|
|
6
|
-
airia/client/base_client.py,sha256=
|
|
6
|
+
airia/client/base_client.py,sha256=YWhQle7cmtiuc5BwiavW-NYjTC6kXyclpse4irwkMuI,7969
|
|
7
7
|
airia/client/sync_client.py,sha256=iUqRn7Bv5hi-Qcg3Vgfc-Z1gx5T42f9Vq4pUTPsyG5M,22750
|
|
8
8
|
airia/types/__init__.py,sha256=s6_uMrrKzhk2wg1lpaRRIl4AQ8hUxKbCNLfz-VK7tAs,2166
|
|
9
9
|
airia/types/api_version.py,sha256=Uzom6O2ZG92HN_Z2h-lTydmO2XYX9RVs4Yi4DJmXytE,255
|
|
10
10
|
airia/types/request_data.py,sha256=m8lBwFliK2_kZU2TgeLdhiO_7v826lVRhA5_8NYB_NM,206
|
|
11
11
|
airia/types/sse_messages.py,sha256=wSdowY07AjEO8R73SJrFPJtkfIBS4satUpNytjKQq2U,8305
|
|
12
|
-
airia/types/api/get_pipeline_config.py,sha256=
|
|
12
|
+
airia/types/api/get_pipeline_config.py,sha256=HAKgcpiJKeG_TuWtxo28CeWiodhlsVBwgbpzDgd1Eoo,5401
|
|
13
13
|
airia/types/api/pipeline_execution.py,sha256=4zGM5W4aXiAibAdgWQCIZBC_blW6QYAlAHoVUMbnCF0,752
|
|
14
14
|
airia/utils/sse_parser.py,sha256=h3TcBvXqUIngTqgY6yYxZCGLnC1eI6meQzYr13aFAb8,2791
|
|
15
|
-
airia-0.1.
|
|
16
|
-
airia-0.1.
|
|
17
|
-
airia-0.1.
|
|
18
|
-
airia-0.1.
|
|
19
|
-
airia-0.1.
|
|
15
|
+
airia-0.1.8.dist-info/licenses/LICENSE,sha256=R3ClUMMKPRItIcZ0svzyj2taZZnFYw568YDNzN9KQ1Q,1066
|
|
16
|
+
airia-0.1.8.dist-info/METADATA,sha256=Toz3tWc8psnI2QbUrhjfzomljqp5BSrlaJH11mohHos,13218
|
|
17
|
+
airia-0.1.8.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
18
|
+
airia-0.1.8.dist-info/top_level.txt,sha256=qUQEKfs_hdOYTwjKj1JZbRhS5YeXDNaKQaVTrzabS6w,6
|
|
19
|
+
airia-0.1.8.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|