Skip to content
This repository was archived by the owner on Aug 12, 2025. It is now read-only.

feat: provider update #219

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

cdoern
Copy link
Contributor

@cdoern cdoern commented Apr 8, 2025

What does this PR do?

add v1/providers/ client handling which uses PUT to allow users to change their provider configuration

this is a follow up to #1429 and related to #1359

a user can call something like:

llama_stack_client.providers.update(api="inference", provider_id="ollama", provider_type="remote::ollama", config={'url': 'http:/localhost:12345'})

or

llama-stack-client providers update inference ollama remote::ollama "{'url': 'http://localhost:12345'}"

this API works by adding a RequestMiddleware to the server which checks requests, and if the user is using PUT /v1/providers, the routes are re-registered with the re-initialized provider configurations/methods

Test Plan

see meta-llama/llama-stack#1905

add v1/providers/ client handling which uses PUT to allow users to change their provider configuration

this is a follow up to #1429 and related to #1359

a user can call something like:

llama_stack_client.providers.update(api="inference", provider_id="ollama", provider_type="remote::ollama", config={'url': 'http:/localhost:12345'})

or

llama-stack-client providers update inference ollama remote::ollama "{'url': 'http://localhost:12345'}"

this API works by adding a RequestMiddleware to the server which checks requests, and if the user is using PUT /v1/providers, the routes are re-registered with the re-initialized provider configurations/methods

Signed-off-by: Charlie Doern <[email protected]>
@nathan-weinberg
Copy link

@cdoern you're going to want to close this and reopen it in https://github.com/llamastack/llama-stack-client-python

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants