Never stop coding. Free MIT AI gateway: one endpoint, 375 providers (150+ free), 1,400+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 900+ contributors
TypeScript a2aai-agentsai-gatewayanthropicclaudeclaude-codeclinecodexcopilotcursordeepseekfree-aigeminikimillm-gatewaymcpopenaiopenai-proxyqwentoken-saver
fix(batch): round-3 polish — wizard Enter BUTTON exclusion, deriveProvider chatgpt-/o-series + i18n, useRef race guard
diegosouzapwa7d9c803d6db
diff --git a/src/app/(dashboard)/dashboard/batch/BatchListTab.tsx b/src/app/(dashboard)/dashboard/batch/BatchListTab.tsxindex 6b20d13260..bfd81273b2 100644--- a/src/app/(dashboard)/dashboard/batch/BatchListTab.tsx+++ b/src/app/(dashboard)/dashboard/batch/BatchListTab.tsx@@ -94,15 +94,28 @@ const STATUS_STYLES: Record<string, string> = {expired_with_failures: "bg-orange-500/15 text-orange-400 border-orange-500/25",};-// A-1 — Derive Provider label from model id (no provider field on BatchRecord).-// Heuristic-only display; no filter side-effect. Returns "—" for unknown shapes.-function deriveProvider(model: string | null | undefined): string {- if (!model) return "—";+// A-1 / R2 — Derive Provider label from model id (no provider field on BatchRecord).+// Heuristic-only display; no filter side-effect. Vendor names are proper nouns and+// stay un-translated; "other" / "unknown" return discriminators so the call-site can+// translate via t() — keeps function pure & free of next-intl coupling.+type ProviderLabel = "OpenAI" | "Anthropic" | "Gemini" | "other" | "unknown";+function deriveProvider(model: string | null | undefined): ProviderLabel {+ if (!model) return "unknown";const lower = model.toLowerCase();- if (lower.startsWith("gpt-") || lower.startsWith("o1") || lower.startsWith("o3") || lower.startsWith("text-embedding-") || lower.startsWith("dall-e")) return "OpenAI";+ // OpenAI family: gpt-*, chatgpt-*, o-series (o1/o3/o4 + suffixes), embeddings, DALL·E+ if (+ lower.startsWith("gpt-") ||+ lower.startsWith("chatgpt-") ||+ /^o[1-9](?:-|$)/.test(lower) ||+ lower.startsWith("text-embedding-") ||+ lower.startsWith("dall-e") ||+ lower.startsWith("whisper") ||+ lower.startsWith("tts-")+ )+ return "OpenAI";if (lower.startsWith("claude-")) return "Anthropic";if (lower.startsWith("gemini")) return "Gemini";- return "Other";+ return "other";}const STATUS_LABELS: Record<string, string> = {@@ -462,7 +475,12 @@ export default function BatchListTab({</span></td><td className="px-4 py-3 text-[var(--color-text-main)] text-xs whitespace-nowrap">- {deriveProvider(batch.model)}+ {(() => {+ const p = deriveProvider(batch.model);+ if (p === "unknown") return t("batchListProviderUnknown");+ if (p === "other") return t("batchListProviderOther");+ return p;+ })()}</td><td className="px-4 py-3 text-[var(--color-text-main)] text-xs">{batch.endpoint}diff --git a/src/app/(dashboard)/dashboard/batch/components/NewBatchWizard.tsx b/src/app/(dashboard)/dashboard/batch/components/NewBatchWizard.tsxindex 836b184e03..eb24f60f05 100644--- a/src/app/(dashboard)/dashboard/batch/components/NewBatchWizard.tsx+++ b/src/app/(dashboard)/dashboard/batch/components/NewBatchWizard.tsx@@ -166,8 +166,11 @@ export default function NewBatchWizard({}if (e.key === "Enter") {const tag = (e.target as HTMLElement | null)?.tagName;- if (tag === "INPUT" || tag === "TEXTAREA" || tag === "SELECT") return;- // canGoNext lives below; compute lazily via reading the disabled state of the Next button+ // Skip form controls (typing) AND buttons — a focused button (Next/Back/Cancel/+ // Create) already activates natively on Enter; firing the global Next click too+ // would double-dispatch and conflict with Back/Cancel. Only advance when focus is+ // on a non-interactive element (the modal body).+ if (tag === "INPUT" || tag === "TEXTAREA" || tag === "SELECT" || tag === "BUTTON") return;const nextBtn = document.querySelector<HTMLButtonElement>('button[data-wizard-next="true"]');diff --git a/src/app/(dashboard)/dashboard/batch/components/wizard/InputStep.tsx b/src/app/(dashboard)/dashboard/batch/components/wizard/InputStep.tsxindex a777dea7a9..5460cd51a3 100644--- a/src/app/(dashboard)/dashboard/batch/components/wizard/InputStep.tsx+++ b/src/app/(dashboard)/dashboard/batch/components/wizard/InputStep.tsx@@ -36,6 +36,9 @@ export default function InputStep({ input, onChange, destination }: InputStepProconst fileInputRef = useRef<HTMLInputElement>(null);const [isDragging, setIsDragging] = useState(false);const [isReading, setIsReading] = useState(false);+ // B-2b — synchronous stale-proof guard for concurrent drops/picks in the same+ // event-loop tick (React state lags behind dispatches within a tick).+ const isReadingRef = useRef(false);const [csvJsonl, setCsvJsonl] = useState<string | null>(null);const isJsonl = input.kind === "jsonl";@@ -47,8 +50,11 @@ export default function InputStep({ input, onChange, destination }: InputStepPro}async function processFile(file: File) {- // B-2 race guard — ignore concurrent drops while a read is in flight- if (isReading) return;+ // B-2/B-2b race guard — ref is checked & flipped synchronously so concurrent+ // calls in the same tick (e.g. drop + file-input-change firing back-to-back)+ // cannot both pass. State mirror is for UI only.+ if (isReadingRef.current) return;+ isReadingRef.current = true;const expectedExt = isJsonl ? ".jsonl" : ".csv";if (!file.name.toLowerCase().endsWith(expectedExt)) {// Soft warning — don't block, let validation catch it@@ -65,6 +71,7 @@ export default function InputStep({ input, onChange, destination }: InputStepPro} catch (err) {console.error("[InputStep] file read error:", err);} finally {+ isReadingRef.current = false;setIsReading(false);}}diff --git a/src/i18n/messages/ar.json b/src/i18n/messages/ar.jsonindex 2934258984..987cd5b9f7 100644--- a/src/i18n/messages/ar.json+++ b/src/i18n/messages/ar.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "الصفحة الرئيسية",diff --git a/src/i18n/messages/az.json b/src/i18n/messages/az.jsonindex 017b73fa58..218b2af1cc 100644--- a/src/i18n/messages/az.json+++ b/src/i18n/messages/az.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/bg.json b/src/i18n/messages/bg.jsonindex adfc59487e..656ef57d35 100644--- a/src/i18n/messages/bg.json+++ b/src/i18n/messages/bg.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Начало",diff --git a/src/i18n/messages/bn.json b/src/i18n/messages/bn.jsonindex 18ba8900d7..8fd809f1b5 100644--- a/src/i18n/messages/bn.json+++ b/src/i18n/messages/bn.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/cs.json b/src/i18n/messages/cs.jsonindex 7a6609d998..ab27fc81e3 100644--- a/src/i18n/messages/cs.json+++ b/src/i18n/messages/cs.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Domov",diff --git a/src/i18n/messages/da.json b/src/i18n/messages/da.jsonindex d7ca7d579e..37dc812fb1 100644--- a/src/i18n/messages/da.json+++ b/src/i18n/messages/da.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Hjem",diff --git a/src/i18n/messages/de.json b/src/i18n/messages/de.jsonindex bb79e61c4a..6f04c6b5a5 100644--- a/src/i18n/messages/de.json+++ b/src/i18n/messages/de.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Zuhause",diff --git a/src/i18n/messages/en.json b/src/i18n/messages/en.jsonindex 5c703212ce..31285fc918 100644--- a/src/i18n/messages/en.json+++ b/src/i18n/messages/en.json@@ -780,6 +780,7 @@"batchListProgressPartial": "(partial)","batchListProviderColumn": "Provider","batchListProviderUnknown": "—",+ "batchListProviderOther": "Other","batchListBatchCreated": "Batch {id} created — refreshing list…","batchListBatchCreatedDismiss": "Dismiss","batchListRefreshing": "Refreshing…",diff --git a/src/i18n/messages/es.json b/src/i18n/messages/es.jsonindex 7b2f9e49b4..048ae9b237 100644--- a/src/i18n/messages/es.json+++ b/src/i18n/messages/es.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Inicio",diff --git a/src/i18n/messages/fa.json b/src/i18n/messages/fa.jsonindex e794379656..25083c122c 100644--- a/src/i18n/messages/fa.json+++ b/src/i18n/messages/fa.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/fi.json b/src/i18n/messages/fi.jsonindex e874b902d0..9e2c4964d6 100644--- a/src/i18n/messages/fi.json+++ b/src/i18n/messages/fi.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Kotiin",diff --git a/src/i18n/messages/fr.json b/src/i18n/messages/fr.jsonindex 7a9f43b4bb..4650ce90cc 100644--- a/src/i18n/messages/fr.json+++ b/src/i18n/messages/fr.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Accueil",diff --git a/src/i18n/messages/gu.json b/src/i18n/messages/gu.jsonindex 7668f36d87..87bde5e1bd 100644--- a/src/i18n/messages/gu.json+++ b/src/i18n/messages/gu.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/he.json b/src/i18n/messages/he.jsonindex a80d0537dd..f5a2cff266 100644--- a/src/i18n/messages/he.json+++ b/src/i18n/messages/he.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "בית",diff --git a/src/i18n/messages/hi.json b/src/i18n/messages/hi.jsonindex 2b97a1548a..8afc71d568 100644--- a/src/i18n/messages/hi.json+++ b/src/i18n/messages/hi.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "घर",diff --git a/src/i18n/messages/hu.json b/src/i18n/messages/hu.jsonindex 588ccc834c..53e50b0b3b 100644--- a/src/i18n/messages/hu.json+++ b/src/i18n/messages/hu.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Otthon",diff --git a/src/i18n/messages/id.json b/src/i18n/messages/id.jsonindex 504ecfcadf..ad610c22ec 100644--- a/src/i18n/messages/id.json+++ b/src/i18n/messages/id.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Rumah",diff --git a/src/i18n/messages/in.json b/src/i18n/messages/in.jsonindex b4ceba21a2..df40f51ddf 100644--- a/src/i18n/messages/in.json+++ b/src/i18n/messages/in.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/it.json b/src/i18n/messages/it.jsonindex 542d48370c..ba2f2b22d9 100644--- a/src/i18n/messages/it.json+++ b/src/i18n/messages/it.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Casa",diff --git a/src/i18n/messages/ja.json b/src/i18n/messages/ja.jsonindex 131c4c8fc2..6410b0a052 100644--- a/src/i18n/messages/ja.json+++ b/src/i18n/messages/ja.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "ホーム",diff --git a/src/i18n/messages/ko.json b/src/i18n/messages/ko.jsonindex e5ad754a58..176bcdad88 100644--- a/src/i18n/messages/ko.json+++ b/src/i18n/messages/ko.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "홈",diff --git a/src/i18n/messages/mr.json b/src/i18n/messages/mr.jsonindex 216fdf9ec8..6c00b95ac9 100644--- a/src/i18n/messages/mr.json+++ b/src/i18n/messages/mr.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/ms.json b/src/i18n/messages/ms.jsonindex 589e30cf63..41a1866db0 100644--- a/src/i18n/messages/ms.json+++ b/src/i18n/messages/ms.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Rumah",diff --git a/src/i18n/messages/nl.json b/src/i18n/messages/nl.jsonindex 54cadac8a2..21185ebf1e 100644--- a/src/i18n/messages/nl.json+++ b/src/i18n/messages/nl.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Thuis",diff --git a/src/i18n/messages/no.json b/src/i18n/messages/no.jsonindex e4cf3d04f0..e4c699df74 100644--- a/src/i18n/messages/no.json+++ b/src/i18n/messages/no.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Hjem",diff --git a/src/i18n/messages/phi.json b/src/i18n/messages/phi.jsonindex c4a9ba78cf..de0612cbd5 100644--- a/src/i18n/messages/phi.json+++ b/src/i18n/messages/phi.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Bahay",diff --git a/src/i18n/messages/pl.json b/src/i18n/messages/pl.jsonindex eee5f1e1b6..3bfab35867 100644--- a/src/i18n/messages/pl.json+++ b/src/i18n/messages/pl.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Dom",diff --git a/src/i18n/messages/pt-BR.json b/src/i18n/messages/pt-BR.jsonindex e8ce517048..3d2fced7e5 100644--- a/src/i18n/messages/pt-BR.json+++ b/src/i18n/messages/pt-BR.json@@ -780,6 +780,7 @@"batchListProgressPartial": "(parcial)","batchListProviderColumn": "Provedor","batchListProviderUnknown": "—",+ "batchListProviderOther": "Outro","batchListBatchCreated": "Batch {id} criado — atualizando lista…","batchListBatchCreatedDismiss": "Fechar","batchListRefreshing": "Atualizando…",diff --git a/src/i18n/messages/pt.json b/src/i18n/messages/pt.jsonindex 0db1317aef..9e23893878 100644--- a/src/i18n/messages/pt.json+++ b/src/i18n/messages/pt.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Página inicial",diff --git a/src/i18n/messages/ro.json b/src/i18n/messages/ro.jsonindex 45752dea0d..e4c9205615 100644--- a/src/i18n/messages/ro.json+++ b/src/i18n/messages/ro.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Acasă",diff --git a/src/i18n/messages/ru.json b/src/i18n/messages/ru.jsonindex b530cf2cb9..3445d01344 100644--- a/src/i18n/messages/ru.json+++ b/src/i18n/messages/ru.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Главная",diff --git a/src/i18n/messages/sk.json b/src/i18n/messages/sk.jsonindex 21bb8d0968..e1eeff849c 100644--- a/src/i18n/messages/sk.json+++ b/src/i18n/messages/sk.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Domov",diff --git a/src/i18n/messages/sv.json b/src/i18n/messages/sv.jsonindex 40972219d0..4af32bb54e 100644--- a/src/i18n/messages/sv.json+++ b/src/i18n/messages/sv.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Hem",diff --git a/src/i18n/messages/sw.json b/src/i18n/messages/sw.jsonindex 461657eb96..ed2d093d5c 100644--- a/src/i18n/messages/sw.json+++ b/src/i18n/messages/sw.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/ta.json b/src/i18n/messages/ta.jsonindex 59f3643af0..91f5d4305c 100644--- a/src/i18n/messages/ta.json+++ b/src/i18n/messages/ta.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/te.json b/src/i18n/messages/te.jsonindex ce3e0e3322..0b25bf0cad 100644--- a/src/i18n/messages/te.json+++ b/src/i18n/messages/te.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/th.json b/src/i18n/messages/th.jsonindex 284b3d894d..524d626d31 100644--- a/src/i18n/messages/th.json+++ b/src/i18n/messages/th.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "บ้าน",diff --git a/src/i18n/messages/tr.json b/src/i18n/messages/tr.jsonindex 7d13608297..4d993a6dca 100644--- a/src/i18n/messages/tr.json+++ b/src/i18n/messages/tr.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Ana Sayfa",diff --git a/src/i18n/messages/uk-UA.json b/src/i18n/messages/uk-UA.jsonindex 1afee0ac76..3cf651d3a8 100644--- a/src/i18n/messages/uk-UA.json+++ b/src/i18n/messages/uk-UA.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "додому",diff --git a/src/i18n/messages/ur.json b/src/i18n/messages/ur.jsonindex 00e06ddd3b..e44c6e8fbb 100644--- a/src/i18n/messages/ur.json+++ b/src/i18n/messages/ur.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Home",diff --git a/src/i18n/messages/vi.json b/src/i18n/messages/vi.jsonindex f134a518ef..c9c855630e 100644--- a/src/i18n/messages/vi.json+++ b/src/i18n/messages/vi.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "Trang chủ",diff --git a/src/i18n/messages/zh-CN.json b/src/i18n/messages/zh-CN.jsonindex 18fcc19c80..133474a0d9 100644--- a/src/i18n/messages/zh-CN.json+++ b/src/i18n/messages/zh-CN.json@@ -802,7 +802,8 @@"wizardInputCsvJsonlReady": "JSONL generated — ready to validate.","wizardInputLargeFileWarning": "Large file detected — validation runs by sampling (first 5 MB + last 100 KB). Full validation happens server-side.","wizardCostWindow24h": "24h completion window",- "wizardValidationFieldsOk": "required fields valid"+ "wizardValidationFieldsOk": "required fields valid",+ "batchListProviderOther": "Other"},"sidebar": {"home": "首页",diff --git a/tests/unit/dashboard/batch/list-regression.test.tsx b/tests/unit/dashboard/batch/list-regression.test.tsxindex 3fcedf8b2d..4689151244 100644--- a/tests/unit/dashboard/batch/list-regression.test.tsx+++ b/tests/unit/dashboard/batch/list-regression.test.tsx@@ -320,6 +320,37 @@ describe("BatchListTab — rendering", () => {expect(text).toContain("Anthropic");expect(text).toContain("Gemini");});++ it("19. Provider derivation handles OpenAI variants: chatgpt-* and o-series (R2)", () => {+ const batches = [+ makeBatch({ id: "b-chatgpt", model: "chatgpt-4o-latest", status: "completed" }),+ makeBatch({ id: "b-o1", model: "o1-preview", status: "completed" }),+ makeBatch({ id: "b-o3", model: "o3-mini", status: "completed" }),+ ];+ const el = render(+ <BatchListTab batches={batches} files={[]} loading={false} />+ );+ const text = el.textContent ?? "";+ // All three are OpenAI families — the column should print "OpenAI" three times.+ const occurrences = (text.match(/OpenAI/g) ?? []).length;+ expect(occurrences).toBeGreaterThanOrEqual(3);+ });++ it("20. Provider derivation routes unknown / null model through i18n keys (R2)", () => {+ const batches = [+ makeBatch({ id: "b-unknown-model", model: "weird-model-name-not-recognized", status: "completed" }),+ // makeBatch's default model is gpt-4o; explicitly null-ish models below+ makeBatch({ id: "b-null-model", model: "", status: "completed" }),+ ];+ const el = render(+ <BatchListTab batches={batches} files={[]} loading={false} />+ );+ const text = el.textContent ?? "";+ // i18n mock returns the key literal — proves we route through t() and+ // didn't leave hardcoded "Other" / "—" English strings in the cell.+ expect(text).toContain("batchListProviderOther");+ expect(text).toContain("batchListProviderUnknown");+ });});// ── FilesListTab ──────────────────────────────────────────────────────────────