Claude Code Unrecognized Model

Detect a fatal Claude Code harness model-configuration fault and abort early. Trigger when a run's stderr contains `claude-code:unrecognized_model` or the configured `model` field names an ID the CLI does not recognize (e.g. `deepseek-flash`), so the run would otherwise stall to its full timeout with no task artifacts.

ruc-nlpir Updated 23 repo stars

File contents

An unrecognized_model error is an environment/configuration fault, not a defect in the task implementation. When the session's model field names an ID the Claude Code CLI does not recognize (e.g. deepseek-flash), API calls fail and the run stalls to its full timeout (e.g. 900s) without producing the requested files.

Do:

  • Confirm the configured model early. If it is not a recognized Claude model, surface the mismatch and stop instead of spending the time budget.
  • If claude-code:unrecognized_model appears in stderr — it can surface on an auxiliary query such as generate_session_title — abort the run and report the configuration failure.
  • When a run times out, inspect stderr before judging the implementation: an unrecognized_model timeout is a configuration fault, not evidence about the task's implementation quality.

ruc-nlpir/flashrsi commit 53dee6d56c

Frequently asked questions

npx get-skill add ruc-nlpir/claude-code-unrecognized-model