Commit Graph
1 Commits
Author SHA1 Message Date
yetone 1ca2c62c49 catalog: a relay's deepseek-v4.1-flash is priced at DeepSeek's, whose entry names it by a dated canonical id (Winnie7572 on X, #4811, #5622)
models.dev lists DeepSeek's V4.1 Flash only as deepseek-flash with
canonical_model_id deepseek/deepseek-v4.1-flash-1017. The canonical
fallback (#1520) matched the undated id alone, so every relay serving
deepseek-v4.1-flash (Open Design, WorkBuddy, Tencent Cloud) had no price
and no estimated cost. priceIndex now also keys a maker's own canonical
entries with a trailing snapshot date (-MMDD, -YYYYMMDD, -YYYY-MM-DD)
taken off, tried after the exact and dashed keys, so a price a vendor
lists by the id as given still wins. Only the provider that is the
canonical's maker counts, as before, so no other vendor's model is priced.

Open Design's other models were checked with the plugin's real ids
(packages/opendesign models.mjs) against models.dev: every one but
deepseek-v4.1-flash and deepseek-v4.1-flash-eco was already priced.
-eco is the plugin's own id, not a snapshot, and stays unpriced (filed).

Run (mote, at this tree): go test -count=1 for internal/provider,
catalog, usage, gui all ok; go vet darwin, windows, linux nogui ok.
New TestRelayDeepSeekSnapshotCanonicalPriced (models.dev entries in
testdata/models_dev_opendesign.json) is red with the snapshot key
disabled by hand. TestCommandCodePlanPrice's relay case asserted the gap
("a relay took Command Code's list price" for an unpriced model); it now
asserts DeepSeek's price, which Command Code's plan still beats with its
own catalog. Not tried: a live Open Design account.
2026-11-13 01:01:23 +08:00