Skip to content

Commit 7ae2ea9

Browse files
committed
feat: introduce /admin API for stack administration and operations
- Add new /admin API (v1alpha) for administrative operations including provider management, health checks, version info, and route listing - Implement using FastAPI routers following batches pattern with proper request/response models - Endpoints: /admin/providers, /admin/providers/{id}, /admin/inspect/routes, /admin/health, /admin/version - Create admin module structure: models.py, api.py, fastapi_routes.py, __init__.py - Add AdminImpl in llama_stack/core combining provider and inspect functionality - Deprecate standalone /providers and /inspect APIs (remain functional for backward compatibility) - Consolidate duplicate types: ProviderInfo, HealthInfo, RouteInfo, etc. now defined once in admin.models - Test new API using Stainless SDK in integration tests Signed-off-by: Charlie Doern <[email protected]>
1 parent 66f3cf4 commit 7ae2ea9

File tree

22 files changed

+4954
-3674
lines changed

22 files changed

+4954
-3674
lines changed

client-sdks/stainless/config.yml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,12 @@ resources:
163163
sampling_params: SamplingParams
164164
scoring_result: ScoringResult
165165
system_message: SystemMessage
166+
health_info: HealthInfo
167+
provider_info: ProviderInfo
168+
list_providers_response: ListProvidersResponse
169+
route_info: RouteInfo
170+
list_routes_response: ListRoutesResponse
171+
version_info: VersionInfo
166172
toolgroups:
167173
models:
168174
tool_group: ToolGroup
@@ -261,11 +267,6 @@ resources:
261267
type: http
262268
endpoint: delete /v1/conversations/{conversation_id}/items/{item_id}
263269
inspect:
264-
models:
265-
healthInfo: HealthInfo
266-
providerInfo: ProviderInfo
267-
routeInfo: RouteInfo
268-
versionInfo: VersionInfo
269270
methods:
270271
health: get /v1/health
271272
version: get /v1/version
@@ -357,16 +358,12 @@ resources:
357358
paginated: false
358359
endpoint: get /v1/models
359360
providers:
360-
models:
361-
list_providers_response: ListProvidersResponse
362361
methods:
363362
list:
364363
paginated: false
365364
endpoint: get /v1/providers
366365
retrieve: get /v1/providers/{provider_id}
367366
routes:
368-
models:
369-
list_routes_response: ListRoutesResponse
370367
methods:
371368
list:
372369
paginated: false
@@ -474,6 +471,13 @@ resources:
474471
cancel: delete /v1alpha/eval/benchmarks/{benchmark_id}/jobs/{job_id}
475472
status: get /v1alpha/eval/benchmarks/{benchmark_id}/jobs/{job_id}
476473
retrieve: get /v1alpha/eval/benchmarks/{benchmark_id}/jobs/{job_id}/result
474+
admin:
475+
methods:
476+
list_providers: get /v1alpha/admin/providers
477+
inspect_provider: get /v1alpha/admin/providers/{provider_id}
478+
list_routes: get /v1alpha/admin/inspect/routes
479+
health: get /v1alpha/admin/health
480+
version: get /v1alpha/admin/version
477481
beta:
478482
subresources:
479483
datasets:

0 commit comments

Comments
 (0)