From 696d078959c17c769776a239dc5c4d5d3c6b16d8 Mon Sep 17 00:00:00 2001 From: Teknium <127238744+teknium1@users.noreply.github.com> Date: Thu, 10 Sep 2026 03:37:28 -0700 Subject: [PATCH] fix(deepseek): only fold deepseek-* spellings onto deepseek-flash Names outside the family (qwen3.8-max typed on the DeepSeek provider) now pass through so the validator rejects them, instead of silently running Flash under a different label. --- hermes_cli/model_normalize.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/hermes_cli/model_normalize.py b/hermes_cli/model_normalize.py index 323420d881..fe05f79670 100644 --- a/hermes_cli/model_normalize.py +++ b/hermes_cli/model_normalize.py @@ -105,12 +105,13 @@ _DEEPSEEK_V_SERIES_RE = re.compile(r"^deepseek-v\d+([-.].+)?$") def _normalize_for_deepseek(model_name: str) -> str: """Map a model input to a DeepSeek-accepted id: canonicals and ``deepseek-v…`` pass - through (dated variants and future V-series work without a release); retired aliases and - everything else become ``deepseek-flash``.""" + through (dated variants and future V-series work without a release); retired aliases and other + ``deepseek-*`` spellings become ``deepseek-flash``. Names outside the family pass through + untouched so the validator can reject them instead of silently running Flash.""" bare = _strip_vendor_prefix(model_name).lower() if bare in _DEEPSEEK_CANONICAL_MODELS or _DEEPSEEK_V_SERIES_RE.match(bare): return bare - return "deepseek-flash" + return "deepseek-flash" if bare.startswith("deepseek") else bare def _strip_vendor_prefix(model_name: str) -> str: