feat(models): move manual reasoning efforts into a catalog override

PR #69 added efforts for meta/muse-spark-* directly to the generated
catalog, which the drift check flags and the daily sync job reverts.

Keep src/commandcode-catalog.ts byte-identical to upstream and merge a
separate src/commandcode-catalog-overrides.ts over it at load time. A
test fails as soon as upstream publishes efforts for an overridden model
so the override gets removed instead of shadowing the CLI catalog.

Verified against the live endpoint: pi --thinking xhigh sends
reasoning_effort="xhigh" for meta/muse-spark-1.2-contributor and the
request succeeds; --thinking off sends none.

Closes #69
This commit is contained in:
Patrick Wozniak
2026-09-02 00:03:45 +02:00
parent df4f4a6eef
commit d3c9832d28
7 changed files with 61 additions and 7 deletions
@@ -32,6 +32,8 @@ npm run sync:commandcode-catalog
Regenerates `src/commandcode-catalog.ts` and bumps the documented CLI version in `README.md`. Review the diff; the catalog also lists reasoning models without selectable efforts.
Never add efforts to the generated file by hand. Manual effort policy for reasoning models that upstream ships without levels lives in `src/commandcode-catalog-overrides.ts` and is merged at load time. When the sync report lists a model from that file under "New effort metadata", remove its override; `tests/test-models.ts` fails until you do.
### 3. Update display pricing (manual review)
Fetch <https://commandcode.ai/docs/resources/pricing-limits> and compare against `src/pricing.ts`: