beamlit 0.0.47rc93__py3-none-any.whl → 0.0.48__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/decorator.py +3 -3
- beamlit/api/{model_providers/delete_model_provider.py → accounts/delete_account.py} +42 -35
- beamlit/api/{model_providers/get_model_provider.py → accounts/get_account.py} +34 -34
- beamlit/api/{model_providers/list_model_providers.py → accounts/list_accounts.py} +21 -21
- beamlit/api/{model_providers/update_model_provider.py → accounts/update_account.py} +43 -43
- beamlit/api/agents/get_agent_metrics.py +12 -12
- beamlit/api/{model_providers/create_model_provider.py → default/create_account.py} +30 -30
- beamlit/api/functions/get_function_metrics.py +12 -12
- beamlit/api/models/get_model_metrics.py +12 -12
- beamlit/functions/common.py +0 -1
- beamlit/functions/mcp/mcp.py +3 -2
- beamlit/models/__init__.py +16 -30
- beamlit/models/{model_metadata.py → account.py} +93 -15
- beamlit/models/{agent_metadata.py → account_metadata.py} +16 -41
- beamlit/models/account_spec.py +123 -0
- beamlit/models/{agent_render.py → account_spec_address.py} +6 -6
- beamlit/models/agent.py +6 -2
- beamlit/models/agent_spec.py +30 -6
- beamlit/models/billing_address.py +133 -0
- beamlit/models/core_spec.py +27 -5
- beamlit/models/core_spec_configurations.py +3 -1
- beamlit/models/environment.py +6 -2
- beamlit/models/environment_metadata.py +3 -1
- beamlit/models/function.py +6 -2
- beamlit/models/function_spec.py +27 -5
- beamlit/models/integration_connection.py +6 -2
- beamlit/models/integration_connection_spec.py +18 -14
- beamlit/models/{function_render.py → integration_connection_spec_config.py} +6 -6
- beamlit/models/{core_status.py → integration_connection_spec_secret.py} +6 -6
- beamlit/models/latency_metric.py +24 -4
- beamlit/models/metadata.py +3 -1
- beamlit/models/metrics.py +13 -3
- beamlit/models/model.py +6 -2
- beamlit/models/model_spec.py +27 -5
- beamlit/models/pending_invitation_accept.py +3 -1
- beamlit/models/pending_invitation_render.py +13 -3
- beamlit/models/policy.py +6 -2
- beamlit/models/policy_max_tokens.py +106 -0
- beamlit/models/policy_spec.py +30 -0
- beamlit/models/request_duration_over_time_metrics.py +7 -1
- beamlit/models/request_total_by_origin_metric.py +14 -2
- beamlit/models/request_total_metric.py +10 -2
- beamlit/models/resource_environment_metrics.py +33 -7
- beamlit/models/resource_log.py +9 -0
- beamlit/models/runtime.py +10 -2
- beamlit/models/store_agent.py +3 -1
- beamlit/models/store_function.py +3 -1
- beamlit/models/token_rate_metrics.py +17 -3
- beamlit/models/trace_ids_response.py +3 -21
- beamlit/models/workspace.py +12 -1
- {beamlit-0.0.47rc93.dist-info → beamlit-0.0.48.dist-info}/METADATA +1 -1
- {beamlit-0.0.47rc93.dist-info → beamlit-0.0.48.dist-info}/RECORD +55 -70
- beamlit/models/function_metadata.py +0 -146
- beamlit/models/increase_and_rate_metric.py +0 -61
- beamlit/models/integration_config.py +0 -45
- beamlit/models/integration_connection_config.py +0 -45
- beamlit/models/integration_connection_secret.py +0 -61
- beamlit/models/model_provider.py +0 -173
- beamlit/models/model_render.py +0 -45
- beamlit/models/provider_config.py +0 -94
- beamlit/models/qps.py +0 -61
- beamlit/models/repository_type_0.py +0 -70
- beamlit/models/resource_deployment_metrics.py +0 -176
- beamlit/models/resource_deployment_metrics_inference_per_second_per_region.py +0 -77
- beamlit/models/resource_deployment_metrics_query_per_second_per_region_per_code.py +0 -75
- beamlit/models/resource_environment_metrics_inference_per_region.py +0 -77
- beamlit/models/resource_environment_metrics_inference_per_second_per_region.py +0 -77
- beamlit/models/resource_environment_metrics_query_per_region_per_code.py +0 -75
- beamlit/models/resource_environment_metrics_query_per_second_per_region_per_code.py +0 -75
- beamlit/models/resource_metrics.py +0 -96
- /beamlit/api/{model_providers → accounts}/__init__.py +0 -0
- {beamlit-0.0.47rc93.dist-info → beamlit-0.0.48.dist-info}/WHEEL +0 -0
- {beamlit-0.0.47rc93.dist-info → beamlit-0.0.48.dist-info}/licenses/LICENSE +0 -0
@@ -5,20 +5,20 @@ import httpx
|
|
5
5
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
|
-
from ...models.
|
8
|
+
from ...models.account import Account
|
9
9
|
from ...types import Response
|
10
10
|
|
11
11
|
|
12
12
|
def _get_kwargs(
|
13
|
-
|
13
|
+
account_id: str,
|
14
14
|
*,
|
15
|
-
body:
|
15
|
+
body: Account,
|
16
16
|
) -> dict[str, Any]:
|
17
17
|
headers: dict[str, Any] = {}
|
18
18
|
|
19
19
|
_kwargs: dict[str, Any] = {
|
20
20
|
"method": "put",
|
21
|
-
"url": f"/
|
21
|
+
"url": f"/accounts/{account_id}",
|
22
22
|
}
|
23
23
|
|
24
24
|
_body = body.to_dict()
|
@@ -30,9 +30,9 @@ def _get_kwargs(
|
|
30
30
|
return _kwargs
|
31
31
|
|
32
32
|
|
33
|
-
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[
|
33
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[Account]:
|
34
34
|
if response.status_code == 200:
|
35
|
-
response_200 =
|
35
|
+
response_200 = Account.from_dict(response.json())
|
36
36
|
|
37
37
|
return response_200
|
38
38
|
if client.raise_on_unexpected_status:
|
@@ -41,7 +41,7 @@ def _parse_response(*, client: Union[AuthenticatedClient, Client], response: htt
|
|
41
41
|
return None
|
42
42
|
|
43
43
|
|
44
|
-
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[
|
44
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[Account]:
|
45
45
|
return Response(
|
46
46
|
status_code=HTTPStatus(response.status_code),
|
47
47
|
content=response.content,
|
@@ -51,29 +51,29 @@ def _build_response(*, client: Union[AuthenticatedClient, Client], response: htt
|
|
51
51
|
|
52
52
|
|
53
53
|
def sync_detailed(
|
54
|
-
|
54
|
+
account_id: str,
|
55
55
|
*,
|
56
56
|
client: AuthenticatedClient,
|
57
|
-
body:
|
58
|
-
) -> Response[
|
59
|
-
"""Update
|
57
|
+
body: Account,
|
58
|
+
) -> Response[Account]:
|
59
|
+
"""Update account
|
60
60
|
|
61
|
-
|
61
|
+
Updates an account by name.
|
62
62
|
|
63
63
|
Args:
|
64
|
-
|
65
|
-
body (
|
64
|
+
account_id (str):
|
65
|
+
body (Account): Account
|
66
66
|
|
67
67
|
Raises:
|
68
68
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
69
69
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
70
70
|
|
71
71
|
Returns:
|
72
|
-
Response[
|
72
|
+
Response[Account]
|
73
73
|
"""
|
74
74
|
|
75
75
|
kwargs = _get_kwargs(
|
76
|
-
|
76
|
+
account_id=account_id,
|
77
77
|
body=body,
|
78
78
|
)
|
79
79
|
|
@@ -85,58 +85,58 @@ def sync_detailed(
|
|
85
85
|
|
86
86
|
|
87
87
|
def sync(
|
88
|
-
|
88
|
+
account_id: str,
|
89
89
|
*,
|
90
90
|
client: AuthenticatedClient,
|
91
|
-
body:
|
92
|
-
) -> Optional[
|
93
|
-
"""Update
|
91
|
+
body: Account,
|
92
|
+
) -> Optional[Account]:
|
93
|
+
"""Update account
|
94
94
|
|
95
|
-
|
95
|
+
Updates an account by name.
|
96
96
|
|
97
97
|
Args:
|
98
|
-
|
99
|
-
body (
|
98
|
+
account_id (str):
|
99
|
+
body (Account): Account
|
100
100
|
|
101
101
|
Raises:
|
102
102
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
103
103
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
104
104
|
|
105
105
|
Returns:
|
106
|
-
|
106
|
+
Account
|
107
107
|
"""
|
108
108
|
|
109
109
|
return sync_detailed(
|
110
|
-
|
110
|
+
account_id=account_id,
|
111
111
|
client=client,
|
112
112
|
body=body,
|
113
113
|
).parsed
|
114
114
|
|
115
115
|
|
116
116
|
async def asyncio_detailed(
|
117
|
-
|
117
|
+
account_id: str,
|
118
118
|
*,
|
119
119
|
client: AuthenticatedClient,
|
120
|
-
body:
|
121
|
-
) -> Response[
|
122
|
-
"""Update
|
120
|
+
body: Account,
|
121
|
+
) -> Response[Account]:
|
122
|
+
"""Update account
|
123
123
|
|
124
|
-
|
124
|
+
Updates an account by name.
|
125
125
|
|
126
126
|
Args:
|
127
|
-
|
128
|
-
body (
|
127
|
+
account_id (str):
|
128
|
+
body (Account): Account
|
129
129
|
|
130
130
|
Raises:
|
131
131
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
132
132
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
133
133
|
|
134
134
|
Returns:
|
135
|
-
Response[
|
135
|
+
Response[Account]
|
136
136
|
"""
|
137
137
|
|
138
138
|
kwargs = _get_kwargs(
|
139
|
-
|
139
|
+
account_id=account_id,
|
140
140
|
body=body,
|
141
141
|
)
|
142
142
|
|
@@ -146,30 +146,30 @@ async def asyncio_detailed(
|
|
146
146
|
|
147
147
|
|
148
148
|
async def asyncio(
|
149
|
-
|
149
|
+
account_id: str,
|
150
150
|
*,
|
151
151
|
client: AuthenticatedClient,
|
152
|
-
body:
|
153
|
-
) -> Optional[
|
154
|
-
"""Update
|
152
|
+
body: Account,
|
153
|
+
) -> Optional[Account]:
|
154
|
+
"""Update account
|
155
155
|
|
156
|
-
|
156
|
+
Updates an account by name.
|
157
157
|
|
158
158
|
Args:
|
159
|
-
|
160
|
-
body (
|
159
|
+
account_id (str):
|
160
|
+
body (Account): Account
|
161
161
|
|
162
162
|
Raises:
|
163
163
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
164
164
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
165
165
|
|
166
166
|
Returns:
|
167
|
-
|
167
|
+
Account
|
168
168
|
"""
|
169
169
|
|
170
170
|
return (
|
171
171
|
await asyncio_detailed(
|
172
|
-
|
172
|
+
account_id=account_id,
|
173
173
|
client=client,
|
174
174
|
body=body,
|
175
175
|
)
|
@@ -5,7 +5,7 @@ import httpx
|
|
5
5
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
|
-
from ...models.
|
8
|
+
from ...models.resource_environment_metrics import ResourceEnvironmentMetrics
|
9
9
|
from ...types import UNSET, Response, Unset
|
10
10
|
|
11
11
|
|
@@ -31,9 +31,9 @@ def _get_kwargs(
|
|
31
31
|
|
32
32
|
def _parse_response(
|
33
33
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
34
|
-
) -> Optional[
|
34
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
35
35
|
if response.status_code == 200:
|
36
|
-
response_200 =
|
36
|
+
response_200 = ResourceEnvironmentMetrics.from_dict(response.json())
|
37
37
|
|
38
38
|
return response_200
|
39
39
|
if client.raise_on_unexpected_status:
|
@@ -44,7 +44,7 @@ def _parse_response(
|
|
44
44
|
|
45
45
|
def _build_response(
|
46
46
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
47
|
-
) -> Response[
|
47
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
48
48
|
return Response(
|
49
49
|
status_code=HTTPStatus(response.status_code),
|
50
50
|
content=response.content,
|
@@ -58,7 +58,7 @@ def sync_detailed(
|
|
58
58
|
*,
|
59
59
|
client: AuthenticatedClient,
|
60
60
|
environment: Union[Unset, str] = UNSET,
|
61
|
-
) -> Response[
|
61
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
62
62
|
"""Get agent metrics
|
63
63
|
|
64
64
|
Args:
|
@@ -70,7 +70,7 @@ def sync_detailed(
|
|
70
70
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
71
71
|
|
72
72
|
Returns:
|
73
|
-
Response[
|
73
|
+
Response[ResourceEnvironmentMetrics]
|
74
74
|
"""
|
75
75
|
|
76
76
|
kwargs = _get_kwargs(
|
@@ -90,7 +90,7 @@ def sync(
|
|
90
90
|
*,
|
91
91
|
client: AuthenticatedClient,
|
92
92
|
environment: Union[Unset, str] = UNSET,
|
93
|
-
) -> Optional[
|
93
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
94
94
|
"""Get agent metrics
|
95
95
|
|
96
96
|
Args:
|
@@ -102,7 +102,7 @@ def sync(
|
|
102
102
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
103
103
|
|
104
104
|
Returns:
|
105
|
-
|
105
|
+
ResourceEnvironmentMetrics
|
106
106
|
"""
|
107
107
|
|
108
108
|
return sync_detailed(
|
@@ -117,7 +117,7 @@ async def asyncio_detailed(
|
|
117
117
|
*,
|
118
118
|
client: AuthenticatedClient,
|
119
119
|
environment: Union[Unset, str] = UNSET,
|
120
|
-
) -> Response[
|
120
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
121
121
|
"""Get agent metrics
|
122
122
|
|
123
123
|
Args:
|
@@ -129,7 +129,7 @@ async def asyncio_detailed(
|
|
129
129
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
130
130
|
|
131
131
|
Returns:
|
132
|
-
Response[
|
132
|
+
Response[ResourceEnvironmentMetrics]
|
133
133
|
"""
|
134
134
|
|
135
135
|
kwargs = _get_kwargs(
|
@@ -147,7 +147,7 @@ async def asyncio(
|
|
147
147
|
*,
|
148
148
|
client: AuthenticatedClient,
|
149
149
|
environment: Union[Unset, str] = UNSET,
|
150
|
-
) -> Optional[
|
150
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
151
151
|
"""Get agent metrics
|
152
152
|
|
153
153
|
Args:
|
@@ -159,7 +159,7 @@ async def asyncio(
|
|
159
159
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
160
160
|
|
161
161
|
Returns:
|
162
|
-
|
162
|
+
ResourceEnvironmentMetrics
|
163
163
|
"""
|
164
164
|
|
165
165
|
return (
|
@@ -5,19 +5,19 @@ import httpx
|
|
5
5
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
|
-
from ...models.
|
8
|
+
from ...models.account import Account
|
9
9
|
from ...types import Response
|
10
10
|
|
11
11
|
|
12
12
|
def _get_kwargs(
|
13
13
|
*,
|
14
|
-
body:
|
14
|
+
body: Account,
|
15
15
|
) -> dict[str, Any]:
|
16
16
|
headers: dict[str, Any] = {}
|
17
17
|
|
18
18
|
_kwargs: dict[str, Any] = {
|
19
19
|
"method": "post",
|
20
|
-
"url": "/
|
20
|
+
"url": "/accounts",
|
21
21
|
}
|
22
22
|
|
23
23
|
_body = body.to_dict()
|
@@ -29,9 +29,9 @@ def _get_kwargs(
|
|
29
29
|
return _kwargs
|
30
30
|
|
31
31
|
|
32
|
-
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[
|
32
|
+
def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Optional[Account]:
|
33
33
|
if response.status_code == 200:
|
34
|
-
response_200 =
|
34
|
+
response_200 = Account.from_dict(response.json())
|
35
35
|
|
36
36
|
return response_200
|
37
37
|
if client.raise_on_unexpected_status:
|
@@ -40,7 +40,7 @@ def _parse_response(*, client: Union[AuthenticatedClient, Client], response: htt
|
|
40
40
|
return None
|
41
41
|
|
42
42
|
|
43
|
-
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[
|
43
|
+
def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[Account]:
|
44
44
|
return Response(
|
45
45
|
status_code=HTTPStatus(response.status_code),
|
46
46
|
content=response.content,
|
@@ -52,21 +52,21 @@ def _build_response(*, client: Union[AuthenticatedClient, Client], response: htt
|
|
52
52
|
def sync_detailed(
|
53
53
|
*,
|
54
54
|
client: AuthenticatedClient,
|
55
|
-
body:
|
56
|
-
) -> Response[
|
57
|
-
"""Create
|
55
|
+
body: Account,
|
56
|
+
) -> Response[Account]:
|
57
|
+
"""Create account
|
58
58
|
|
59
|
-
|
59
|
+
Creates an account.
|
60
60
|
|
61
61
|
Args:
|
62
|
-
body (
|
62
|
+
body (Account): Account
|
63
63
|
|
64
64
|
Raises:
|
65
65
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
66
66
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
67
67
|
|
68
68
|
Returns:
|
69
|
-
Response[
|
69
|
+
Response[Account]
|
70
70
|
"""
|
71
71
|
|
72
72
|
kwargs = _get_kwargs(
|
@@ -83,21 +83,21 @@ def sync_detailed(
|
|
83
83
|
def sync(
|
84
84
|
*,
|
85
85
|
client: AuthenticatedClient,
|
86
|
-
body:
|
87
|
-
) -> Optional[
|
88
|
-
"""Create
|
86
|
+
body: Account,
|
87
|
+
) -> Optional[Account]:
|
88
|
+
"""Create account
|
89
89
|
|
90
|
-
|
90
|
+
Creates an account.
|
91
91
|
|
92
92
|
Args:
|
93
|
-
body (
|
93
|
+
body (Account): Account
|
94
94
|
|
95
95
|
Raises:
|
96
96
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
97
97
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
98
98
|
|
99
99
|
Returns:
|
100
|
-
|
100
|
+
Account
|
101
101
|
"""
|
102
102
|
|
103
103
|
return sync_detailed(
|
@@ -109,21 +109,21 @@ def sync(
|
|
109
109
|
async def asyncio_detailed(
|
110
110
|
*,
|
111
111
|
client: AuthenticatedClient,
|
112
|
-
body:
|
113
|
-
) -> Response[
|
114
|
-
"""Create
|
112
|
+
body: Account,
|
113
|
+
) -> Response[Account]:
|
114
|
+
"""Create account
|
115
115
|
|
116
|
-
|
116
|
+
Creates an account.
|
117
117
|
|
118
118
|
Args:
|
119
|
-
body (
|
119
|
+
body (Account): Account
|
120
120
|
|
121
121
|
Raises:
|
122
122
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
123
123
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
124
124
|
|
125
125
|
Returns:
|
126
|
-
Response[
|
126
|
+
Response[Account]
|
127
127
|
"""
|
128
128
|
|
129
129
|
kwargs = _get_kwargs(
|
@@ -138,21 +138,21 @@ async def asyncio_detailed(
|
|
138
138
|
async def asyncio(
|
139
139
|
*,
|
140
140
|
client: AuthenticatedClient,
|
141
|
-
body:
|
142
|
-
) -> Optional[
|
143
|
-
"""Create
|
141
|
+
body: Account,
|
142
|
+
) -> Optional[Account]:
|
143
|
+
"""Create account
|
144
144
|
|
145
|
-
|
145
|
+
Creates an account.
|
146
146
|
|
147
147
|
Args:
|
148
|
-
body (
|
148
|
+
body (Account): Account
|
149
149
|
|
150
150
|
Raises:
|
151
151
|
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
152
152
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
153
153
|
|
154
154
|
Returns:
|
155
|
-
|
155
|
+
Account
|
156
156
|
"""
|
157
157
|
|
158
158
|
return (
|
@@ -5,7 +5,7 @@ import httpx
|
|
5
5
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
|
-
from ...models.
|
8
|
+
from ...models.resource_environment_metrics import ResourceEnvironmentMetrics
|
9
9
|
from ...types import UNSET, Response, Unset
|
10
10
|
|
11
11
|
|
@@ -31,9 +31,9 @@ def _get_kwargs(
|
|
31
31
|
|
32
32
|
def _parse_response(
|
33
33
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
34
|
-
) -> Optional[
|
34
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
35
35
|
if response.status_code == 200:
|
36
|
-
response_200 =
|
36
|
+
response_200 = ResourceEnvironmentMetrics.from_dict(response.json())
|
37
37
|
|
38
38
|
return response_200
|
39
39
|
if client.raise_on_unexpected_status:
|
@@ -44,7 +44,7 @@ def _parse_response(
|
|
44
44
|
|
45
45
|
def _build_response(
|
46
46
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
47
|
-
) -> Response[
|
47
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
48
48
|
return Response(
|
49
49
|
status_code=HTTPStatus(response.status_code),
|
50
50
|
content=response.content,
|
@@ -58,7 +58,7 @@ def sync_detailed(
|
|
58
58
|
*,
|
59
59
|
client: AuthenticatedClient,
|
60
60
|
environment: Union[Unset, str] = UNSET,
|
61
|
-
) -> Response[
|
61
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
62
62
|
"""Get function metrics
|
63
63
|
|
64
64
|
Args:
|
@@ -70,7 +70,7 @@ def sync_detailed(
|
|
70
70
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
71
71
|
|
72
72
|
Returns:
|
73
|
-
Response[
|
73
|
+
Response[ResourceEnvironmentMetrics]
|
74
74
|
"""
|
75
75
|
|
76
76
|
kwargs = _get_kwargs(
|
@@ -90,7 +90,7 @@ def sync(
|
|
90
90
|
*,
|
91
91
|
client: AuthenticatedClient,
|
92
92
|
environment: Union[Unset, str] = UNSET,
|
93
|
-
) -> Optional[
|
93
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
94
94
|
"""Get function metrics
|
95
95
|
|
96
96
|
Args:
|
@@ -102,7 +102,7 @@ def sync(
|
|
102
102
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
103
103
|
|
104
104
|
Returns:
|
105
|
-
|
105
|
+
ResourceEnvironmentMetrics
|
106
106
|
"""
|
107
107
|
|
108
108
|
return sync_detailed(
|
@@ -117,7 +117,7 @@ async def asyncio_detailed(
|
|
117
117
|
*,
|
118
118
|
client: AuthenticatedClient,
|
119
119
|
environment: Union[Unset, str] = UNSET,
|
120
|
-
) -> Response[
|
120
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
121
121
|
"""Get function metrics
|
122
122
|
|
123
123
|
Args:
|
@@ -129,7 +129,7 @@ async def asyncio_detailed(
|
|
129
129
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
130
130
|
|
131
131
|
Returns:
|
132
|
-
Response[
|
132
|
+
Response[ResourceEnvironmentMetrics]
|
133
133
|
"""
|
134
134
|
|
135
135
|
kwargs = _get_kwargs(
|
@@ -147,7 +147,7 @@ async def asyncio(
|
|
147
147
|
*,
|
148
148
|
client: AuthenticatedClient,
|
149
149
|
environment: Union[Unset, str] = UNSET,
|
150
|
-
) -> Optional[
|
150
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
151
151
|
"""Get function metrics
|
152
152
|
|
153
153
|
Args:
|
@@ -159,7 +159,7 @@ async def asyncio(
|
|
159
159
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
160
160
|
|
161
161
|
Returns:
|
162
|
-
|
162
|
+
ResourceEnvironmentMetrics
|
163
163
|
"""
|
164
164
|
|
165
165
|
return (
|
@@ -5,7 +5,7 @@ import httpx
|
|
5
5
|
|
6
6
|
from ... import errors
|
7
7
|
from ...client import AuthenticatedClient, Client
|
8
|
-
from ...models.
|
8
|
+
from ...models.resource_environment_metrics import ResourceEnvironmentMetrics
|
9
9
|
from ...types import UNSET, Response, Unset
|
10
10
|
|
11
11
|
|
@@ -31,9 +31,9 @@ def _get_kwargs(
|
|
31
31
|
|
32
32
|
def _parse_response(
|
33
33
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
34
|
-
) -> Optional[
|
34
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
35
35
|
if response.status_code == 200:
|
36
|
-
response_200 =
|
36
|
+
response_200 = ResourceEnvironmentMetrics.from_dict(response.json())
|
37
37
|
|
38
38
|
return response_200
|
39
39
|
if client.raise_on_unexpected_status:
|
@@ -44,7 +44,7 @@ def _parse_response(
|
|
44
44
|
|
45
45
|
def _build_response(
|
46
46
|
*, client: Union[AuthenticatedClient, Client], response: httpx.Response
|
47
|
-
) -> Response[
|
47
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
48
48
|
return Response(
|
49
49
|
status_code=HTTPStatus(response.status_code),
|
50
50
|
content=response.content,
|
@@ -58,7 +58,7 @@ def sync_detailed(
|
|
58
58
|
*,
|
59
59
|
client: AuthenticatedClient,
|
60
60
|
environment: Union[Unset, str] = UNSET,
|
61
|
-
) -> Response[
|
61
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
62
62
|
"""Get model metrics
|
63
63
|
|
64
64
|
Returns metrics for a model by name.
|
@@ -72,7 +72,7 @@ def sync_detailed(
|
|
72
72
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
73
73
|
|
74
74
|
Returns:
|
75
|
-
Response[
|
75
|
+
Response[ResourceEnvironmentMetrics]
|
76
76
|
"""
|
77
77
|
|
78
78
|
kwargs = _get_kwargs(
|
@@ -92,7 +92,7 @@ def sync(
|
|
92
92
|
*,
|
93
93
|
client: AuthenticatedClient,
|
94
94
|
environment: Union[Unset, str] = UNSET,
|
95
|
-
) -> Optional[
|
95
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
96
96
|
"""Get model metrics
|
97
97
|
|
98
98
|
Returns metrics for a model by name.
|
@@ -106,7 +106,7 @@ def sync(
|
|
106
106
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
107
107
|
|
108
108
|
Returns:
|
109
|
-
|
109
|
+
ResourceEnvironmentMetrics
|
110
110
|
"""
|
111
111
|
|
112
112
|
return sync_detailed(
|
@@ -121,7 +121,7 @@ async def asyncio_detailed(
|
|
121
121
|
*,
|
122
122
|
client: AuthenticatedClient,
|
123
123
|
environment: Union[Unset, str] = UNSET,
|
124
|
-
) -> Response[
|
124
|
+
) -> Response[ResourceEnvironmentMetrics]:
|
125
125
|
"""Get model metrics
|
126
126
|
|
127
127
|
Returns metrics for a model by name.
|
@@ -135,7 +135,7 @@ async def asyncio_detailed(
|
|
135
135
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
136
136
|
|
137
137
|
Returns:
|
138
|
-
Response[
|
138
|
+
Response[ResourceEnvironmentMetrics]
|
139
139
|
"""
|
140
140
|
|
141
141
|
kwargs = _get_kwargs(
|
@@ -153,7 +153,7 @@ async def asyncio(
|
|
153
153
|
*,
|
154
154
|
client: AuthenticatedClient,
|
155
155
|
environment: Union[Unset, str] = UNSET,
|
156
|
-
) -> Optional[
|
156
|
+
) -> Optional[ResourceEnvironmentMetrics]:
|
157
157
|
"""Get model metrics
|
158
158
|
|
159
159
|
Returns metrics for a model by name.
|
@@ -167,7 +167,7 @@ async def asyncio(
|
|
167
167
|
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
168
168
|
|
169
169
|
Returns:
|
170
|
-
|
170
|
+
ResourceEnvironmentMetrics
|
171
171
|
"""
|
172
172
|
|
173
173
|
return (
|
beamlit/functions/common.py
CHANGED
beamlit/functions/mcp/mcp.py
CHANGED
@@ -6,13 +6,14 @@ import pydantic
|
|
6
6
|
import pydantic_core
|
7
7
|
import requests
|
8
8
|
import typing_extensions as t
|
9
|
-
from beamlit.authentication.authentication import AuthenticatedClient
|
10
|
-
from beamlit.common.settings import get_settings
|
11
9
|
from langchain_core.tools.base import BaseTool, BaseToolkit, ToolException
|
12
10
|
from mcp.types import CallToolResult, ListToolsResult
|
13
11
|
from pydantic.json_schema import JsonSchemaValue
|
14
12
|
from pydantic_core import core_schema as cs
|
15
13
|
|
14
|
+
from beamlit.authentication.authentication import AuthenticatedClient
|
15
|
+
from beamlit.common.settings import get_settings
|
16
|
+
|
16
17
|
settings = get_settings()
|
17
18
|
|
18
19
|
TYPE_MAP = {
|