mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-07 03:18:23 -05:00
feat: override Valves per-model #4348
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @kaytwo on GitHub (Mar 9, 2025).
Check Existing Issues
Problem Description
Current function configuration has two modalities:
Thus, if you want to create a filter that is customized per model, you need to copy-paste the underlying function code to a new copy of that function, give it a new name, and set the system level valves to a different configuration, and then instruct your users on which one they should be picking for a given configuration. This makes it hard to allow a large number of users to maintain and customize their own model configurations with various valves.
Desired Solution you'd like
Open-webui should allow system level valves to be overridden on a per-model level. This would require adding a user interface to enumerate and configure valves to the model edit page, a place to store them in model configuration, and back-end logic to expose the proper valve to the function on use.
Alternatives Considered
Additional Context
I would be willing to work on a PR to implement this.
@tjbck commented on GitHub (Mar 9, 2025):
You should be using Pipe function here.