From b2a00a0d2aef255737b30561719576a0e9ab4eb8 Mon Sep 17 00:00:00 2001 From: frob Date: Thu, 17 Jul 2025 12:31:49 +0800 Subject: [PATCH] openai: allow openai endpoint to accept webp images (#11412) Co-authored-by: Richard Lyons --- openai/openai.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openai/openai.go b/openai/openai.go index 012189d23..35b8b9a01 100644 --- a/openai/openai.go +++ b/openai/openai.go @@ -423,7 +423,7 @@ func fromChatRequest(r ChatCompletionRequest) (*api.ChatRequest, error) { } } - types := []string{"jpeg", "jpg", "png"} + types := []string{"jpeg", "jpg", "png", "webp"} valid := false for _, t := range types { prefix := "data:image/" + t + ";base64,"