Feature Request: Pipeline Valves with discrete lists of options #96

Open
opened 2026-02-15 19:15:47 -05:00 by yindo · 4 comments
Owner

Originally created by @PlebeiusGaragicus on GitHub (Aug 10, 2024).

While working on LangGraph agents I noticed a new and useful feature in LangGraph Studio where configurable options can be given as a discrete list of possibilities.

Link to code example

# Define the config
class GraphConfig(TypedDict):
    model_name: Literal["anthropic", "openai"]

This code now tells LangGraph Studio to display these as a nice list in the UI.

I'm requesting that we also have the Pipelines Valve UI display a list of options as defined in the pipeline code itself. After looking through the examples I haven't noticed if this has been implemented yet and it would be very helpful.

Originally created by @PlebeiusGaragicus on GitHub (Aug 10, 2024). While working on LangGraph agents I noticed a new and useful feature in LangGraph Studio where configurable options can be given as a discrete list of possibilities. [Link to code example](https://github.com/langchain-ai/langgraph-example/blob/ecf328da62e3efc3270c16fb83e1f6725dd107d1/my_agent/agent.py#L10) ```python # Define the config class GraphConfig(TypedDict): model_name: Literal["anthropic", "openai"] ``` This code now tells LangGraph Studio to display these as a nice list in the UI. I'm requesting that we also have the Pipelines Valve UI display a list of options as defined in the pipeline code itself. After looking through the examples I haven't noticed if this has been implemented yet and it would be very helpful.
Author
Owner

@milafrerichs commented on GitHub (Nov 8, 2024):

this is already possible:

class Pipeline:
    class Valves(BaseModel):
        MODEL_NAME: Literal["anthropic", "openai"]
@milafrerichs commented on GitHub (Nov 8, 2024): this is already possible: ```python class Pipeline: class Valves(BaseModel): MODEL_NAME: Literal["anthropic", "openai"] ```
Author
Owner

@PlebeiusGaragicus commented on GitHub (May 10, 2025):

I can't seen to dynamically load a Literal type at runtime.

Is there a way to dynamically set a value on pipeline init?

@PlebeiusGaragicus commented on GitHub (May 10, 2025): I can't seen to dynamically load a Literal type at runtime. Is there a way to dynamically set a value on pipeline init?
Author
Owner

@Haervwe commented on GitHub (Oct 12, 2025):

Hi @PlebeiusGaragicus did you find a way to dinamycally add literals? It would be a really nice addition for example for model ids in valves

@Haervwe commented on GitHub (Oct 12, 2025): Hi @PlebeiusGaragicus did you find a way to dinamycally add literals? It would be a really nice addition for example for model ids in valves
Author
Owner

@PlebeiusGaragicus commented on GitHub (Oct 22, 2025):

@Haervwe no I’ve just about moved on. I’m not confident I can get a LangGraph agent working with open webui just yet and that was my use case. But they’re really cooking so I’m hopeful. Agents are the way…! OUI is getting closer

@PlebeiusGaragicus commented on GitHub (Oct 22, 2025): @Haervwe no I’ve just about moved on. I’m not confident I can get a LangGraph agent working with open webui just yet and that was my use case. But they’re really cooking so I’m hopeful. Agents are the way…! OUI is getting closer
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: open-webui/pipelines#96