From 20c527eded7edb53500970ea2b1550f92d650a88 Mon Sep 17 00:00:00 2001 From: Sai Soundararaj Date: Tue, 1 Jul 2025 17:26:40 -0700 Subject: [PATCH] a --- api_update_plan.md | 6 +++--- docs/_static/llama-stack-spec.html | 24 ++++++++++++++++-------- docs/_static/llama-stack-spec.yaml | 12 ++++++++++++ llama_stack/apis/providers/providers.py | 12 ++++++++++++ 4 files changed, 43 insertions(+), 11 deletions(-) diff --git a/api_update_plan.md b/api_update_plan.md index 026156bbd..cef3c470d 100644 --- a/api_update_plan.md +++ b/api_update_plan.md @@ -238,9 +238,9 @@ Before finalizing documentation, verify: [x] 17. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/shields/shields.py` - Safety shields [x] 18. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/batch_inference/batch_inference.py` - Batch inference operations [x] 19. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/synthetic_data_generation/synthetic_data_generation.py` - Data generation -20. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/telemetry/telemetry.py` - Telemetry and monitoring -21. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/providers/providers.py` - Provider management -22. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/inspect/inspect.py` - System inspection +[x] 20. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/providers/providers.py` - Provider management +21. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/inspect/inspect.py` - System inspection +22. `/Users/saip/Documents/GitHub/llama-stack/llama_stack/apis/telemetry/telemetry.py` - Telemetry and monitoring **Step 1: Existing Documentation Assessment** - **Priority**: Review all @json_schema_type classes and @webmethod functions for docstring completeness diff --git a/docs/_static/llama-stack-spec.html b/docs/_static/llama-stack-spec.html index 6b59a3e25..7f1610ff4 100644 --- a/docs/_static/llama-stack-spec.html +++ b/docs/_static/llama-stack-spec.html @@ -11694,13 +11694,16 @@ "type": "object", "properties": { "api": { - "type": "string" + "type": "string", + "description": "The API name this provider implements" }, "provider_id": { - "type": "string" + "type": "string", + "description": "Unique identifier for the provider" }, "provider_type": { - "type": "string" + "type": "string", + "description": "The type of provider implementation" }, "config": { "type": "object", @@ -11725,7 +11728,8 @@ "type": "object" } ] - } + }, + "description": "Configuration parameters for the provider" }, "health": { "type": "object", @@ -11750,7 +11754,8 @@ "type": "object" } ] - } + }, + "description": "Current health status of the provider" } }, "additionalProperties": false, @@ -11761,7 +11766,8 @@ "config", "health" ], - "title": "ProviderInfo" + "title": "ProviderInfo", + "description": "Information about a registered provider including its configuration and health status." }, "InvokeToolRequest": { "type": "object", @@ -12200,14 +12206,16 @@ "type": "array", "items": { "$ref": "#/components/schemas/ProviderInfo" - } + }, + "description": "List of provider information objects" } }, "additionalProperties": false, "required": [ "data" ], - "title": "ListProvidersResponse" + "title": "ListProvidersResponse", + "description": "Response containing a list of all available providers." }, "RouteInfo": { "type": "object", diff --git a/docs/_static/llama-stack-spec.yaml b/docs/_static/llama-stack-spec.yaml index 0c576b7c9..5fddd1449 100644 --- a/docs/_static/llama-stack-spec.yaml +++ b/docs/_static/llama-stack-spec.yaml @@ -8441,10 +8441,13 @@ components: properties: api: type: string + description: The API name this provider implements provider_id: type: string + description: Unique identifier for the provider provider_type: type: string + description: The type of provider implementation config: type: object additionalProperties: @@ -8455,6 +8458,8 @@ components: - type: string - type: array - type: object + description: >- + Configuration parameters for the provider health: type: object additionalProperties: @@ -8465,6 +8470,7 @@ components: - type: string - type: array - type: object + description: Current health status of the provider additionalProperties: false required: - api @@ -8473,6 +8479,9 @@ components: - config - health title: ProviderInfo + description: >- + Information about a registered provider including its configuration and health + status. InvokeToolRequest: type: object properties: @@ -8787,10 +8796,13 @@ components: type: array items: $ref: '#/components/schemas/ProviderInfo' + description: List of provider information objects additionalProperties: false required: - data title: ListProvidersResponse + description: >- + Response containing a list of all available providers. RouteInfo: type: object properties: diff --git a/llama_stack/apis/providers/providers.py b/llama_stack/apis/providers/providers.py index 4bc977bf1..bcf3f30ce 100644 --- a/llama_stack/apis/providers/providers.py +++ b/llama_stack/apis/providers/providers.py @@ -14,6 +14,14 @@ from llama_stack.schema_utils import json_schema_type, webmethod @json_schema_type class ProviderInfo(BaseModel): + """Information about a registered provider including its configuration and health status. + + :param api: The API name this provider implements + :param provider_id: Unique identifier for the provider + :param provider_type: The type of provider implementation + :param config: Configuration parameters for the provider + :param health: Current health status of the provider + """ api: str provider_id: str provider_type: str @@ -22,6 +30,10 @@ class ProviderInfo(BaseModel): class ListProvidersResponse(BaseModel): + """Response containing a list of all available providers. + + :param data: List of provider information objects + """ data: list[ProviderInfo]