Skip to content

Commit 7a74ad7

Browse files
committed
Updated documentation
1 parent a263db1 commit 7a74ad7

1 file changed

Lines changed: 11 additions & 4 deletions

File tree

src/app/endpoints/models.py

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,18 +83,25 @@ async def models_endpoint_handler(
8383
Handle requests to the /models endpoint.
8484
8585
Process GET requests to the /models endpoint, returning a list of available
86-
models from the Llama Stack service.
86+
models from the Llama Stack service. It is possible to specify "model_type"
87+
query parameter that is used as a filter. For example, if model type is set
88+
to "llm", only LLM models will be returned:
8789
88-
Parameters:
90+
curl http://localhost:8080/v1/models?model_type=llm
91+
92+
The "model_type" query parameter is optional. When not specified, all models
93+
will be returned.
94+
95+
## Parameters:
8996
request: The incoming HTTP request.
9097
auth: Authentication tuple from the auth dependency.
9198
model_type: Optional filter to return only models matching this type.
9299
93-
Raises:
100+
## Raises:
94101
HTTPException: If unable to connect to the Llama Stack server or if
95102
model retrieval fails for any reason.
96103
97-
Returns:
104+
## Returns:
98105
ModelsResponse: An object containing the list of available models.
99106
"""
100107
# Used only by the middleware

0 commit comments

Comments
 (0)