Source Intelligence

DisclaimerUnofficial, and not affiliated with Anthropic. Nearly all of this is read straight out of what ships: npm bundles, captured prompts, published docs. Anthropic's own notes go in verbatim, marked as theirs. The rest is my reading, and every entry carries the strings behind it. If one looks wrong, vote it down and say why.

All of v2.1.197 Home All releases olderv2.1.196 v2.1.198newer
Claude Code v2.1.197

Alias-to-Canonical-ID Resolution for Persisted Model Preferences

What

Model alias matching now uses a canonical wire model ID to let hosts correctly match a stored explicit model ID (e.g., a saved claude-sonnet-4-6) against the alias row that covers it, surviving model transitions without breaking saved settings.

Details
  • New resolvedModel field (previously documented as canonicalId) in the model row schema: "Canonical wire model id this row's value resolves to (e.g. 'sonnet' → 'claude-sonnet-5'). Lets hosts match a persisted explicit id against the alias row that covers it." — populated by Y4t() via Bo(value), which resolves an alias to its concrete wire model ID
  • New cda(options, persistedId) function: if persistedId already exists verbatim in the option list it is returned unchanged; otherwise a z4t() scan finds a covering alias by checking in order — exact value match, fable-family membership, same model family AND (same 1M-context flag OR model is natively 1M-capable)
  • When cda() finds a match it returns the alias option's value (e.g., "sonnet"), so the picker highlights the correct alias row for the persisted model; if no alias covers the persisted ID the call-site expression cda(options, initial) ?? initial keeps the original persisted value as the initial selection rather than discarding it
Evidence

Schema field resolvedModel and description (search for "Canonical wire model id this row's"); cda(e, t) function definition; z4t() matcher (search for "Lets hosts match a persisted explicit id")

Strings lifted out of the shipped bundle, so the claim above can be checked against them.

See this entry in the whole of v2.1.197 →