Commit Graph
1 Commits
Author SHA1 Message Date
yetone 51f24a363a workbuddy 0.2.28: list an enterprise's custom: models (#1015)
An enterprise account's own models ("custom:<name>|<name>", modelType
"enterprise") come in /v3/config's models but not in the cli agent's
list. WorkBuddy's CLI (bundled in WorkBuddy 5.5.6, AgentManager.
computeModels) appends every config model whose id starts with
"custom:" to the agent's list itself, after the agent's own ones.
liveModels read only the agent's list, so the models were missing
entirely, and a forced chat to them worked. They are now appended in
the config's order with their context, output, images, price and
efforts, and the id goes to WorkBuddy as given, "|" and all. They stay
on chat (nativeOf matches only a bare claude- id), where the reporter's
chat was served. Both sites share liveModels; nothing else enumerates
the config. The CLI also appends models tagged "custom" or "chat":
those in a desktop's cached config are its local models with their own
url and apiKey, so they stay out.

PR #1016 (yetihan) joined the two spellings instead (an agent-listed
custom:x|x against a bare detail id x); the issue's literal entry,
run against d2e21b7b, lists neither model (expected 2, got 0).

Run (mica, HOME=$(mktemp -d), at a181b898, this change on edc6dbcd;
the rebase onto 934e6b33 adds antigravity commits only):
bun test packages/workbuddy 342 pass, 0 fail across 32 files;
bun scripts/check.mjs exit 0. Earlier the same on mote at dba24067.
The root `bun test` was not run before the push: both machines'
suite.lock were held by other sessions' Go and GUI suites (mica's for
6h), and it is queued on mote behind them; its result goes on #1015.
Broken by hand: the append turned off, 5 of 6 custom.test.mjs red
(the no-cli-agent case passes, as it should); the de-duplication
removed, the "listed once" test red.
Not tried: a real enterprise account; none is available, so the
fixture is the issue's own JSON shape and the "not in the cli agent's
list" placement is inferred from the report and the CLI's code.

Reported-by: CnsMaple
Co-authored-by: zhou.han <18181754+yetihan@users.noreply.github.com>
Refs #1015
2026-11-12 02:20:29 +08:00