-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[Feature]: Dynamic reloading config file #964
Comments
cc: @chanwit |
"Our environment uses Kubernetes, and LLM instances are served by the LM-controller. When the LM-controller starts a new LLM instance, we want it to be automatically registered with a proxy. To achieve this, we plan to write a Kubernetes informer that monitors the creation and deletion of LLM instances, captures their endpoint information, and sends it to register the endpoint with the proxy, in this case, LiteLLM. For LiteLLM to support this dynamic endpoint discovery, it needs to implement endpoint registration and deregistration, such as POST and DELETE at /endpoints, allowing for on-the-fly alias and endpoint registration without restarting the proxy process. From a security standpoint, we would limit this endpoint to local access only, or possibly use a Unix socket." |
I'll update the thread once this is in prod. |
in prod in v |
Thank you for the ping @krrishdholakia Here's my take on the acceptance criteria for this feature.
|
@chanwit Here's how to use it: Step 1: Add a model with an id to your config.yaml model_list:
- model_name: "openai-model"
litellm_params:
model: "gpt-3.5-turbo"
model_info:
id: "my-model-id" Step 2: Start your proxy $ litellm /path/to/config.yaml Step 3: Make a POST
|
Let me know if this looks good to you Will update this ticket once the release is in prod. |
closing as this is now out |
Hi @krrishdholakia Sorry for the delayed response as I'm just testing this out now. Can you give a valid example of the POST request for a new model? Following the Swagger example, the following model: { Results in a server error: { It looks like a file is initially created, but model_info is a serialized python object: model_list:
Interestingly enough litellm_params is persisted ok, and both are passed into yaml.dump the same way in the config object |
that's concerning. Here's how i was testing it - litellm/litellm/tests/test_proxy_server.py Line 126 in a9f1039
I had to skip it on circle ci due to ci/fastapi issues. Thanks for flagging this, i'll have it fixed today + add better ci testing. |
fix pushed + testing added @ericblue |
will update this ticket once the fix is in prod. |
fix live v |
The Feature
"I'm searching for a way to perform dynamic model and endpoint discovery, as it's crucial for our ecosystem. It would be beneficial if LiteLLM allowed the dynamic reloading of the config file, for example. That would help a lot."
Motivation, pitch
user request
Twitter / LinkedIn details
No response
The text was updated successfully, but these errors were encountered: