diff --git a/backend/open_webui/routers/ollama.py b/backend/open_webui/routers/ollama.py index 64373c616..4fca10e1f 100644 --- a/backend/open_webui/routers/ollama.py +++ b/backend/open_webui/routers/ollama.py @@ -944,7 +944,7 @@ class ChatMessage(BaseModel): class GenerateChatCompletionForm(BaseModel): model: str messages: list[ChatMessage] - format: Optional[dict] = None + format: Optional[Union[dict, str]] = None options: Optional[dict] = None template: Optional[str] = None stream: Optional[bool] = True