{"version":"2.1.196","anchor":"model-catalog-refactoring","canonical_anchor":"model-catalog-refactoring","heading":"Model Catalog Refactoring","tier":null,"area":null,"scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.196\/e\/model-catalog-refactoring","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.196","markdown":"### Model Catalog Refactoring\n\nThe internal model catalog has been refactored from a large inline constants object to a data-driven catalog loaded from a shared source file. Model provider IDs are now derived from structured catalog entries via helper functions, and a validation step ensures all named config exports have non-null provider IDs for every supported platform.\n\n**Details**\n\n- The catalog object (`iQs`) is validated at runtime using a Zod schema (`sfd()`); if the parse fails the entire catalog silently falls back to an empty stub with `schema_version: 0` and no models.\n- A provider-ID reverse-lookup map (`lfd`) is built at startup by iterating all `provider_ids` values across all entries; if the same provider ID string appears in two distinct catalog entries the build throws a hard collision error.\n- Each entry carries: `id`, `family`, `display_name`, optional `knowledge_cutoff`, per-provider `provider_ids` (first_party, bedrock, vertex, foundry, anthropic_aws, mantle, gateway), `eager_input_streaming` per provider, `context` (`window` size and `supports_1m_beta` flag), `capabilities` array (e.g. `\"context_management\"`, `\"effort\"`, `\"adaptive_thinking\"`, `\"max_effort\"`), and optional `deprecation` (`retirement_dates`, `remapped_to`).\n- Top-level catalog fields include `aliases` (family-to-provider-ID mappings with optional per-provider overrides), `defaults`, `latest_per_family`, `alias_migration`, and `best`.\n- A build-time script (`bun run generate:model-catalog`) validates and formats the source JSON before bundling; the runtime parse is a second safety net for any drift.\n- This catalog is the authority consumed by the new alias resolution path (see Model Alias Resolution entry above).\n\n**Evidence**\n\nNew catalog loader (search for `\"Hand-maintained baked-in model catalog\"`) and schema (search for `\"model catalog: provider id collision across distinct entries\"`)"}