Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

fix: add model validation on Playground

Yuta Saito4ec6a827b462
diff --git a/ui/litellm-dashboard/src/components/playground/chat_ui/ChatUI.tsx b/ui/litellm-dashboard/src/components/playground/chat_ui/ChatUI.tsx
index 348a059b6d6..1cf9c7eb8df 100644
--- a/ui/litellm-dashboard/src/components/playground/chat_ui/ChatUI.tsx
+++ b/ui/litellm-dashboard/src/components/playground/chat_ui/ChatUI.tsx
@@ -748,8 +748,19 @@ const ChatUI: React.FC<ChatUIProps> = ({
return;
}
- // Require model selection for Responses API
- if (endpointType === EndpointType.RESPONSES && !selectedModel) {
+ // Require model selection for all model-based endpoints
+ const modelRequiredEndpoints = [
+ EndpointType.CHAT,
+ EndpointType.IMAGE,
+ EndpointType.SPEECH,
+ EndpointType.IMAGE_EDITS,
+ EndpointType.RESPONSES,
+ EndpointType.ANTHROPIC_MESSAGES,
+ EndpointType.EMBEDDINGS,
+ EndpointType.TRANSCRIPTION,
+ ];
+
+ if (modelRequiredEndpoints.includes(endpointType as EndpointType) && !selectedModel) {
NotificationsManager.fromBackend("Please select a model before sending a request");
return;
}