Fill contextWindow, maxOutput, modalities, and request-feature capabilities on grain=provider catalogs #58
main fromrefs/pull/58/head·merged by tombeckenham View on GitHubPart of #53. Pricing, prose extraction, and spec-sync re-walk stay on that issue.
What#
Native /models payloads publish none of these facts (OpenAI, xAI), or only token limits plus a capability tree (Anthropic), or limits plus thinking and sampling defaults (Gemini). The rest comes from each provider's own published sources, then from the bound generation request schema. No unlabeled third-party catalog: a model catalog that mirrors another one caps its accuracy at theirs.
| Source | What it fills |
|---|---|
Provider /models / extras / docs | contextWindow, maxOutput, listing modalities, listing flags |
Bound input schema (schemaEndpointId) | OpenRouter supported_parameters names (tools, temperature, …) and input modalities still null after listing |
| OpenRouter catalog (already in D1) | Compare only — discrepancies on model detail. Never written onto native rows |
Listing/docs win on a field they stated. generated OpenAI-borrowed specs are not walked. Host-native capability objects (FAL, etc.) stay objects.
Each stored value carries fact_sources (migration 0006): per-field and per-flag { derivation, sourceUrl, endpointId, path }. GET /v1/models/{p}/{id} always includes factSources and discrepancies. GET /v1/models?provenance=1 includes factSources on list rows.
Gemini capabilities no longer holds supportedGenerationMethods. The :predict vs :generateContent decision is stored as schema_endpoint_id (migration 0005). The config fallback still reads leftover methods from capabilities so un-repolled Imagen keeps :predict.
Live fill rates (listing/docs only, 2026-09-08)#
Schema-walk flags are not in these numbers; they land on the next poll after this ships.
| Provider | contextWindow | maxOutput | modalities | capabilities |
|---|---|---|---|---|
| openai | 102/131 | 104 | 125 | 89 |
| anthropic | 11/11 | 11 | 11 | 11 |
| grok | 7/12 | 0 | 12 | 0 |
| gemini | 54/54 | 54 | 0 | 47 |
| groq | 14/14 | 14 | 14 | 10 |
| jina | 29/29 | 20 | 29 | 0 |
| fireworks | 23/25 | 0 | 0 | 23 |
| mistral | 50/50 | 0 | 0 | 40 |
| moonshot | 2/2 | 0 | 0 | 2 |
| sambanova | 7/7 | 7 | 0 | 0 |
| hyperbolic | 5/5 | 0 | 0 | 1 |
| novita | 155/156 | 156 | 156 | 134 |
| cohere | 29/33 | 0 | 0 | 15 |
Behaviour notes#
- Production Workers Builds runs
bun run deploy:ci, which applies pending D1 migrations then deploys. PR previews do not migrate (shared prod D1). - First poll after deploy emits one
model.updatedper newly filled row. - Docs-format drift surfaces as a poll error for that provider, not as silent nulls.
Still on #53 (not this PR)#
docs-extracted— leftover prose (Anthropic tools in sentences, OpenAI effort levels, Gemini modalities). Extraction model + verbatim quote, never overwriting a higher rung.- Spec-sync re-walk — schema-derived flags currently refresh on the 15-min model poll. Re-walk bound models when a spec sync updates the input schema.
- Pricing — separate slice. Sources already identified on the issue.
- 1
tombeckenham changed the title
tombeckenham merged thiseb67a99
tombeckenham closed this
Sign in to join this conversation.
Deploying with
Cloudflare Workers#
The latest updates on your project. Learn more about integrating Git with Workers.
View logs