| 1 | # Model manifest |
| 2 | |
| 3 | The [bundled manifest](../../apps/server/src/provider/model-manifest.json) allows |
| 4 | offline startup; fetching it from `main` lets model metadata change between |
| 5 | releases. Failed fetches or invalid data preserve the last usable manifest. |
| 6 | Remote data must pass both catalog-reference validation and the owning provider's |
| 7 | adapter validation before replacing the cache. |
| 8 | |
| 9 | A newer bundle outranks the cached remote manifest by `updatedAt`, so a release can |
| 10 | correct model data before the next successful fetch. Bump `updatedAt` whenever the |
| 11 | file changes. Fetch time cannot establish which copy contains the newer edit. |
| 12 | |
| 13 | Generic catalog data describes presentation and capabilities. Each provider owns |
| 14 | its adapter schema and dispatch mappings. Providers never read the manifest |
| 15 | itself: the server exposes each driver's entry through the |
| 16 | [`ModelCatalog`](../../packages/provider-core/src/server/ModelCatalog.ts) port, |
| 17 | and compatibility policies stay with the server. Claude uses the manifest for its entire |
| 18 | built-in catalog. Adding a model with an existing capability profile is a JSON |
| 19 | edit; a new profile is needed only for a new capability combination. Codex still |
| 20 | gets its model list from its app server. |
| 21 | |
| 22 | A model that needs a newer provider CLI should still be announced as soon as it |
| 23 | ships. Claude entries set `adapter.claudeCode.minVersion`; Codex entries set |
| 24 | `adapter.codex.minVersion`, since Codex's own `model/list` cannot name models |
| 25 | released after the installed build. Snapshots report those models in |
| 26 | `updateRequiredModels`, and the picker tells the user which update unlocks them. |
| 27 | |
| 28 | `currentModels.claudeAgent` is the current-model classification overlay for |
| 29 | releases that predate catalog discovery; it does not add models to their catalogs. |
| 30 | Catalog-aware releases use `providers.claudeAgent.models[].status` instead. |
| 31 | Codex uses `currentModels.codex` as a legacy-classification overlay for discovered |
| 32 | models. |
| 33 | |
| 34 | Model data is schema-validated configuration. Tests should cover resolver, cache, |
| 35 | and adapter semantics with synthetic model names, so adding a model never requires |
| 36 | tests that repeat the configuration. |