太陽と向日葵 on magpie's Discord: Usage no longer shows what calls through
Devin cost. Two causes, both in what the list gives magpie:
- Every model went with a price of 0 (runtimeModel's cost), and magpie
falls back to models.dev, which has none of Devin's own models (SWE-2,
SWE-1.7 Lightning). Devin lists each paid model's price in
GetCliModelConfigs: field 32 of a config, one per "Input", "Cached input"
and "Output", a float32 in USD per "1M tokens". parsePrices reads it
(fields() now keeps a fixed32's bytes), and listed() gives an entry the
price its variants share, none when they differ. Read from Devin's own
response on 10-15: Opus 5.5 4/20 (cache 0.2), its fast run 8/40, SWE-1.7
Lightning 2.5/12.5, SWE-2 Lightning 1/5, GLM-5.2 1.4/4.4. The Free tier
lists none.
- Devin now files swe-2-high-, -medium- and -max-lightning under SWE-2 at
the High cost tier. A family was free only when every model under it
was, so swe-2 lost free (seen in the owner's plugin-providers.json on
0.1.17), and with it 0.1.16's rule that a used-up day and week don't hold
SWE-2. A family is now judged by the variants variantFor sends it as:
those at an effort and its default.
Run: HOME=<mktemp -d> bun test in packages/devin: 84 pass. prices.test.mjs
uses Devin's real GetCliModelConfigs bytes of 10-15, cut to 11 configs
(testdata/model-configs-1015.bin, no account data in it). Without the
index.mjs change: 3 of its 4 tests red. Broke by hand: the family's free
over every model again turns 2 red; cost back at 0 turns 1 red.
bun scripts/check.mjs devin: ok. Every price above checked by decoding the
full real response with a separate Python reader.
Not run: magpie end to end with this version (magpie reads a plugin's
price from its next commit on).
On Windows the devin CLI reads %APPDATA%\devin\ whatever folder it is
given (#17), so cliAnswersFor turned it away for every account before
looking at whose sign-in it reads, and an account without the CLI never
asked at all. Both kept the 2026-09-30 SNAPSHOT, which has no Gemini 4
Argon; moving a built-in Devin with it ticked then failed with "the
plugin doesn't serve Gemini 4 Argon" (NieiR).
The list now comes from GetCliModelConfigs, asked with the account's
token (the call the plugin already made for images): its configs carry
each model's label, context (18), output (model_info 13), family uid
(model_info 23) and family label (30.1). Read over Devin's real response
for the owner's account, parseConfigFamilies gives exactly the 52
families and 262 variants `devin models list --format json` prints, in
its order, less Adaptive and Fusion. When Devin can't be asked, the CLI's
list is used if the CLI names the account Devin names the token's, even
when it reads its own folder (the Windows case); else SNAPSHOT, now
refreshed from the CLI (Gemini 4 Argon and Claude Haiku 5.5 added,
Inkling and Claude Sonnet 4.5 kept for the accounts still offered them).
Run:
- TMPDIR/HOME in a scratch dir, bun test packages/devin: 54 pass, 0 fail.
With index.mjs put back to 0.1.14, the 4 new identity tests fail
(parseConfigFamilies missing; familiesFor without gemini-4-argon;
"models list" never run for a same-account CLI reading its own folder;
provider.models without gemini-4-argon).
- bun scripts/check.mjs devin passes.
- Real account (owner's Devin, sandbox HOME, no devin CLI on PATH):
provider.models gave 85 models with gemini-4-argon (1048576/1000000)
and claude-haiku-5-5; 0.1.14 gave the declared list only.
Not tried: the Windows box itself; the new path doesn't run the CLI.
objectRoot dropped any anyOf/oneOf branch that was itself a union. Codex
desktop's automation_update (zod 4: root anyOf of view, delete, and create
and update, each a union on kind) folded to only view's mode and id, both
required, so the model was offered a tool that could only view. Found
while fixing the same fold in magpie's built-in for #1271.
A nested union branch is now folded first (up to 8 deep); a field the
root doesn't define takes every distinct schema the branches give it, as
anyOf when they differ; a field every branch requires stays required.
Verified: schema.test.mjs's new test fails on 0.1.9 (no "name" among
[id mode]) and passes now; HOME=$(mktemp -d) bun test in packages/devin:
39 pass, 0 fail.