beamlit 0.0.56rc106__py3-none-any.whl → 0.0.57__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.
- beamlit/agents/chain.py +0 -2
- beamlit/agents/chat.py +20 -8
- beamlit/agents/decorator.py +112 -99
- beamlit/agents/thread.py +5 -9
- beamlit/api/agents/delete_agent.py +1 -22
- beamlit/api/agents/get_agent.py +1 -22
- beamlit/api/agents/get_agent_metrics.py +13 -34
- beamlit/api/agents/get_agent_trace_ids.py +44 -14
- beamlit/api/agents/{list_agent_history.py → list_agent_revisions.py} +21 -17
- beamlit/api/agents/list_agents.py +4 -36
- beamlit/api/default/get_trace_ids.py +0 -15
- beamlit/api/default/list_mcp_hub_definitions.py +12 -12
- beamlit/api/functions/delete_function.py +1 -22
- beamlit/api/functions/get_function.py +1 -22
- beamlit/api/functions/get_function_metrics.py +13 -34
- beamlit/api/functions/get_function_trace_ids.py +44 -14
- beamlit/api/functions/{create_function_release.py → list_function_revisions.py} +26 -18
- beamlit/api/functions/list_functions.py +4 -36
- beamlit/api/knowledgebases/create_knowledgebase.py +4 -4
- beamlit/api/knowledgebases/delete_knowledgebase.py +5 -26
- beamlit/api/knowledgebases/get_knowledgebase.py +1 -22
- beamlit/api/{environments/get_environment_metrics.py → knowledgebases/list_knowledgebase_revisions.py} +34 -34
- beamlit/api/knowledgebases/list_knowledgebases.py +4 -36
- beamlit/api/models/create_model.py +4 -8
- beamlit/api/models/delete_model.py +1 -22
- beamlit/api/models/get_model.py +1 -22
- beamlit/api/models/get_model_metrics.py +13 -34
- beamlit/api/models/get_model_trace_ids.py +44 -14
- beamlit/api/models/{release_model.py → list_model_revisions.py} +26 -22
- beamlit/api/models/list_models.py +4 -36
- beamlit/api/models/update_model.py +4 -8
- beamlit/authentication/authentication.py +11 -8
- beamlit/authentication/clientcredentials.py +15 -28
- beamlit/authentication/credentials.py +2 -7
- beamlit/common/settings.py +1 -4
- beamlit/deploy/deploy.py +15 -9
- beamlit/functions/common.py +16 -16
- beamlit/functions/local/local.py +4 -5
- beamlit/functions/mcp/client.py +96 -0
- beamlit/functions/mcp/mcp.py +56 -43
- beamlit/functions/remote/remote.py +9 -11
- beamlit/models/__init__.py +8 -38
- beamlit/models/agent.py +6 -6
- beamlit/models/function.py +6 -6
- beamlit/models/knowledgebase.py +6 -6
- beamlit/models/last_n_requests_metric.py +0 -9
- beamlit/models/model.py +7 -7
- beamlit/models/{resource_environment_metrics.py → resource_metrics.py} +20 -26
- beamlit/models/{resource_environment_metrics_request_total_per_code.py → resource_metrics_request_total_per_code.py} +5 -5
- beamlit/models/{resource_environment_metrics_rps_per_code.py → resource_metrics_rps_per_code.py} +5 -5
- beamlit/models/{model_release.py → revision_metadata.py} +20 -20
- beamlit/models/runtime.py +2 -2
- beamlit/models/workspace.py +0 -9
- beamlit/run.py +3 -7
- beamlit/serve/app.py +4 -8
- {beamlit-0.0.56rc106.dist-info → beamlit-0.0.57.dist-info}/METADATA +2 -1
- {beamlit-0.0.56rc106.dist-info → beamlit-0.0.57.dist-info}/RECORD +63 -91
- beamlit/api/agents/create_agent_release.py +0 -146
- beamlit/api/agents/delete_agent_history.py +0 -155
- beamlit/api/agents/get_agent_history.py +0 -155
- beamlit/api/agents/put_agent_history.py +0 -181
- beamlit/api/environments/__init__.py +0 -0
- beamlit/api/environments/create_environment.py +0 -167
- beamlit/api/environments/delete_environment.py +0 -154
- beamlit/api/environments/get_environment.py +0 -154
- beamlit/api/environments/list_environments.py +0 -139
- beamlit/api/environments/update_environment.py +0 -180
- beamlit/api/generation/__init__.py +0 -0
- beamlit/api/generation/run_information_generation_agent.py +0 -168
- beamlit/api/history/__init__.py +0 -0
- beamlit/api/history/get_agents_history.py +0 -155
- beamlit/api/history/list_agents_history.py +0 -131
- beamlit/models/agent_history.py +0 -167
- beamlit/models/agent_history_event.py +0 -133
- beamlit/models/agent_information_request.py +0 -63
- beamlit/models/agent_information_response.py +0 -79
- beamlit/models/agent_release.py +0 -70
- beamlit/models/environment.py +0 -96
- beamlit/models/environment_metadata.py +0 -148
- beamlit/models/environment_metrics.py +0 -77
- beamlit/models/environment_spec.py +0 -63
- beamlit/models/function_release.py +0 -70
- beamlit/models/knowledgebase_release.py +0 -70
- beamlit/models/mcp_hub_artifact.py +0 -188
- beamlit/models/mcp_hub_artifact_entrypoint.py +0 -45
- beamlit/models/mcp_hub_artifact_form.py +0 -45
- /beamlit/api/agents/{get_agent_environment_logs.py → get_agent_logs.py} +0 -0
- /beamlit/api/functions/{get_function_environment_logs.py → get_function_logs.py} +0 -0
- /beamlit/api/models/{get_model_environment_logs.py → get_model_logs.py} +0 -0
- {beamlit-0.0.56rc106.dist-info → beamlit-0.0.57.dist-info}/WHEEL +0 -0
- {beamlit-0.0.56rc106.dist-info → beamlit-0.0.57.dist-info}/entry_points.txt +0 -0
- {beamlit-0.0.56rc106.dist-info → beamlit-0.0.57.dist-info}/licenses/LICENSE +0 -0
@@ -1,79 +0,0 @@
|
|
1
|
-
from typing import Any, TypeVar, Union
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
T = TypeVar("T", bound="AgentInformationResponse")
|
9
|
-
|
10
|
-
|
11
|
-
@_attrs_define
|
12
|
-
class AgentInformationResponse:
|
13
|
-
"""generation agent information response
|
14
|
-
|
15
|
-
Attributes:
|
16
|
-
description (Union[Unset, str]): Description of the agent
|
17
|
-
display_name (Union[Unset, str]): Display name of the agent
|
18
|
-
prompt (Union[Unset, str]): Prompt of the agent
|
19
|
-
"""
|
20
|
-
|
21
|
-
description: Union[Unset, str] = UNSET
|
22
|
-
display_name: Union[Unset, str] = UNSET
|
23
|
-
prompt: Union[Unset, str] = UNSET
|
24
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
25
|
-
|
26
|
-
def to_dict(self) -> dict[str, Any]:
|
27
|
-
description = self.description
|
28
|
-
|
29
|
-
display_name = self.display_name
|
30
|
-
|
31
|
-
prompt = self.prompt
|
32
|
-
|
33
|
-
field_dict: dict[str, Any] = {}
|
34
|
-
field_dict.update(self.additional_properties)
|
35
|
-
field_dict.update({})
|
36
|
-
if description is not UNSET:
|
37
|
-
field_dict["description"] = description
|
38
|
-
if display_name is not UNSET:
|
39
|
-
field_dict["displayName"] = display_name
|
40
|
-
if prompt is not UNSET:
|
41
|
-
field_dict["prompt"] = prompt
|
42
|
-
|
43
|
-
return field_dict
|
44
|
-
|
45
|
-
@classmethod
|
46
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
47
|
-
if not src_dict:
|
48
|
-
return None
|
49
|
-
d = src_dict.copy()
|
50
|
-
description = d.pop("description", UNSET)
|
51
|
-
|
52
|
-
display_name = d.pop("displayName", UNSET)
|
53
|
-
|
54
|
-
prompt = d.pop("prompt", UNSET)
|
55
|
-
|
56
|
-
agent_information_response = cls(
|
57
|
-
description=description,
|
58
|
-
display_name=display_name,
|
59
|
-
prompt=prompt,
|
60
|
-
)
|
61
|
-
|
62
|
-
agent_information_response.additional_properties = d
|
63
|
-
return agent_information_response
|
64
|
-
|
65
|
-
@property
|
66
|
-
def additional_keys(self) -> list[str]:
|
67
|
-
return list(self.additional_properties.keys())
|
68
|
-
|
69
|
-
def __getitem__(self, key: str) -> Any:
|
70
|
-
return self.additional_properties[key]
|
71
|
-
|
72
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
73
|
-
self.additional_properties[key] = value
|
74
|
-
|
75
|
-
def __delitem__(self, key: str) -> None:
|
76
|
-
del self.additional_properties[key]
|
77
|
-
|
78
|
-
def __contains__(self, key: str) -> bool:
|
79
|
-
return key in self.additional_properties
|
beamlit/models/agent_release.py
DELETED
@@ -1,70 +0,0 @@
|
|
1
|
-
from typing import Any, TypeVar, Union
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
T = TypeVar("T", bound="AgentRelease")
|
9
|
-
|
10
|
-
|
11
|
-
@_attrs_define
|
12
|
-
class AgentRelease:
|
13
|
-
"""Agent release, used to deploy a agent from one environment to another
|
14
|
-
|
15
|
-
Attributes:
|
16
|
-
from_ (Union[Unset, str]): Origin environment from which the agent is released
|
17
|
-
to (Union[Unset, str]): Destination environment to which the agent is released
|
18
|
-
"""
|
19
|
-
|
20
|
-
from_: Union[Unset, str] = UNSET
|
21
|
-
to: Union[Unset, str] = UNSET
|
22
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
23
|
-
|
24
|
-
def to_dict(self) -> dict[str, Any]:
|
25
|
-
from_ = self.from_
|
26
|
-
|
27
|
-
to = self.to
|
28
|
-
|
29
|
-
field_dict: dict[str, Any] = {}
|
30
|
-
field_dict.update(self.additional_properties)
|
31
|
-
field_dict.update({})
|
32
|
-
if from_ is not UNSET:
|
33
|
-
field_dict["from"] = from_
|
34
|
-
if to is not UNSET:
|
35
|
-
field_dict["to"] = to
|
36
|
-
|
37
|
-
return field_dict
|
38
|
-
|
39
|
-
@classmethod
|
40
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
41
|
-
if not src_dict:
|
42
|
-
return None
|
43
|
-
d = src_dict.copy()
|
44
|
-
from_ = d.pop("from", UNSET)
|
45
|
-
|
46
|
-
to = d.pop("to", UNSET)
|
47
|
-
|
48
|
-
agent_release = cls(
|
49
|
-
from_=from_,
|
50
|
-
to=to,
|
51
|
-
)
|
52
|
-
|
53
|
-
agent_release.additional_properties = d
|
54
|
-
return agent_release
|
55
|
-
|
56
|
-
@property
|
57
|
-
def additional_keys(self) -> list[str]:
|
58
|
-
return list(self.additional_properties.keys())
|
59
|
-
|
60
|
-
def __getitem__(self, key: str) -> Any:
|
61
|
-
return self.additional_properties[key]
|
62
|
-
|
63
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
64
|
-
self.additional_properties[key] = value
|
65
|
-
|
66
|
-
def __delitem__(self, key: str) -> None:
|
67
|
-
del self.additional_properties[key]
|
68
|
-
|
69
|
-
def __contains__(self, key: str) -> bool:
|
70
|
-
return key in self.additional_properties
|
beamlit/models/environment.py
DELETED
@@ -1,96 +0,0 @@
|
|
1
|
-
from typing import TYPE_CHECKING, Any, TypeVar, Union
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
if TYPE_CHECKING:
|
9
|
-
from ..models.environment_spec import EnvironmentSpec
|
10
|
-
from ..models.metadata import Metadata
|
11
|
-
|
12
|
-
|
13
|
-
T = TypeVar("T", bound="Environment")
|
14
|
-
|
15
|
-
|
16
|
-
@_attrs_define
|
17
|
-
class Environment:
|
18
|
-
"""Environment on which deployments will be made (e.g. development, production), enforcing multiple policies at once.
|
19
|
-
|
20
|
-
Attributes:
|
21
|
-
metadata (Union[Unset, Metadata]): Metadata
|
22
|
-
spec (Union[Unset, EnvironmentSpec]): Environment specification
|
23
|
-
"""
|
24
|
-
|
25
|
-
metadata: Union[Unset, "Metadata"] = UNSET
|
26
|
-
spec: Union[Unset, "EnvironmentSpec"] = UNSET
|
27
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
28
|
-
|
29
|
-
def to_dict(self) -> dict[str, Any]:
|
30
|
-
metadata: Union[Unset, dict[str, Any]] = UNSET
|
31
|
-
if self.metadata and not isinstance(self.metadata, Unset) and not isinstance(self.metadata, dict):
|
32
|
-
metadata = self.metadata.to_dict()
|
33
|
-
elif self.metadata and isinstance(self.metadata, dict):
|
34
|
-
metadata = self.metadata
|
35
|
-
|
36
|
-
spec: Union[Unset, dict[str, Any]] = UNSET
|
37
|
-
if self.spec and not isinstance(self.spec, Unset) and not isinstance(self.spec, dict):
|
38
|
-
spec = self.spec.to_dict()
|
39
|
-
elif self.spec and isinstance(self.spec, dict):
|
40
|
-
spec = self.spec
|
41
|
-
|
42
|
-
field_dict: dict[str, Any] = {}
|
43
|
-
field_dict.update(self.additional_properties)
|
44
|
-
field_dict.update({})
|
45
|
-
if metadata is not UNSET:
|
46
|
-
field_dict["metadata"] = metadata
|
47
|
-
if spec is not UNSET:
|
48
|
-
field_dict["spec"] = spec
|
49
|
-
|
50
|
-
return field_dict
|
51
|
-
|
52
|
-
@classmethod
|
53
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
54
|
-
from ..models.environment_spec import EnvironmentSpec
|
55
|
-
from ..models.metadata import Metadata
|
56
|
-
|
57
|
-
if not src_dict:
|
58
|
-
return None
|
59
|
-
d = src_dict.copy()
|
60
|
-
_metadata = d.pop("metadata", UNSET)
|
61
|
-
metadata: Union[Unset, Metadata]
|
62
|
-
if isinstance(_metadata, Unset):
|
63
|
-
metadata = UNSET
|
64
|
-
else:
|
65
|
-
metadata = Metadata.from_dict(_metadata)
|
66
|
-
|
67
|
-
_spec = d.pop("spec", UNSET)
|
68
|
-
spec: Union[Unset, EnvironmentSpec]
|
69
|
-
if isinstance(_spec, Unset):
|
70
|
-
spec = UNSET
|
71
|
-
else:
|
72
|
-
spec = EnvironmentSpec.from_dict(_spec)
|
73
|
-
|
74
|
-
environment = cls(
|
75
|
-
metadata=metadata,
|
76
|
-
spec=spec,
|
77
|
-
)
|
78
|
-
|
79
|
-
environment.additional_properties = d
|
80
|
-
return environment
|
81
|
-
|
82
|
-
@property
|
83
|
-
def additional_keys(self) -> list[str]:
|
84
|
-
return list(self.additional_properties.keys())
|
85
|
-
|
86
|
-
def __getitem__(self, key: str) -> Any:
|
87
|
-
return self.additional_properties[key]
|
88
|
-
|
89
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
90
|
-
self.additional_properties[key] = value
|
91
|
-
|
92
|
-
def __delitem__(self, key: str) -> None:
|
93
|
-
del self.additional_properties[key]
|
94
|
-
|
95
|
-
def __contains__(self, key: str) -> bool:
|
96
|
-
return key in self.additional_properties
|
@@ -1,148 +0,0 @@
|
|
1
|
-
from typing import TYPE_CHECKING, Any, TypeVar, Union
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
if TYPE_CHECKING:
|
9
|
-
from ..models.metadata_labels import MetadataLabels
|
10
|
-
|
11
|
-
|
12
|
-
T = TypeVar("T", bound="EnvironmentMetadata")
|
13
|
-
|
14
|
-
|
15
|
-
@_attrs_define
|
16
|
-
class EnvironmentMetadata:
|
17
|
-
"""Environment metadata
|
18
|
-
|
19
|
-
Attributes:
|
20
|
-
created_at (Union[Unset, str]): The date and time when the resource was created
|
21
|
-
updated_at (Union[Unset, str]): The date and time when the resource was updated
|
22
|
-
created_by (Union[Unset, str]): The user or service account who created the resource
|
23
|
-
updated_by (Union[Unset, str]): The user or service account who updated the resource
|
24
|
-
display_name (Union[Unset, str]): Model display name
|
25
|
-
labels (Union[Unset, MetadataLabels]): Labels
|
26
|
-
name (Union[Unset, str]): Model name
|
27
|
-
workspace (Union[Unset, str]): Workspace name
|
28
|
-
environment (Union[Unset, str]): Environment name
|
29
|
-
"""
|
30
|
-
|
31
|
-
created_at: Union[Unset, str] = UNSET
|
32
|
-
updated_at: Union[Unset, str] = UNSET
|
33
|
-
created_by: Union[Unset, str] = UNSET
|
34
|
-
updated_by: Union[Unset, str] = UNSET
|
35
|
-
display_name: Union[Unset, str] = UNSET
|
36
|
-
labels: Union[Unset, "MetadataLabels"] = UNSET
|
37
|
-
name: Union[Unset, str] = UNSET
|
38
|
-
workspace: Union[Unset, str] = UNSET
|
39
|
-
environment: Union[Unset, str] = UNSET
|
40
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
41
|
-
|
42
|
-
def to_dict(self) -> dict[str, Any]:
|
43
|
-
created_at = self.created_at
|
44
|
-
|
45
|
-
updated_at = self.updated_at
|
46
|
-
|
47
|
-
created_by = self.created_by
|
48
|
-
|
49
|
-
updated_by = self.updated_by
|
50
|
-
|
51
|
-
display_name = self.display_name
|
52
|
-
|
53
|
-
labels: Union[Unset, dict[str, Any]] = UNSET
|
54
|
-
if self.labels and not isinstance(self.labels, Unset) and not isinstance(self.labels, dict):
|
55
|
-
labels = self.labels.to_dict()
|
56
|
-
elif self.labels and isinstance(self.labels, dict):
|
57
|
-
labels = self.labels
|
58
|
-
|
59
|
-
name = self.name
|
60
|
-
|
61
|
-
workspace = self.workspace
|
62
|
-
|
63
|
-
environment = self.environment
|
64
|
-
|
65
|
-
field_dict: dict[str, Any] = {}
|
66
|
-
field_dict.update(self.additional_properties)
|
67
|
-
field_dict.update({})
|
68
|
-
if created_at is not UNSET:
|
69
|
-
field_dict["createdAt"] = created_at
|
70
|
-
if updated_at is not UNSET:
|
71
|
-
field_dict["updatedAt"] = updated_at
|
72
|
-
if created_by is not UNSET:
|
73
|
-
field_dict["createdBy"] = created_by
|
74
|
-
if updated_by is not UNSET:
|
75
|
-
field_dict["updatedBy"] = updated_by
|
76
|
-
if display_name is not UNSET:
|
77
|
-
field_dict["displayName"] = display_name
|
78
|
-
if labels is not UNSET:
|
79
|
-
field_dict["labels"] = labels
|
80
|
-
if name is not UNSET:
|
81
|
-
field_dict["name"] = name
|
82
|
-
if workspace is not UNSET:
|
83
|
-
field_dict["workspace"] = workspace
|
84
|
-
if environment is not UNSET:
|
85
|
-
field_dict["environment"] = environment
|
86
|
-
|
87
|
-
return field_dict
|
88
|
-
|
89
|
-
@classmethod
|
90
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
91
|
-
from ..models.metadata_labels import MetadataLabels
|
92
|
-
|
93
|
-
if not src_dict:
|
94
|
-
return None
|
95
|
-
d = src_dict.copy()
|
96
|
-
created_at = d.pop("createdAt", UNSET)
|
97
|
-
|
98
|
-
updated_at = d.pop("updatedAt", UNSET)
|
99
|
-
|
100
|
-
created_by = d.pop("createdBy", UNSET)
|
101
|
-
|
102
|
-
updated_by = d.pop("updatedBy", UNSET)
|
103
|
-
|
104
|
-
display_name = d.pop("displayName", UNSET)
|
105
|
-
|
106
|
-
_labels = d.pop("labels", UNSET)
|
107
|
-
labels: Union[Unset, MetadataLabels]
|
108
|
-
if isinstance(_labels, Unset):
|
109
|
-
labels = UNSET
|
110
|
-
else:
|
111
|
-
labels = MetadataLabels.from_dict(_labels)
|
112
|
-
|
113
|
-
name = d.pop("name", UNSET)
|
114
|
-
|
115
|
-
workspace = d.pop("workspace", UNSET)
|
116
|
-
|
117
|
-
environment = d.pop("environment", UNSET)
|
118
|
-
|
119
|
-
environment_metadata = cls(
|
120
|
-
created_at=created_at,
|
121
|
-
updated_at=updated_at,
|
122
|
-
created_by=created_by,
|
123
|
-
updated_by=updated_by,
|
124
|
-
display_name=display_name,
|
125
|
-
labels=labels,
|
126
|
-
name=name,
|
127
|
-
workspace=workspace,
|
128
|
-
environment=environment,
|
129
|
-
)
|
130
|
-
|
131
|
-
environment_metadata.additional_properties = d
|
132
|
-
return environment_metadata
|
133
|
-
|
134
|
-
@property
|
135
|
-
def additional_keys(self) -> list[str]:
|
136
|
-
return list(self.additional_properties.keys())
|
137
|
-
|
138
|
-
def __getitem__(self, key: str) -> Any:
|
139
|
-
return self.additional_properties[key]
|
140
|
-
|
141
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
142
|
-
self.additional_properties[key] = value
|
143
|
-
|
144
|
-
def __delitem__(self, key: str) -> None:
|
145
|
-
del self.additional_properties[key]
|
146
|
-
|
147
|
-
def __contains__(self, key: str) -> bool:
|
148
|
-
return key in self.additional_properties
|
@@ -1,77 +0,0 @@
|
|
1
|
-
from typing import TYPE_CHECKING, Any, TypeVar, Union
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
if TYPE_CHECKING:
|
9
|
-
from ..models.metric import Metric
|
10
|
-
|
11
|
-
|
12
|
-
T = TypeVar("T", bound="EnvironmentMetrics")
|
13
|
-
|
14
|
-
|
15
|
-
@_attrs_define
|
16
|
-
class EnvironmentMetrics:
|
17
|
-
"""Metrics for the environment
|
18
|
-
|
19
|
-
Attributes:
|
20
|
-
inference_global (Union[Unset, list['Metric']]): Array of metrics
|
21
|
-
"""
|
22
|
-
|
23
|
-
inference_global: Union[Unset, list["Metric"]] = UNSET
|
24
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
25
|
-
|
26
|
-
def to_dict(self) -> dict[str, Any]:
|
27
|
-
inference_global: Union[Unset, list[dict[str, Any]]] = UNSET
|
28
|
-
if not isinstance(self.inference_global, Unset):
|
29
|
-
inference_global = []
|
30
|
-
for componentsschemas_array_metric_item_data in self.inference_global:
|
31
|
-
componentsschemas_array_metric_item = componentsschemas_array_metric_item_data.to_dict()
|
32
|
-
inference_global.append(componentsschemas_array_metric_item)
|
33
|
-
|
34
|
-
field_dict: dict[str, Any] = {}
|
35
|
-
field_dict.update(self.additional_properties)
|
36
|
-
field_dict.update({})
|
37
|
-
if inference_global is not UNSET:
|
38
|
-
field_dict["inferenceGlobal"] = inference_global
|
39
|
-
|
40
|
-
return field_dict
|
41
|
-
|
42
|
-
@classmethod
|
43
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
44
|
-
from ..models.metric import Metric
|
45
|
-
|
46
|
-
if not src_dict:
|
47
|
-
return None
|
48
|
-
d = src_dict.copy()
|
49
|
-
inference_global = []
|
50
|
-
_inference_global = d.pop("inferenceGlobal", UNSET)
|
51
|
-
for componentsschemas_array_metric_item_data in _inference_global or []:
|
52
|
-
componentsschemas_array_metric_item = Metric.from_dict(componentsschemas_array_metric_item_data)
|
53
|
-
|
54
|
-
inference_global.append(componentsschemas_array_metric_item)
|
55
|
-
|
56
|
-
environment_metrics = cls(
|
57
|
-
inference_global=inference_global,
|
58
|
-
)
|
59
|
-
|
60
|
-
environment_metrics.additional_properties = d
|
61
|
-
return environment_metrics
|
62
|
-
|
63
|
-
@property
|
64
|
-
def additional_keys(self) -> list[str]:
|
65
|
-
return list(self.additional_properties.keys())
|
66
|
-
|
67
|
-
def __getitem__(self, key: str) -> Any:
|
68
|
-
return self.additional_properties[key]
|
69
|
-
|
70
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
71
|
-
self.additional_properties[key] = value
|
72
|
-
|
73
|
-
def __delitem__(self, key: str) -> None:
|
74
|
-
del self.additional_properties[key]
|
75
|
-
|
76
|
-
def __contains__(self, key: str) -> bool:
|
77
|
-
return key in self.additional_properties
|
@@ -1,63 +0,0 @@
|
|
1
|
-
from typing import Any, TypeVar, Union, cast
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
T = TypeVar("T", bound="EnvironmentSpec")
|
9
|
-
|
10
|
-
|
11
|
-
@_attrs_define
|
12
|
-
class EnvironmentSpec:
|
13
|
-
"""Environment specification
|
14
|
-
|
15
|
-
Attributes:
|
16
|
-
policies (Union[Unset, list[str]]):
|
17
|
-
"""
|
18
|
-
|
19
|
-
policies: Union[Unset, list[str]] = UNSET
|
20
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
21
|
-
|
22
|
-
def to_dict(self) -> dict[str, Any]:
|
23
|
-
policies: Union[Unset, list[str]] = UNSET
|
24
|
-
if not isinstance(self.policies, Unset):
|
25
|
-
policies = self.policies
|
26
|
-
|
27
|
-
field_dict: dict[str, Any] = {}
|
28
|
-
field_dict.update(self.additional_properties)
|
29
|
-
field_dict.update({})
|
30
|
-
if policies is not UNSET:
|
31
|
-
field_dict["policies"] = policies
|
32
|
-
|
33
|
-
return field_dict
|
34
|
-
|
35
|
-
@classmethod
|
36
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
37
|
-
if not src_dict:
|
38
|
-
return None
|
39
|
-
d = src_dict.copy()
|
40
|
-
policies = cast(list[str], d.pop("policies", UNSET))
|
41
|
-
|
42
|
-
environment_spec = cls(
|
43
|
-
policies=policies,
|
44
|
-
)
|
45
|
-
|
46
|
-
environment_spec.additional_properties = d
|
47
|
-
return environment_spec
|
48
|
-
|
49
|
-
@property
|
50
|
-
def additional_keys(self) -> list[str]:
|
51
|
-
return list(self.additional_properties.keys())
|
52
|
-
|
53
|
-
def __getitem__(self, key: str) -> Any:
|
54
|
-
return self.additional_properties[key]
|
55
|
-
|
56
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
57
|
-
self.additional_properties[key] = value
|
58
|
-
|
59
|
-
def __delitem__(self, key: str) -> None:
|
60
|
-
del self.additional_properties[key]
|
61
|
-
|
62
|
-
def __contains__(self, key: str) -> bool:
|
63
|
-
return key in self.additional_properties
|
@@ -1,70 +0,0 @@
|
|
1
|
-
from typing import Any, TypeVar, Union
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
T = TypeVar("T", bound="FunctionRelease")
|
9
|
-
|
10
|
-
|
11
|
-
@_attrs_define
|
12
|
-
class FunctionRelease:
|
13
|
-
"""Function release, used to deploy a function from one environment to another
|
14
|
-
|
15
|
-
Attributes:
|
16
|
-
from_ (Union[Unset, str]): Origin environment from which the function is released
|
17
|
-
to (Union[Unset, str]): Destination environment to which the function is released
|
18
|
-
"""
|
19
|
-
|
20
|
-
from_: Union[Unset, str] = UNSET
|
21
|
-
to: Union[Unset, str] = UNSET
|
22
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
23
|
-
|
24
|
-
def to_dict(self) -> dict[str, Any]:
|
25
|
-
from_ = self.from_
|
26
|
-
|
27
|
-
to = self.to
|
28
|
-
|
29
|
-
field_dict: dict[str, Any] = {}
|
30
|
-
field_dict.update(self.additional_properties)
|
31
|
-
field_dict.update({})
|
32
|
-
if from_ is not UNSET:
|
33
|
-
field_dict["from"] = from_
|
34
|
-
if to is not UNSET:
|
35
|
-
field_dict["to"] = to
|
36
|
-
|
37
|
-
return field_dict
|
38
|
-
|
39
|
-
@classmethod
|
40
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
41
|
-
if not src_dict:
|
42
|
-
return None
|
43
|
-
d = src_dict.copy()
|
44
|
-
from_ = d.pop("from", UNSET)
|
45
|
-
|
46
|
-
to = d.pop("to", UNSET)
|
47
|
-
|
48
|
-
function_release = cls(
|
49
|
-
from_=from_,
|
50
|
-
to=to,
|
51
|
-
)
|
52
|
-
|
53
|
-
function_release.additional_properties = d
|
54
|
-
return function_release
|
55
|
-
|
56
|
-
@property
|
57
|
-
def additional_keys(self) -> list[str]:
|
58
|
-
return list(self.additional_properties.keys())
|
59
|
-
|
60
|
-
def __getitem__(self, key: str) -> Any:
|
61
|
-
return self.additional_properties[key]
|
62
|
-
|
63
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
64
|
-
self.additional_properties[key] = value
|
65
|
-
|
66
|
-
def __delitem__(self, key: str) -> None:
|
67
|
-
del self.additional_properties[key]
|
68
|
-
|
69
|
-
def __contains__(self, key: str) -> bool:
|
70
|
-
return key in self.additional_properties
|
@@ -1,70 +0,0 @@
|
|
1
|
-
from typing import Any, TypeVar, Union
|
2
|
-
|
3
|
-
from attrs import define as _attrs_define
|
4
|
-
from attrs import field as _attrs_field
|
5
|
-
|
6
|
-
from ..types import UNSET, Unset
|
7
|
-
|
8
|
-
T = TypeVar("T", bound="KnowledgebaseRelease")
|
9
|
-
|
10
|
-
|
11
|
-
@_attrs_define
|
12
|
-
class KnowledgebaseRelease:
|
13
|
-
"""Knowledgebase release, used to deploy a function from one environment to another
|
14
|
-
|
15
|
-
Attributes:
|
16
|
-
from_ (Union[Unset, str]): Origin environment from which the function is released
|
17
|
-
to (Union[Unset, str]): Destination environment to which the function is released
|
18
|
-
"""
|
19
|
-
|
20
|
-
from_: Union[Unset, str] = UNSET
|
21
|
-
to: Union[Unset, str] = UNSET
|
22
|
-
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
23
|
-
|
24
|
-
def to_dict(self) -> dict[str, Any]:
|
25
|
-
from_ = self.from_
|
26
|
-
|
27
|
-
to = self.to
|
28
|
-
|
29
|
-
field_dict: dict[str, Any] = {}
|
30
|
-
field_dict.update(self.additional_properties)
|
31
|
-
field_dict.update({})
|
32
|
-
if from_ is not UNSET:
|
33
|
-
field_dict["from"] = from_
|
34
|
-
if to is not UNSET:
|
35
|
-
field_dict["to"] = to
|
36
|
-
|
37
|
-
return field_dict
|
38
|
-
|
39
|
-
@classmethod
|
40
|
-
def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T:
|
41
|
-
if not src_dict:
|
42
|
-
return None
|
43
|
-
d = src_dict.copy()
|
44
|
-
from_ = d.pop("from", UNSET)
|
45
|
-
|
46
|
-
to = d.pop("to", UNSET)
|
47
|
-
|
48
|
-
knowledgebase_release = cls(
|
49
|
-
from_=from_,
|
50
|
-
to=to,
|
51
|
-
)
|
52
|
-
|
53
|
-
knowledgebase_release.additional_properties = d
|
54
|
-
return knowledgebase_release
|
55
|
-
|
56
|
-
@property
|
57
|
-
def additional_keys(self) -> list[str]:
|
58
|
-
return list(self.additional_properties.keys())
|
59
|
-
|
60
|
-
def __getitem__(self, key: str) -> Any:
|
61
|
-
return self.additional_properties[key]
|
62
|
-
|
63
|
-
def __setitem__(self, key: str, value: Any) -> None:
|
64
|
-
self.additional_properties[key] = value
|
65
|
-
|
66
|
-
def __delitem__(self, key: str) -> None:
|
67
|
-
del self.additional_properties[key]
|
68
|
-
|
69
|
-
def __contains__(self, key: str) -> bool:
|
70
|
-
return key in self.additional_properties
|