Skip to content

feat: llama-stack-client providers inspect PROVIDER_ID #181

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 13, 2025

Conversation

cdoern
Copy link
Contributor

@cdoern cdoern commented Mar 5, 2025

What does this PR do?

allow a user to see certain parts of the provider configuration for a specified provider. This is the cli code corresponding to meta-llama/llama-stack#1429

This PR introduces:

  • llama-stack-client providers inspect
  • amends llama-stack-client providers list to use /v1/providers
  • GetProviderResponse to handle the response from these new API calls

allow a user to see certain parts of the provider configuration for a specified provider.

Signed-off-by: Charlie Doern <cdoern@redhat.com>
@ashwinb ashwinb merged commit 6d18aae into meta-llama:main Mar 13, 2025
2 checks passed
ashwinb pushed a commit to meta-llama/llama-stack that referenced this pull request Mar 13, 2025
# What does this PR do?

currently the `inspect` API for providers is really a `list` API. Create
a new `providers` API which has a GET `providers/{provider_id}` inspect
API
which returns "user friendly" configuration to the end user. Also add a
GET `/providers` endpoint which returns the list of providers as
`inspect/providers` does today.

This API follows CRUD and is more intuitive/RESTful.

This work is part of the RFC at
#1359

sensitive fields are redacted using `redact_sensetive_fields` on the
server side before returning a response:

<img width="456" alt="Screenshot 2025-03-13 at 4 40 21 PM"
src="https://github.com/user-attachments/assets/9465c221-2a26-42f8-a08a-6ac4a9fecce8"
/>


## Test Plan

using meta-llama/llama-stack-client-python#181 a
user is able to to run the following:

`llama stack build --template ollama --image-type venv`
`llama stack run --image-type venv
~/.llama/distributions/ollama/ollama-run.yaml`
`llama-stack-client providers inspect ollama`

<img width="378" alt="Screenshot 2025-03-13 at 4 39 35 PM"
src="https://github.com/user-attachments/assets/8273d05d-8bc3-44c6-9e4b-ef95e48d5466"
/>


also, was able to run the new test_list integration test locally with
ollama:

<img width="1509" alt="Screenshot 2025-03-13 at 11 03 40 AM"
src="https://github.com/user-attachments/assets/9b9db166-f02f-45b0-86a4-306d85149bc8"
/>

Signed-off-by: Charlie Doern <cdoern@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants