Commit Graph
1173 Commits
Author SHA1 Message Date
汤杭运 27ce92fd8f agent-wave 0.1.1: the mode names its model, sets a thinking level, and Wave is found by wsh (#1106)
Wave's magpie mode now carries the picked model's name ("Magpie · <model>"),
display:order 1 and the crow icon, and ai:thinkinglevel from the model's
efforts (medium, then high, then low; left out when it has none). The agent
also detects Wave by the wsh CLI, attributes usage by Wave's User-Agent, and
shows a notice on picking the Magpie mode in Wave. connect still returns one
whole `magpie` object, so a disconnect removes the mode. By aibot88.

Checked against Wave's source (pkg/wconfig/settingsconfig.go): display:order,
display:icon and ai:thinkinglevel (enum low/medium/high) are AIModeConfigType
fields. magpie passes name and efforts to connect (internal/agent/plugged.go),
and bin/ua/notice are agentplug.Desc fields.

Run at the reviewed head 008cd8bb4, HOME=$(mktemp -d):
- packages/wave: bun test 5 pass, 0 fail (mote)
- bun scripts/check.mjs wave: ok
Broken by hand: putting "high" ahead of "medium" turns the thinking-level
test red (4 pass, 1 fail, magpie-desktop WSL); restored.

The author ran it on magpie 0.1.3900 with Wave 0.14.5 on macOS.
Not tried by the reviewer: a real Wave install.
2026-11-14 00:28:26 +08:00
K1NG_HAER1N e488064e06 antigravity 0.1.10: Google Search grounding as a magpie web search (#1103)
Adds a magpie `search` hook (`search.antigravity`, auth: antigravity) that runs
a query through Google Search grounding (`tools: [{googleSearch: {}}]`) on a
Flash model from the signed-in account's live catalog, with thinking off, and
returns the grounded pages (title, URL, snippets), deduplicated and trimmed to
`count`. A refusal carries numeric `status` and `retryAfter` so magpie rests
the account for search only. Grounding redirect URLs are returned as Google
sends them; no extra request is made per result. By Invis1ble-2.

Run at the reviewed head f0465e41b on mote, HOME=$(mktemp -d):
- bun test ./packages/antigravity/: 90 pass, 0 fail (294 expect calls)
- bun scripts/check.mjs antigravity: ok

Broken by hand: turning off the per-URL dedup in pagesFromGrounding turns
search.test.mjs red (5 pass, 1 fail); restored.

The author ran it through a real magpie with a real Antigravity account
(`magpie tool web_search`, 10 pages for "latest Bun runtime release version")
and checked the SEARCH_MODELS names against a real fetchAvailableModels.

Not tried by the reviewer: a real Antigravity account.
2026-11-14 00:06:15 +08:00
zhangyandzy1233 a410afe0d9 zycode 0.1.0: zycode as a magpie agent through a reversible agent.toml (#1104)
Adds `@magpie-community/agent-zycode` 0.1.0: zycode (`zypi`, the VS Code extension, the ACP agent) on magpie's Agents page. magpie writes the model, gateway URL and key to `~/.pi-python/local.env`. A host part (`bridge.mjs`) copies them into the `[model]` table of `agent.toml` as text, and puts the file back byte for byte on disconnect, keeping any edits the user made meanwhile.

Reviewed at 618771e7c9269c8248599f05cd86eb18e00c358f:
- WSL Ubuntu 24.04, Bun 1.4.2: `bun test` in packages/zycode 20 pass; `bun scripts/check.mjs zycode` exit 0.
- Broken by hand: disconnect leaving agent.toml as is (`const back = current`) turns 9 of 20 red.
- No network and no child processes; local files only, temp-and-rename, symlinks refused.
- Real run by the author (Ubuntu VM, zypi 0.9.1, magpie v0.1.4069): only the four [model] lines changed; one turn answered through magpie (Usage shows zycode, 4 calls); after disconnect, agent.toml and local.env have identical sha256.

Not tried: Windows, macOS, the VS Code extension's frozen agent binary.

Co-authored-by: zy1233 <zy1233@users.noreply.github.com>
2026-11-13 23:17:06 +08:00
yetone 8647819cd1 day-card 0.3.4: the Background menu stays on the page where the toolbar wraps
The menu hangs from the Background button's right edge. Where the page is
narrow enough for the toolbar to wrap (about 1000px and less), the button
sits at the left and the 292px menu ran off the page's left edge: at
900px it spanned -105..185, and the first column, the reader's own
picture with its new remove badge among them, couldn't be reached. On
open it now hangs from the button's left edge (#bg-pop.left, origin top
left) when the button's right edge has less room than the menu's width.
Found while checking 0.3.3's badge.

Run on mote at 4191c523 + this change:
- bg-delete.gui.mjs, now at 1200, 900 and 420 wide with a check that the
  menu is within the page: 600 ok, all ok (Chromium and WebKit, five
  languages, mouse and touch).
- HOME=$(mktemp -d) bun test packages/day-card: 19 pass, 0 fail.
- bun scripts/check.mjs: exit 0.
The whole repo's bun test ran green at 4191c523 (8662 pass); this change
touches only day-card's page and its GUI script.
Broken by hand: without the toggle, "menu within the page" FAILs at
900px (-105..185).
Not tried: the live magpie window.
2026-11-13 22:50:33 +08:00
yetone 4191c52328 day-card 0.3.3: your own background picture can be removed, with a badge at its corner (netube99 on X)
A picture added in Background stayed for good. Its swatch now carries a
small × badge at the top-right: shown on hover with a mouse (gated by
hover: hover and pointer: fine), on keyboard focus (focus-within), and
always where there is no hover (touch). The badge is its own button
beside the swatch, not inside it. Removing the picture drops it from the
saved plugin options (pick({ image: "" }), the 1.1s debounced
options.set); a card drawn on it goes back to teal through norm, a
picture not in use leaves the backdrop alone. The menu stays open (the
click is stopped before the outside-click closer sees a detached target)
and focus moves to the + button. No confirm dialog: adding it back is one
pick away. Badge fades and grows from scale(.9) in 150ms on the strong
ease-out; reduced motion keeps the fade only. Name in all five
languages.

Run on mote at 4f5d4138 + this change:
- HOME=$(mktemp -d) bun test (whole repo): 8662 pass, 20 skip, 0 fail.
- bun scripts/check.mjs: exit 0.
- new bg-delete.gui.mjs (Chromium and WebKit, en/zh/zh-TW/ja/de, mouse
  and touch, 1200x800): 180 ok, all ok. Checks the badge's name, hidden
  without hover, shown on hover and on focus, at the corner, always shown
  on touch, menu open after, teal picked, focus on +, saved options
  without the picture, no page errors.
Broken by hand: without the stopPropagation, "menu stays open" FAILs in
every case; with :focus-visible on the wrapper in place of :focus-within,
"badge shown on focus" FAILs. The script needs the badge, so it fails on
the old page.
Not tried: the live magpie window. Seen on the way: at a page width where
the toolbar wraps (900px), the Background menu runs off the page's left
edge, so the picture's swatch can't be reached; fixed in the next commit.
2026-11-13 22:45:13 +08:00
yetone 4f5d4138ad agy-cli 0.1.39: a new nc.exe build drops this runtime's older ones (#1097)
Each nc dir holds a whole Bun runtime (~115MB) and its key changes with
mcp-server.mjs, so every plugin update left one in %TEMP% for the 7-day
sweep (Hy1an measured it). Each dir now holds a `runtime` file naming the
runtime that built it; a build removes the same runtime's other nc dirs at
once. Another runtime's dirs (another install) and dirs from before the
marker keep the week. A running nc.exe is locked, so its dir stays.

Run: test/windows-nc.mjs 8/8 on WSL and on Windows 11 (xiaomi-gpu);
bun test in packages/agy-cli 20/20 (WSL); check.mjs agy-cli ok.
Broken by hand: 0.1.38's index.mjs fails the new test (and the two that
now expect the marker).
Not tried: a real update on Windows. Dirs 0.1.38 left have no marker, so
they still go after a week.

Reported-by: Hy1an
2026-11-13 21:15:11 +08:00
yetone 67a5baaa1f agy-cli test: the sign-in check's upper bound has room on both sides (#1089)
"#1064 登录检查不为探测等太久" bounded authorize() at SLOW_MS + 3s + 1s, so
a busy Windows box used up the 1s and went red 1 in 12. The fake session
now answers after 60s, and the test asks that the probe session was started
and that authorize() returned before half of that. The lower bound stays: a
timer is only ever late.

Run: WSL, node --test test/catalog.mjs 24/24; Windows 11 (xiaomi-gpu,
Node 22), the #1064 tests 12 times, 0 red.
Broken by hand: OFFERED_SIGNIN_WAIT_MS at 120s (authorize waits for the
session) makes the test red, "登录检查等了会话(31524ms)".
No package code changed, so no version bump.
2026-11-13 20:43:46 +08:00
ming_jiang c2f54a8e74 amp-usage 0.1.2: an open page survives the plugin host restarting (#1099)
amp-usage keeps its service token across a host restart; a held lock is waited for, and the page polls with a timeout and clears its notice on recovery. Fixes #1098.

Reviewed at 8a6a66162; 585c921ae only drops a docs file.
Run (WSL, Bun 1.4.2, temp HOME): amp-usage tests 53/53, bun scripts/check.mjs exit 0.
Broken by hand: main's lib/server.mjs fails tests 1 and 2; main's index.mjs fails test 3.
Not tried: a real Amp account through a restarted magpie.
2026-11-13 20:28:35 +08:00
yetone c441017527 scripts/check: each package gets a folder of its own as its directory (#1100)
check.mjs handed every plugin process.cwd() as its directory, so a
plugin that writes state there (atomcode's atomcode-state.json) left an
untracked file in the checkout. magpie gives a plugin a data folder of
its own; the check now does the same, one temp folder per package,
removed at the end.

Run (mote, temp HOME, Bun 1.4.2): bun scripts/check.mjs exits 0, 59
packages ok, and no file in the tree is newer than the run's start.
Broken by hand: with main's check.mjs the same run leaves
./atomcode-state.json.

Reported-by: jinyue806
2026-11-13 19:59:41 +08:00
yetone 035a11cf88 agy-cli 0.1.38: a runtime under a non-ASCII folder still builds nc.exe (#1097)
On Windows, Bun's `build --compile` widens its own path byte by byte
into UTF-16 before CopyFileW, so a magpie-bun.exe under a non-ASCII
folder (a Chinese user name) fails with "failed to copy bun executable
into temporary file: ENOENT". windowsNcDir then fell back to nc.cmd,
which agy 1.5.x never runs, and no client tool reached the model.

When process.execPath isn't ASCII, the build now runs a copy of the
runtime in an ASCII-only folder (the temp dir, else %PUBLIC%, else
%ProgramData%) and removes it after. nc.exe's cache key is still the
real runtime's path.

Run (mote, temp HOME, Bun 1.4.2): node --test test/windows-nc.mjs
7 pass; bun test in packages/agy-cli 20 pass; scripts/check.mjs
agy-cli ok. Broken by hand: with main's index.mjs the new test fails.

Windows 11 (xiaomi-gpu, Bun 1.4.2, real binaries): bun under a folder
named with Chinese characters fails `build --compile` with the
reporter's ENOENT. A non-ASCII cwd, server path or output path is fine,
and the compiled exe runs from a non-ASCII folder; an 8.3 short path
doesn't help. The plugin's own ensureShimDir, run by that bun: main
gives nc.cmd, this change gives nc.exe in 614ms, which starts, and
leaves no build dir or runtime copy behind.

Not tried: agy itself against the new nc.exe on Windows, and Bun 1.4.4
(the reporter's); the code path read is the same in Bun's main source.

Reported-by: Hy1an
2026-11-13 19:58:09 +08:00
Pursuit806 a2af9d2dd3 astudio 0.2.2: fill in DeepSeek-V4.1-Flash while the catalog lags (#1095)
Reviewed at b43d74357. WSL (Bun 1.4.2, temp HOME): bun test in packages/astudio 81 pass, scripts/check.mjs astudio ok. Without the catalogSlugs check the two new tests fail. A slug the catalog lists, hidden or not, is never filled in. Not tried: no AStudio account here, so the model's 200 is the author's.
2026-11-13 19:49:49 +08:00
tungloong 592b716ac3 agy-cli 0.1.37: DeepSeek Harness's notes are not the loop's task; a trimmed loop keeps its whole user turn (#1093)
Reviewed at 56248465f. WSL (Bun 1.4.2, temp HOME): bun test in packages/agy-cli 20 pass (repeat-batch.mjs inside agy-cli.test.mjs), scripts/check.mjs agy-cli ok. With main's index.mjs, node --test test/repeat-batch.mjs fails 6 (19, 20, 21, 22, 24, 26). Open question, not blocking: a string-content message holding a runtime snapshot and the user's words reads as meta-only (affects only prompts trimmed past 112 KiB).
2026-11-13 19:49:31 +08:00
Akiiwa 157c7deefd agentcompass 0.2.1: a needs_visual task requires image input at every tool_operation level (#1092)
Reviewed at cedd845b3. WSL (Bun 1.4.2, temp HOME): bun test in packages/agentcompass 141 pass, scripts/check.mjs agentcompass ok. Without Boolean(task.needs_visual) the new test fails; restored, 141/141. Generated files change only their Source line.
2026-11-13 19:49:26 +08:00
yetone f053e32790 autoclaw 0.2.23: ZCode's subagent opening line is rewritten too (#1094)
ZCode's built-in subagents (general-purpose) open "You are an agent for
ZCode CLI. …", which the "You are ZCode" rule doesn't match. AutoClaw
answered 406 for them while the main session, in the same minute on the
same account, was 200. As with Claude Code's subagent line, an article
goes in front of the name: "You are an agent for the ZCode CLI." The
reporter ran exactly this rule on 0.2.22: 406 before, 200 x2 after.

Run (WSL, magpie-desktop, HOME=$(mktemp -d)): bun test in
packages/autoclaw, 117 pass / 0 fail; bun scripts/check.mjs autoclaw ok.
Broken by hand: without the new rule, "a system prompt carrying every
known line at once comes out clean in one pass" goes red.
Not tried: a real AutoClaw account.

Reported-by: aynauynij
2026-11-13 19:09:06 +08:00
yetone 59d1d107d0 codearts 0.3.17: sign in with a Huawei Cloud International account in the browser (#1090)
The browser sign-in always opened the mainland portal
(codearts.huaweicloud.com/portal/authorize, locale zh-cn), so an
international-station account could not sign in in the browser.

A new method, "Sign in with Huawei Cloud (International)", opens
auth.huaweicloud.com/authui/login?site=intl&locale=en-us with the
international portal's authorize URL
(codearts.ap-southeast-1.huaweicloud.com/portal/authorize, same
parameters, locale en-us) as `service`. The reporter found that the
portal alone sends a signed-out browser to the mainland login. After the
callback, the portal's result page is the international one too. The
code is exchanged at the same STS endpoint, as the reporter found. The
credential is stamped `station: "international"` (the key the IDE import
already uses), so chats, usage and signing stay on that station.
refreshCredential now carries `station` over, or a renewal would turn
the account back into a mainland one. The international sign-in skips
the mainland IAM phone read and OfficeAce's MaaS read.

The method is listed last, so the mainland browser method and the IDE
method keep their places. A mainland credential still carries no station.

Run (WSL, magpie-desktop, HOME=$(mktemp -d)): bun test in
packages/codearts, 208 pass / 0 fail; bun scripts/check.mjs codearts ok.
Broken by hand: with `station` taken out of refreshCredential's copy list
and out of the callback, the refresh test and the international sign-in
test go red (206 pass / 2 fail).
Not tried: a real international account. The URLs are the reporter's,
from their own sign-in.

Reported-by: AyakaChen1
2026-11-13 18:33:31 +08:00
yetone fbeda91fb3 loomy 0.1.6: routing reads the daily and permanent credits added up (gocccy0 on X)
gocccy0 on X: Loomy's usage sent the permanent credits (永久积分) as aside
text, and the daily credits (每日赠送积分) either as aside text too (no
dailyLimitPoints pair: routing had no window, "quota unknown") or as the
one window routing reads (with the pair: at 100% it stopped an account
that still had permanent credits).

Now usage leads with 积分合计, the window routing reads (totalOf): spent
is what the daily wallet has spent, limit is spent + daily left +
permanent balance, used its share; with nothing left at all it is 100%.
It renews at Beijing midnight with the daily wallet, and the daily
credits left are lost then (runsOutAt, runsOut), so magpie's Smart and
Least used first spend them first. With the permanent balance alone it
has no reset. The two wallets are still shown, both set aside, as
WorkBuddy shows its plan and extra credits beside their total. No
magpie change: plugin windows already carry amount/limit/runsOutAt, and
40c8d0c81 already shows an all-aside account's read.

Run (mote, HOME=$(mktemp -d)): bun test in packages/loomy, 32 pass,
including the new test (daily spent + 1,200 permanent is 80.6% not 100%;
both 0 is 100%; 3,000 daily left run out at midnight; no limit pair; the
permanent balance alone). Root HOME=$(mktemp -d) bun test: 8648 pass, 20 skip, 0 fail;
scripts/check.mjs ok.
Broken by hand: no total window (the old shape) turns the new test red
(2 counted windows, expected 1).

Not tried: a real Loomy account (the reporter's reply shape is assumed
to be one of the ones tested); magpie's GUI with the plugin installed.
2026-11-13 17:40:41 +08:00
yetone 2e77e646c8 agy-cli 0.1.36: the last model list agy gave is served after a restart (#1086)
After a restart, models() handed out the static Gemini-only fallback until
agy answered again. offeredFilter also hid every non-Gemini model until a
session or probe told it what agy offers. So the first requests after a
restart saw no Claude models.

The bridge now keeps the last list agy gave, and the set it offered, in
models.json beside the session state file. The file has one entry per agy
path, is written under the state lock through temp-and-rename (mode 0600),
and is trusted for 14 days. A half-written or invalid file, another agy
path, or a stale entry all give the static fallback, as before. A saved
list is not treated as an answer from this agy: the offered probe still
waits for a real listing.

Run (WSL magpie-desktop, Bun 1.4.2, Node 22):
- bun test in packages/agy-cli: 20 pass.
- node --test test/catalog.mjs: 24 pass.
- bun scripts/check.mjs agy-cli: ok.
Windows (xiaomi-gpu): node --test test/catalog.mjs 12 times, 11 green.
The one red is the existing wall-clock test "#1064 登录检查不为探测等太久",
filed as #1089. I haven't shown whether it is red on origin/main too.

Broken by hand: readSavedCatalog returning null turns the new #1086 test
red; skipping the offered restore turns it red too.

Not tried: real agy on any OS; a restart with a real signed-in agy.

Reported-by: yinbing-666
2026-11-13 17:29:06 +08:00
Akiiwaandakiiwa-games c4e9c1099e agentcompass 0.2.0: route on AgentCompass v0.6.0 (#1083)
agentcompass routes on the AgentCompass v0.6.0 engine: four capability
categories, quota-economy seat ordering and data gates. With no caller
profile, a request keeps the model the client asked for. External
scoring stays off unless allowExternalScorer and a scorer base URL are
both set. The reference ships in the package. This supersedes #791.

Run at 52a98632, merged onto main, on WSL (Ubuntu 24.04) with
HOME=$(mktemp -d):
- npm test in packages/agentcompass: 140 pass, 0 fail
- bun scripts/check.mjs agentcompass: ok
- Read the diff for new I/O: src/ has no fetch outside the opt-in
  scorer, and no spawn, env read or disk access.
- The docs' scorer example was checked against scorerOptionsOf and
  resolveClassifier.

Not tried: a real Magpie gateway routing live traffic through it.

Co-authored-by: akiiwa-games <akiiwa-games@users.noreply.github.com>
2026-11-13 17:14:25 +08:00
yetone 319b0a6459 layerfs 0.10.2: the page shows its empty state before the first project, not Connecting for good
AlanWang1027713 on X (magpie v0.1.4026, macOS): Plugins -> LayerFS
轨迹 stays on "Connecting to the local trajectory service…".

The page's boot.js jumps its frame to the host's service on 43717, and
the service started only once a store with a project existed. With no
store the jump is refused. The README said the frame then shows the
browser's refused-to-connect page; that is Chromium. A WebKit frame
(magpie's window on macOS and Linux) keeps the old document when its
jump is refused, so it said Connecting for good.

The service now starts when the host loads, store or no store. With no
store (or an empty projects folder) it answers an empty recording
without building the backend, so nothing is written under ~ until a
tool call makes the first project. The empty state now reloads itself
every 5s like the full page, so the first provision shows up without
reopening the page. The retry on a held port no longer waits for a
store, and the store-race recheck it needed is gone.

Run on mote (Bun 1.4.2, temp HOME):
- bun test packages/layerfs: 69 pass, 0 fail. bun scripts/check.mjs: 0.
- Broken by hand: 0.10.1's index.mjs and app.js turn the two new
  tests red (the no-store service test and the empty-state reload).
- Real browsers (Playwright 1.62.0): a sandboxed frame doing boot.js's
  jump against a no-store host. 0.10.1: WebKit's frame stays on
  "Connecting to the local trajectory service…", Chromium's shows
  chrome-error. 0.10.2: both show the zh empty state
  ("还没有记录到轨迹…").

Not tried: the page inside the real magpie window with the plugin
installed.
2026-11-13 17:07:35 +08:00
SivanColaandSivanCola bd5e598d25 deepzora 0.2.0: every model Magpie offers the agent is imported (#1081)
Deepzora's model list now imports every model Magpie offers the agent
(through agentplug's connect catalog), with per-model display name,
effort and context settings, and keeps the user's default when an
upstream is removed.

Run at df024f9d on WSL (Ubuntu 24.04), HOME=$(mktemp -d):
- node --test deepzora.test.mjs: 13 pass
- bun scripts/check.mjs deepzora: ok
- acceptance.mjs and resident-acceptance.mjs against a magpie CLI
  built from main 51b98b1a8 (-tags nogui): every PASS line
- Broken by hand: the tests went red.
- The per-model toml keys were checked against Deepzora's
  ProviderModelOverride source.

Not tried: a real Deepzora desktop install.

Co-authored-by: SivanCola <SivanCola@users.noreply.github.com>
2026-11-13 16:47:50 +08:00
yetone 84d7072a4e Revert "comate 0.1.0: 文心快码 (Baidu Comate) provider plugin"
This reverts commit 9523f472.

A Comate plugin already exists and is listed in magpie's unofficial
plugins: github:PengJunchen/magpie-comate-auth (0.5.12, provider id
`comate`), with native Comate tool calls, task reuse across turns,
images, license paste and the local Comate sign-in, run by its author
on macOS. 0.1.0 here was never run against a real account, carries
tools as JSON text and takes no images, under the same provider id.
Listing it beside the other one gives users the weaker of the two, so
it comes out. It never reached npm (a new package can't be created by
trusted publishing); only the dist branch had it.

Run: git revert only; registry.json still parses
(python3 -c json.load).
2026-11-13 16:25:05 +08:00
yetone 7bccaae910 agy-cli 0.1.35: a client tool's ide-tools permission request is allowed once (#1082)
Newer agy asks before an MCP call, and the bridge refused every
session/request_permission, so each client tool failed with "user
denied permission for mcp(ide-tools/exec_command)". A request whose
title (or name) is exactly mcp(ide-tools/<tool>), mcp "ide-tools/<tool>",
ide-tools/<tool> or mcp_ide-tools_<tool>, with <tool> among the tools
the client declared, now gets allow_once. Those tools run in the client
under its own permissions. agy's own tools (shell, edits, browser) are
still denied, as is a title that only contains such a name somewhere
(a shell command's text can be in its title), an undeclared tool and
another server's tool. rawInput is never read.

Run (WSL magpie-desktop, HOME=$(mktemp -d)): bun test in
packages/agy-cli, 20 pass; bun scripts/check.mjs agy-cli ok. Broken by
hand: with the allow branch off, smoke.mjs has 2 failures, the two
#1082 allow checks.

Not tried: a real agy that asks for MCP permission. The title agy
sends for an MCP call isn't known from its strings, so the forms above
come from its rule and error text; the reporter is asked to confirm.

Reported-by: Saramanda9988
2026-11-13 16:08:40 +08:00
yetone 9523f472b2 comate 0.1.0: 文心快码 (Baidu Comate) provider plugin
A request from X (@vfrpn). Read from the Comate VS Code extension
BaiduComate.comate 4.14.1 (its bundled Comate CLI, @comate/zulu 1.7.16):
unpacked into its own folder and read, never run.

- Sign-in: the CLI's own flow. A fresh clientId opens
  comate.baidu.com/zh/login?track=COMATE_CLI, /api/client/generate/token
  is polled every 2s for 3 minutes, and /api/client/key turns the token
  into the account's license, the credential. A license copied from
  comate.baidu.com/user can be pasted instead (checked at
  /api/key/valid/<license>).
- Models: the account's list from POST /api/v2/api/models/available, as
  the CLI reads it; "auto" alone when it can't be read.
- Chat: one Comate agent turn per request (conversation, task, execute
  SSE) as a custom agent in the client's own shape (isProjectAgent,
  agentPrompt, no server tools). ANSWER deltas and reasoning go out as
  content and reasoning_content, TOKEN_USAGE as usage. code 401 is a 401,
  code 429 / QUOTA_EXCEED / DOWNGRADE a 429. Tools ride as JSON text, as
  in catpaw; images are refused with 400.
- Usage: Comate has no quota a license can read outside Baidu's network,
  so the card says only whether the license holds.

Run (mica, mote was at load 41; sandbox HOME): bun test packages/comate,
22 pass; bun scripts/check.mjs, exit 0 (registry.json and comate ok).

Broken by hand: dropping the login-name header, the code 401 mapping
and the trim of the answer's leading newlines turned 5 tests red; put
back, 22 pass.

Not tried: anything against a real Comate account (none here). Unknown
until one runs: whether the server takes agentPrompt for a top-level
custom agent with no tools of its own, whether conversation and task
need more fields, whether thinkingEnabled / effort / contextWindow are
accepted, the real model ids and the limit frames' shape. The README
says so.
2026-11-13 16:07:44 +08:00
yetone 5f125842b0 antigravity 0.1.9: Gemini 4's thinking is held back for 10 s at most (#1078)
holdThoughts held a Gemini 4 stream until its first non-thinking part,
so a late 400 INVALID_ARGUMENT could be asked again without sending
thinking twice. On a long-thinking turn (gemini-4-hydrogen at high:
60-140 s) the client got nothing until the answer began, and harnesses
with a 60-120 s idle timeout gave up. Now the hold ends after
retry400.holdMs (10 s): what was held goes out and the rest streams
live. A read still out when the time runs out is taken by the body
first, so no chunk is lost. A 400 within the first 10 s is still asked
again; one after that reaches the client as it is. No switch: the cap
covers the timeout without a setting.

Run (WSL, Bun 1.4.2, temp HOME): packages/antigravity bun test 84
pass; bun scripts/check.mjs antigravity ok. Broken by hand: with the
timer replaced by a promise that never settles, the new test fails at
its 3 s timeout. Not tried: a real Gemini 4 account.

Reported-by: hardfist
2026-11-13 15:54:38 +08:00
zhbchnandzhbcn d6dcb6eaa1 workbuddy 0.2.34: REA's surrogate path guard is left out of the tools sent to WorkBuddy AI (#1080)
WorkBuddy AI's deepseek-v4.1-flash-sg refuses a request whose tools
carry REA's exact `^[^\uD800-\uDFFF]*$` path guard with "400: invalid
function call parameters", before any tool is called. fitSchema now
drops that exact pattern from the outbound schema; other patterns, the
surrounding allOf and REA's own validation stay.

Reviewed at 2f4738e9: workbuddy package on Linux (Bun 1.4.2, temp
HOME) 378 pass; bun scripts/check.mjs workbuddy ok; with the new `if`
turned off by hand the new guard test goes red.

Co-authored-by: zhbcn <zhbcn@users.noreply.github.com>
2026-11-13 15:51:22 +08:00
wuuliandwuuli 463bbfe2b6 cursor 0.2.46: a quiet Run's error says the stream timed out, so Pi retries it (#1075)
Cursor's quiet watchdog (idle and heartbeat-only) now ends its error with "; stream timed out (try again)", so Pi, which classifies a streamed error by its words once the 502 is lost behind a 200, retries the turn within its own budget. The status, limits and failure stay as they were. 0.2.46.

Reviewed at 507b2fd0. Checked Pi's own retry list (earendil-works/pi packages/ai/src/utils/retry.ts on main has "timed? out"; "(try again)" alone matches nothing there). magpie's gateway decides on the 502 status (busyStatus), so its own handling is unchanged. Run (WSL, Bun 1.4.2): packages/cursor bun test 421 pass, 0 fail; bun scripts/check.mjs cursor ok. Not run: scripts/cursor-pi-retry.integration.mjs (needs an installed Pi SDK, loopback only); a real Cursor stall (#550).

Co-authored-by: wuuli <wuuli@users.noreply.github.com>
2026-11-13 15:09:02 +08:00
zhou.han 6059fb1990 nowledge-mem: the layout test gives a slow Chrome launch 90 s under CI (#1076)
A layout test whose Chrome launch is slow under CI's full suite gets a 90 s launch bound when CI is set (25 s locally), and the test's own timeout follows the bound plus 10 s for cleanup. Fixes #1071.

Reviewed at df016967. Run (WSL, Bun 1.4.2, CI=1): bun test packages/nowledge-mem 161 pass, 2 skip (no Chrome on that box, so the layout test itself skipped); the author ran a fake Chrome that answers at 26 s, red at 25 s on d24fd5d and green with CI=1. Not tried: a real Chrome on ubuntu CI, which this PR's merge run is.

Co-authored-by: yetihan <yetihan@users.noreply.github.com>
2026-11-13 15:08:56 +08:00
yetone 8528698e3a workbuddy 0.2.33: the free window reads routing traces a line at a time, numbered day files too (#1077)
freeWindowRows read each routing day whole: readFileSync, gunzipSync into
one string, then split("\n"). A busy day's .gz unzipped to 520 MB, and the
read took Bun past 1.1 GB on easonlao's 2 GB host, where the kernel killed
the plugin host every minute or two and every request in flight with it.

- routingLines streams the file (createReadStream, piped through
  createGunzip for a .gz), holding a chunk and one line, never the file.
  A line over 4 MiB is passed over (the longest in the 520 MB day was
  88 KiB). A .gz that fails part way keeps the lines before the fault, as
  magpie's own gzRoutes does; a .gz of several members is read through.
- Today's plain file is read on from the offset past its last newline
  when it has grown (same inode, bigger), so a usage read no longer
  re-reads the day after every request; a half-written last line waits
  for the next read. One that shrank or kept its size is read whole.
- freeWindowRouting lists a day's numbered files (YYYY-MM-DD.N.jsonl and
  .gz, magpie 5d93f6b3), which were missed, so a day past 256 MB read
  short.
- Two usage reads at once share one read of a trace.
- readRoutingRefusals, routingRefusalRows and freeWindowRows are async;
  the one caller, the usage handler, already awaits.

Run (WSL magpie-desktop, Bun 1.4.2, HOME=$(mktemp -d); mote's load was
over 18):
- bun test freewindow.test.mjs: 59 pass.
- packages/workbuddy bun test: 376 pass, 0 fail.
- bun scripts/check.mjs workbuddy: ok.

Broken by hand: the new memory test against origin/main's index.mjs, in
its own child process on a .gz of 256 MB unzipped: RSS grew 848 MB, red
(bar 160 MB); green on this change.

Not tried: the reporter's real 47.6 MB trace or a 2 GB host; Windows and
macOS (the read is node:fs/zlib streams only). Each CN estimated window
still reads a trace on its own, once per trace change.

Reported-by: easonlao
2026-11-13 15:05:03 +08:00
yetone aea9438f90 devin 0.1.40: a typed API key (cog_…) is a sign-in method
wuxudongxd on X: the plugin offered only the browser and CLI sign-ins,
while a hand-written {type:"api", key:"cog_…"} entry (a service user's
key) worked for chat and usage. Add "Devin API key (cog_…)" as a v1 api
method (no authorize, so the host saves the key as typed) and as an
OpenCode 2 key method; v2Auth already reads a key credential. The key is
sent as a sign-in's token is (Basic on GetChatMessage, apiKey on
GetUserStatus), and the first usage read names the account (syncOrg).

Run: bun test in packages/devin (214 pass) and the whole repo's bun test
with a temp HOME on mote (8542 pass, 20 skip, 0 fail).
Broken by hand: with both methods removed, apikey.test.mjs's method and
OpenCode 2 tests go red (the chat and usage tests pass either way: those
paths already took any api key).
Not tried: a real cog_ key (none on hand).
2026-11-13 15:02:14 +08:00
yetone d24fd5d182 factory 0.1.47: add Gemini 4 Hydrogen (#1073)
Droid 1.10.0 adds gemini-4-hydrogen on Factory's Google route, behind its
Gemini4Hydrogen flag: 1M context, 65536 output, low/medium/high, a 0.6x
multiplier and no promotion. Without it a request to
factory/gemini-4-hydrogen went to the Anthropic route and was refused.
It sits after the first 24 like Carbon, so GLM-5.3-Flash stays in them
(#119); grouped by company it sorts first among Gemini, by id as the
others do.

Checked: Droid 1.10.0 darwin/arm64 downloaded on mote, SHA-256
2b6b467e…6bf7f as the issue says. The testdata line is grepped from
that binary, and matches the issue's text byte for byte.
Run: bun test packages/factory on WSL with a temp HOME, 0 fail;
bun scripts/check.mjs factory ok. Hydrogen is index 49 of 60.
Broken by hand: Hydrogen at 0.5x turns 3 rate tests red.
Not tried: a real request (no Factory account with the flag here).

Reported-by: hitbear518
2026-11-13 14:22:10 +08:00
zhou.han 58221e6faa agy-cli: the smoke fake stops a turn whose ToolSearch failed (#1069)
The fake agy in smoke.mjs now returns when its old prompt's ToolSearch
call comes back isError, instead of going on to its loaded-tool validator.
Under a slow shutdown (Windows) that path logged unknownTool and failed
"no call to the loaded tool reaches agy's validator in the old prompt".
Fixture only; the bridge is unchanged.

Run at 6946b93c: smoke.mjs ALL OK (337) 3 of 3 on Windows 11. With an
800ms pause injected before the bridge's process stop (WSL), the parent
fails that check and this head passes it. CI test job green.

Fixes #973.
2026-11-13 14:20:17 +08:00
yetone b40a853c20 agy-cli 0.1.34: agy isn't run in the background without a sign-in, so it stops opening the browser (JZGiVvkSOA75376 on X)
On Windows 11, a signed-out agy opened Google's sign-in page 235 times
in one day. The usage refresh ran `agy` about every 3 minutes, and agy
opens the browser through ShellExecuteW, so the BROWSER=open.cmd guard
can't stop it.

New signin.mjs reads agy's stored sign-in without running agy. agy keeps
it through go-keyring, service "gemini" and user "antigravity":
- macOS: `security find-generic-password`;
- Windows: CredReadW from PowerShell, on the credential
  "gemini:antigravity".
It reads only whether a sign-in is stored, whether it has a refresh
token, and when the access token ends. The token itself never leaves
the function; a hash tells one sign-in from the next. Setting
GEMINI_API_KEY, GOOGLE_API_KEY, AGY_ADC_AUTH or GOOGLE_GENAI_USE_VERTEXAI
means agy signs in some other way, so nothing is concluded from the
keyring. AGY_BRIDGE_STORED_SIGNIN=skip turns the read off.

An access token that has ended is not "needs sign-in". The owner's
working agy has one that ended 11 hours ago and is renewed from its
refresh token. agy counts as unable to sign in when:
- no sign-in is stored;
- the access token has ended and there is no refresh token;
- or agy already failed on this stored sign-in: it said it needs a
  sign-in, or it hung with an ended token and printed nothing or
  sign-in talk, the way an agy waiting on its browser does. This holds
  until another sign-in is stored.

What changes:
- Usage: in those cases agy isn't run. The read says signIn "expired",
  and magpie shows the account's sign-in as expired. After the next good
  read it says "renewed", and magpie clears that.
- Other usage failures wait 10 minutes before the next run, doubling up
  to 6 hours. Before, they ran again on every refresh.
- The model listing (`agy models`) isn't run in the background in those
  cases either. The catalog it has stays.
- Signing in from magpie skips the `agy models` probe and goes straight
  to magpie's own sign-in link. A finished sign-in clears what was
  marked dead.
- A request answers 401 with X-Magpie-Sign-In: expired when no sign-in
  is stored. This uses the last read, so a request never waits for
  PowerShell.
- `agy --version` hanging is never read as a sign-in wait.

Run:
- mote, rebased on a02d5912: `bun scripts/check.mjs` ok and
  `bun test` in packages/agy-cli (20 pass, 0 fail).
- mote, root `HOME=<temp> bun test` at the pre-rebase head (e90d6f01
  base): 7588 pass, 427 fail, none in agy-cli. The reds named in the
  kept tail are OAuth callback-port and loopback page-service tests
  (mote at load ~35-40); main's own CI test job passes them, so this
  push's CI test job is the record for the whole suite.
- win-run on xiaomi-gpu: test/signin.mjs and test/usage.mjs (21 pass,
  3 skip on Windows), plus the PowerShell script for real. Over SSH,
  CredReadW answers 1312 (no logon session), which the script turns into
  "unknown". So the struct read was tried on a CREDENTIALW built in
  memory with a UTF-8 blob: the bytes round-trip and the sign-in parses.
Broken by hand:
- with the usage gate, the backoff hold and the dead mark removed, 5
  usage tests go red;
- with listAgyModels' gate and the request gate removed, the new catalog
  test goes red;
- with the request gate alone removed, it goes red too.
Not tried:
- a real signed-out agy, by the rule against running a real agy sign-in
  or a browser;
- CredReadW in an interactive Windows session (none was logged on);
- agy on Windows at all (xiaomi-gpu has no agy).
On Linux the keyring isn't read ("unknown"): agy runs as before, with
the backoff, and the xdg-open shim already stops the browser there.
2026-11-13 13:45:25 +08:00
yetone a02d5912d9 codearts: stop goes as a list on the international station (#998)
0.3.15 turned every stop into one string, because the mainland gateway
refuses a list (magpie#6342). AyakaChen1 found the international station
(snap-access.ap-southeast-1) is the other way round: a string is refused
and a list works, so the normalisation broke international requests that
used to pass. normalizeStop now takes the account's station: mainland
still gets the first non-empty string, international gets every non-empty
string as a list. Empty or non-string entries are dropped on both.

Run: bun test packages/codearts on WSL with a temp HOME, 204 pass.
bun scripts/check.mjs codearts ok.
Broken by hand: with 0.3.15's index.mjs and the new tests, the stop test
and the international station test fail (2 fail).
Not tried: a real international account; the list shape comes from the
reporter's measurement.

Reported-by: AyakaChen1
2026-11-13 13:40:32 +08:00
yetone 00892c80e3 agy-cli 0.1.33: DSH's @-path paragraph goes reworded, as antigravity sends it (#1028) (LeeTengLong on X)
agy-cli's cloak.mjs copied only antigravity's TURNED_AWAY break-up (#980),
not the REWORDED rewrite antigravity 0.1.7 added for #1028, so DeepSeek
Harness's "Tokens prefixed with @ are paths…" paragraph reached agy word
for word, the text that got gemini-4-argon answering fast, without thinking
and shallow.

cloak.mjs now carries REWORDED, reword and outgoing (reword after cloak),
a copy of antigravity/index.mjs's, and every place agy-cli hands system text
to agy uses outgoing: the session's systemPrompt.append,
<external_system_instructions>, a later system/developer message and the
notices beside a tool result. Only that exact paragraph changes; a prompt
that merely mentions @ paths, and what the user wrote, go as written.
instructionsIdentity still keys on the prompt as the client wrote it. The
packages ship on their own, so the code is a copy; cloak.test.mjs holds it to
antigravity's shape() output for each REWORDED entry and the samples.

Run on mote (Bun 1.4.2, temp HOME): bun test packages/agy-cli
packages/antigravity 118 pass 0 fail; bun scripts/check.mjs exit 0.
Broken by hand: outgoing without reword turns 3 tests red (cloak.test.mjs
2, and smoke.mjs's #1028 session, external_system_instructions and later
system message checks).
Not tried: a real agy with a real Antigravity account and DSH; the
rewording's effect rests on #1028's replays. No magpie min names agy-cli.

Reported-by: LeeTengLong
2026-11-13 13:14:51 +08:00
yetone 9213d9b474 workbuddy 0.2.32: accounts import from a file, and a cloud-hosted enterprise goes to its own address (marchen_cc, emilochen on X)
marchen_cc on X: 「从文件导入账号」 took no WorkBuddy file. magpie had no
import hook for plugins at all; this version gives WorkBuddy one
(auth.import, auth.importFrom/importFroms), which magpie (with plugin
imports) calls from the provider's editor and `magpie accounts import`.
It reads WorkBuddy desktop's .info sign-in ({auth, account}), an
auth.json-style entry, or any JSON holding accessToken/refreshToken (or
access_token/refresh_token), nested in maps or lists. Each is checked by
renewing its refresh token (which takes the sign-in over from the app it
came from, as signing in does) and named as a sign-in is: the file's
account, else /v2/plugin/accounts, then its enterprise. A $wbEncrypted
token (WorkBuddy 5.6+) is refused with a pointer to the browser sign-in;
a file from the other build says to import it under that one.

emilochen on X: an enterprise on WorkBuddy's cloud (a
*.sso.copilot.tencent.com, *.copilot.qq.com or *.sso.codebuddy.cn domain)
is served at https://<domain>, as WorkBuddy's CLI and product.json route
it; the plugin sent it to the site endpoint. Renew, the enterprise
lookup, the meter, the model list and chats now go to the enterprise's
address. iOA domains, accounts with no domain, and API keys stay where
they were. Self-hosted enterprises are not routed.

Run: bun test packages/workbuddy (import.test.mjs 6 of 6), bun
scripts/check.mjs (every package ok), root `HOME=$(mktemp -d) bun test`
on mica: 8534 pass, 1 fail, agy-cli's "test/smoke.mjs against a fake agy" at 40s under the full run, which passes alone (22s) and is filed apart; nothing in agy-cli is touched.
Broken by hand: endpointOf returning the site always turns the 2
endpoint tests red; on the old code the import hook doesn't exist and
the first import test fails.
Not tried: a real enterprise account on a cloud-hosted domain, and a
real desktop .info file from the user (fixtures follow WorkBuddy's
client source).
2026-11-13 13:10:35 +08:00
yetone e90d6f011a kiro 0.1.38: the tests keep kiro-cli's Windows sign-in under their own HOME (#966)
On Windows the plugin reads kiro-cli's database from %APPDATA%\kiro-cli,
while accounts.test.mjs and builderid.test.mjs wrote and removed it under
~/.local/share. With #1067's EBUSY fix in, these were the last 2 of
#966's 8 Windows reds: "kiro-cli's sign-in, with no way known, keeps the
bare email" and "kiro-cli's Builder ID sign-in ... Builder ID's profile".
The tests now set APPDATA inside the temp HOME before loading the plugin,
so no real %APPDATA% is read or removed, and use that folder on win32.
The version bump releases #1067's statement finalizing.

Run: packages/kiro on Windows 11 (Bun 1.4.2, temp HOME/USERPROFILE)
183 pass 0 fail (2 fail at a9f16031 without this); WSL Ubuntu 24.04
183 pass 0 fail; bun scripts/check.mjs kiro ok.
Not tried: macOS (the change is win32-only).

Fixes #966
2026-11-13 11:40:46 +08:00
zhou.han a9f16031fa kiro: finalize kiro-cli's SQLite statements so Windows can remove the file (#1067)
kiro-cli's SQLite statements are finalized in readCLI and saveBack, and in the tests' fixtures, so Windows can remove the database between tests (EBUSY, #966).

Run at 85bb47ff: packages/kiro on Windows 11 (Bun 1.4.2, temp HOME) went from 8 reds on main to 2; Linux (WSL Ubuntu 24.04) 183 pass, 0 fail; `bun scripts/check.mjs kiro` ok. The 2 left are the tests writing kiro-cli's database under ~/.local/share while the plugin reads %APPDATA% on Windows; fixed in the next commit.

Fixes #966 (with the next commit).
2026-11-13 11:40:05 +08:00
yetone 0135b7b0ea agy-cli 0.1.32: the first model list after warming has agy's Claude and GPT models (#1064)
On a signed-in agy, `agy models` takes about 4.4s and `agy acp`'s
session/new about 3s. provider.models() needed three calls before
claude-opus-5-5, claude-sonnet-5-5 and gpt-oss-120b showed up, and
OpenCode 2.x calls it once.

What changed:
- packages/agy-cli/index.mjs:
  - The offered-model probe now starts in listAgyModels' .then, as soon as
    a non-empty list arrives and a caller asked for probeOffered. It no
    longer waits for the next models() call. A hung or failed `agy models`
    still never spawns the probe.
  - probeSignedIn reuses the `agy models` stdout it already has. The same
    parser (parseAgyModels, split out of listAgyModels) fills
    cachedModelCatalog, and the probe starts. Sign-in waits for the probe
    for at most 3s.
  - The offer (acpOfferedModels, acpOfferedKey, offeredProbeAt and any
    in-flight probe) is forgotten when agyPath changes and after a new
    sign-in finishes. A generation counter drops the answer of a probe
    that started before the reset.
  - provider.warming() returns a promise while a list or probe is still
    running, and null when nothing is.
- scripts/opencode2.mjs, copied byte for byte to every
  packages/*/opencode2.mjs: after the first background refresh, the
  adapter awaits hooks.provider.warming() once, for at most 60s, and then
  refreshes once more. It does not loop. Plugins without warming() behave
  as before.
- Not done: the issue's on-disk catalog cache (point 3), skipped as asked.

Known gap: agy-cli has no `config` hook, so under OpenCode 2.x the adapter
lists no provider for it. refresh() returns before it calls
provider.models(), so the follow-up refresh can't add agy's models on 2.x
until agy-cli gets a config hook.

Tests: test/testkit.mjs's fake agy takes a sessionNewDelayMs. The new
tests in test/catalog.mjs set 1.5s on both `agy models` and session/new
and wait for state through warming(), with no fixed sleeps:
- On a slow cold start, the first models() after warming lists Claude and
  GPT, from one probe spawn.
- authorize() on a signed-in agy fills the catalog, and the next models()
  runs no second `agy models`.
- The sign-in wait is bounded: with a 6s session/new, sign-in returns in
  about 4.5s.
- Changing agyPath probes again.
The hang test now awaits warming() before it counts acp spawns.
scripts/opencode2.test.mjs: the warming list is read a second time when
warming ends, and only once when nothing is warming.

Run on Linux (a separate test Mac was over its load limit):
- packages/agy-cli bun test: 17 pass, 0 fail.
- bun scripts/check.mjs agy-cli: ok.
- bun scripts/check.mjs (all packages): ok.
- Root bun test in a temp HOME: 8530 pass, 19 skip, 0 fail.

Broken by hand on Linux, each red, then restored green:
- No probe in the .then: the slow cold-start test.
- probeSignedIn drops the list: the authorize and bounded-wait tests.
- agyPath change keeps the old offer: the agyPath test.
- Unbounded sign-in wait: the bounded-wait test (7514ms).
- Probe also on a failed listing: the hang test.
- origin/main's index.mjs with the new tests: all four #1064 tests.
- Adapter reads the list once: the warming adapter test, and the
  copy-identity check.

Not tried: a real agy (no Google sign-in, no network). The reset after
login.finish has no unit test of its own.

Reported-by: hiee3
2026-11-13 10:59:13 +08:00
yetone 89a54951cc doubao-work 0.1.9: the plan's allowance and each model's multiple are read (qhyqhy1s on X)
The plugin had no auth.usage, so the Providers row said 暂无额度数据, and
models carried no rate. Now:

- usage reads POST /alice/commerce/sale/subscription/quota/summary/ through
  the app's own page (cookies sign it; the bare URL answers 200) and maps
  window_limit_section to windows (percent used, named by span when the
  reply has times, resetsAt from end_time; usage_exhausted reads 100%) and
  the plan's short_name. A 401, an empty reply or a failed fetch gives an
  error with signIn kept. An app the plugin never started is not opened.
- the model menu's rows keep their lines under the name, and a multiple
  written there ("2x", "x0.5", "1.5 倍") becomes the model's rate.

Run: bun test packages/doubao-work through mote-run, HOME in a scratch dir:
47 pass. Broke by hand: usage hook renamed and rate dropped, 3 new tests
red, restored, green. The quota reply shape was read from the real app
(a 标准套餐 account via a copy of its profile, bare URL).

Not tried: the multiple. The owner's account shows only auto, 豆包 2.1
Lite and Pro with no multiple, so what the reporter's menu writes next to
DeepSeek/Kimi/GLM was not seen; rateOf reads the common forms and a row
written another way stays without a rate. The window names for a span are
a guess (the one real window has no times, so it is named 额度).
Models cached by 0.1.8 get rates at the next menu read.
2026-11-13 10:31:36 +08:00
tungloongandtungloong 753a61f85c agy-cli 0.1.31: wait for MCP commit before cancelling steered tool turns (#1061)
When a client steers a live tool turn, agy-cli now waits for agy to commit the MCP responses (a tool_call_update, the next generation, or the prompt ending; AGY_BRIDGE_MCP_COMMIT_WAIT_MS, default 5s) before sending session/cancel. Before, the cancel could beat the response, and agy recorded "Tool execution was canceled". A clean steer keeps SQLite step usage trusted, and an unpolled LONGTOOL result stays in the steered prompt. A steer in progress is not evicted or reclaimed, and a second steer gets 503.

Reviewed at 01de2cc. Run on a separate test Mac (Bun 1.4.2, temp HOME): bun scripts/check.mjs agy-cli ok; bun test ./packages/agy-cli 17 pass. Broken by hand: with no commit wait, the smoke steer case, six steer-in-session groups and usage-settlement go red. Not tried by the reviewer: a real agy (the author's live run on agy 1.5.6 is in the PR).

Co-authored-by: tungloong <tungloong@users.noreply.github.com>
2026-11-13 08:21:35 +08:00
yetone 1a08f08817 agy-cli 0.1.30: a new agy session logs why the live one was not reused (#1058)
#1058: in one Claude Code conversation every request started a new agy
conversation, so Gemini 4 Carbon's cache read stayed at 0. The bridge
reuses a live session only when the conversation key, work dir,
instructions and history all match, and nothing said which one failed.

acquireProcLocked now writes one content-free stderr row per new
session ("[agy-bridge] {event: agy_bridge_session, action: session_new,
reason, conv, fresh, resumed, parked, history}"). reason is no_live (no
session under this conversation key), or for a live one that was
dropped: forced, dead, retiring, work_dir, instructions, history or
fresh_after_first. conv is the key's 12-char digest, so a key that
changes per request shows as a new conv each time. The rows have their
own 30/min budget, so they never crowd out the tool-state rows.
magpie writes plugin stderr into its log, so the reporter can send them.

Run (on a separate test Mac, temp HOME): bun scripts/check.mjs agy-cli
ok; packages/agy-cli bun test ./agy-cli.test.mjs 14 pass 0 fail;
test/repeat-batch.mjs 20 pass, test/conversation-key.mjs 31 pass.
Broken by hand: with the logSessionEvent call disabled, the new #1058
test fails.
Not tried: a real agy, or the reporter's Claude Code requests. This
does not fix the cache miss; it finds which check misses.

Reported-by: chrisjian
2026-11-13 02:40:04 +08:00
yetone 16b487fa8e agy-cli 0.1.29: release the Gemini 4 Carbon limits (jinzheio on X) 2026-11-13 00:56:28 +08:00
yetone 857d43a8c9 agy-cli 0.1.7: Gemini 4 Carbon (Ultra) gets its limits, 1M context and 262144 output (jinzheio on X)
Antigravity's fetchAvailableModels names Gemini 4 Carbon (id gemini-4-carbon,
"available to Ultra plan subscribers", maxTokens 1048576, maxOutputTokens
262144). agy-cli listed the model from `agy models` but gave it no limit, as
modelLimits knew only Argon and 3.8 Flash. Added the family with Google's own
numbers.

Run: bun test agy-cli.test.mjs (all pass) with HOME a temp dir. The new
catalog test is red on the old code (limit undefined) and green with the fix.
Real account: the owner's Antigravity account is free-tier and lists Carbon
as disabled ("Unavailable"); no Ultra account was available, so a Carbon
request was not sent. No region error from this machine (a gemini-3.8-flash
request through the live gateway answered).
Not tried: agy with an Ultra account; the reporter's region restriction.
2026-11-13 00:49:04 +08:00
yetone af7b4cc765 tabbit 0.1.4: a turn's prompt stays under Tabbit's character limit, so long transcripts stop coming back as 492 (#833)
Tabbit refuses a turn whose content is 20,500 characters or more. The answer is code 492 inside the SSE stream, after about 40s. The reporter measured it on 0.1.3: 20,490 characters pass and 20,500 fail. The limit counts characters, not bytes: 61 KB of Chinese at 20,410 characters passed. Concurrency of 2 and 4 didn't reproduce it. An OpenCode agent's system prompt plus the flattened history reaches that size quickly.

flatten now keeps a new room's prompt within 18,000 characters. It keeps, in order, the final user message (at most two thirds), the system prompt (up to 60% of what is left when there are earlier turns), and the earlier turns newest first. A turn that doesn't fit is clipped to its head and tail, or left out with an "[earlier conversation omitted]" note. A continued room's single message is clipped to the same limit.

Run: on a separate test Mac, `npm test` in packages/tabbit passed 88 of 88, and `bun scripts/check.mjs tabbit` was ok.

Broken by hand: with 0.1.3's index.mjs, the 4 new limit tests fail. A property test over system, turn-count and length sizes first caught two budget slips (18,029 and 18,016 characters), both fixed.

Not tried: a real Tabbit turn. I have no Tabbit account. The reporter offered to run their OpenCode case again.

Reported-by: Beyfish <Beyfish@users.noreply.github.com>
2026-11-13 00:26:53 +08:00
tungloongandtungloong a2e601dc21 agy-cli 0.1.28: tool schemas with $ref/allOf/oneOf reach the model with their fields (#1042)
Tool schemas that use $ref, allOf or oneOf now reach the model with all their fields (expandToolSchema).

Nullable unions are lowered to type:[X,"null"]. Inlining is capped by depth (counted only along $ref and allOf), by 8192 nodes and by 256 KiB. A tool with no schema gets a plain object. The ToolSearch fallback was dropped.

Run at 80d19737 merged with main 16e753e8: `bun test packages/agy-cli` 16 pass, check ok.

Broken by hand: lowering a nullable union to a single type makes 1 test fail, and removing the byte cap makes 1 test fail.

Not tried: a real agy turn with these schemas.

Co-authored-by: tungloong <tungloong@users.noreply.github.com>
2026-11-13 00:23:26 +08:00
yetone b195b4f5a9 doubao-work 0.1.8: every model in the app's menu is listed, Kimi K3.1 Pro 高速 too (ul3140773077392 on X)
Two causes of a short list:
- Kimi K3.1 Pro and Kimi K3.1 Pro 高速 both became id kimi-k3.1-pro
  (idFor drops Chinese), so tableFrom kept only the first. 高速 is now
  "fast", and two rows that still collide get a numbered id.
- An account that signed in before 0.1.4 had no models.json, so the list
  stayed at the three built-in models until its first request. The
  provider.models hook now reads the menu once when the list was never
  read (queued behind an ask, once a minute at most), and only from an app
  the plugin has started before (its data folder exists).
Picking sends the row's own label to pickModel, unchanged.

Run on mote (Bun, temp HOME): bun test packages/doubao-work 44 pass,
bun scripts/check.mjs doubao-work ok. Tests use the screenshot's ten
literal labels. Broken by hand, each red: the 高速 mapping, the collision
numbering, the ensureList call (3 fail, restored).
Not tried: the real 豆包工作 app (none on mote or this Mac signed in; the
Windows box has only 豆包, unsigned).
2026-11-12 23:20:25 +08:00
yetone 16e753e8bb antigravity 0.1.8: a manifest read that times out no longer pins 2.9.1 for six hours (#1057)
The User-Agent's version comes from Antigravity's update manifest. A
read that failed (5s timeout, often hit on a cold plugin host) left the
2.9.1 default in place for the full six hours. Google lists and serves
Gemini 4 only to newer releases, so under 2.9.1 the Argon and Carbon
models fell out of the list and a request for them got 404.

- The default is the manifest's version today, 2.31.2.
- The read waits 15s, and one that fails is tried again after a minute.
- A version that changes drops the model lists read under the old one,
  so the newer list arrives at once, not up to ten minutes later.
magpie puts delisted picks back when the list has them again.

Run on a separate test Mac (Bun 1.4.2, temp HOME):
- bun test packages/antigravity: 99 pass, 0 fail (4 new in
  version.test.mjs).
- bun scripts/check.mjs antigravity: ok.
- The manifest answered "version: 2.31.2" today.
Broken by hand, each red then restored:
- no retry after a failed read: 1 fail.
- no list drop on a new version: 1 fail.
Not tried: a real Antigravity account. The reporter's own test of
2.9.1 vs 2.31.2 on one token is what shows the version gates Gemini 4.

Reported-by: floodsource
2026-11-12 23:05:33 +08:00
yetone 507dbcc459 codearts 0.3.15: stop goes to the gateway as a string, an empty one not at all (Abandon332 on X, magpie#6342)
Huawei's gateway takes `stop` as a string only. Any array, [] too, came back
as HTTP 200 with InferHub.001001005.400 "The request param is invalid", which
magpie read as a plain 400 and rested the account for (182 times in the
report). prepareChatBody now sends the first non-empty string of a list, and
drops an empty or blank one or a value of another kind.

Run: bun test packages/codearts (204 pass). Broke it by hand: with the
normalizeStop call commented out the new test is red.
Not tried: a real CodeArts account (the reporter's table is the evidence).
2026-11-12 22:50:15 +08:00
yetone 4b35c34c34 agy-cli 0.1.27: a replay that fits goes unclipped; Claude Code's notes are not the loop's task (#1055)
clipHistoryMessage ran on every history message before the room check,
so a 20 KiB block in a small replay still went as 4 KiB head and tail.
History is now rendered whole first, and blocks are clipped only when
that is over the room; from there the over-budget path is as before.

The #1053 task finder took the last user message with no tool_result,
so a standalone system reminder, interrupt marker or local-command
caveat could be pinned in place of the real prompt. isUserTask skips a
user message whose text is only such notes; an image or any other text
still counts.

Not changed: the 112 KiB default (the installed agy 1.5.5's strings
don't show a 192,000-byte limit), a lone tool_result after the omission
note (history is text; it carries its id), and the issue's redesign.

Run on a separate test Mac (Bun 1.4.2, temp HOME):
- test/repeat-batch.mjs: 19 pass, 0 fail (2 new; 17 pass 2 fail on 0.1.26).
- bun test packages/agy-cli: 15 pass, 0 fail.
- bun scripts/check.mjs agy-cli: ok.
Broken by hand, each 18 pass 1 fail, then restored: clipping always;
the meta check reduced to an empty test; the local-command strip
removed; the interrupt strip removed; the over-budget clip removed
(the A16 >128 KiB test goes red).
Not tried: a real agy.

Reported-by: hiee3
2026-11-12 22:19:39 +08:00
yetone 9be580bc00 doubao-work 0.1.7: find 豆包工作 wherever it is installed (ul3140773077392 on X)
The binary was looked up only at %LOCALAPPDATA%\DoubaoWork (or DOUBAO_WORK_APP),
so an install in D:\Apps\DoubaoWork was never found. When the usual place
has nothing, the plugin now asks the system once: on Windows the Uninstall
keys (HKCU, HKLM, WOW6432Node: InstallLocation, DisplayIcon, UninstallString),
App Paths and the path of a running DoubaoWork.exe/Doubao.exe; on macOS
Spotlight by bundle id, ps, and one folder down in /Applications,
~/Applications and /Volumes/*. The usual place still wins and nothing is
asked then.

zhaodengfeng on X (third-party models): 豆包工作 keeps no local list of them
(model_config_list is served from its cloud config; no custom-model store
found in the app's data). Models on the user's own key are a direct call to
that vendor, not a Doubao task, so they are not served; README says to add
that API to magpie as its own provider.

Run: bun test packages/doubao-work (41 pass, 3 new assertions groups; the
Application\app candidate was red first). bun scripts/check.mjs. win-run on
xiaomi-gpu: the real registry and running Doubao.exe found
...\Doubao\Application\app\Doubao.exe with LOCALAPPDATA pointed at C:\nowhere.
Not tried: a real DoubaoWork install on D:\ (only 豆包 is on that box), the
macOS finders against a real DoubaoWork.app (this Mac has only Doubao.app and
Spotlight returned nothing; the folder scan covers it).
2026-11-12 22:14:27 +08:00