33027a8fb85a9f95ca41c019d760ff0193387195
657
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
33027a8fb8 |
aelios 0.1.0: Aelios memory recall and opt-in recording as gateway hooks (#549)
New package @magpie-community/gateway-aelios 0.1.0: asynchronous gateway hooks for Aelios memory, by sakisakisa-design (Aelios's author).
- Recall before each human turn, appended after the last user message. Recording of completed turns is opt-in (record: false by default).
- Traffic goes only to the user's own serverUrl (HTTPS or loopback HTTP, redirects refused, a key required). Only local and magpie-key origins by default.
- Local admission: an authenticated, dialogue-free GET /v1/hook/identities decides which model maps to which identity. Unmatched turns, or an unavailable list, send no dialogue.
- The request is slimmed (system prompts, thinking and tool results dropped, historical credentials masked). The recorded reply is slimmed to text and tool calls before the secret check and the send.
- Settings page served by a loopback Bun service (Host, Origin null and per-process token checks).
- The cleanMessageText/appendMemory logic ported from AGPL Aelios is relicensed MIT by its sole author (PR thread).
Run at the reviewed head 620cd47 on mote (macOS, Bun 1.4.2):
- bun test packages/aelios: 178 pass. Full HOME=$(mktemp -d) bun test: 4176 pass, 0 fail. Merged onto main
|
||
|
|
39de03001d |
page-chat 0.1.6: one switch uses every MCP server in magpie's Library (Magiczerowxy/magpie-chat#4)
ferocknew asked for a way to give new chats every MCP server without ticking each one. The MCP list in the settings sidebar now starts with a switch, "使用 magpie 的全部 MCP 服务器". On, a chat uses every server in library.json, read again on each chat, so a server added to magpie later is in too; the rows show checked and disabled. Off (the default, and what a 0.1.5 settings.json reads as), ticking works as before, and the ticks set before turning it on come back. The whole path: the setting is mcpAll in the service's settings (cleanSettings keeps it, default false). runChat wants tools when mcpAll is on even with nothing ticked, and pickServers() picks every Library server; "检查连接" (/api/mcp/tools) checks the same set. The page sends useTools when mcpAll is on. The service picks servers from the saved settings, while the page saves them 320ms after a change, so send() now saves pending settings before /api/chat; a switch flipped just before sending (or a server just ticked) counts. Run (mote, bun 1.4.2, HOME a temp dir): bun test chat.test.mjs, 28 pass; bun scripts/check.mjs chat ok. Three new tests: a chat against two fake Streamable-HTTP MCP servers gets only the ticked one with the switch off, both with it on and nothing ticked, a third added to library.json after turning it on, and /api/mcp/tools lists all three; a 0.1.5 settings.json reads as off; the page's wantsTools and the save-before-send. Broken by hand: pickServers ignoring mcpAll fails the first two tests; cleanSettings dropping mcpAll fails the same two; useTools back to "mcp ticked" fails the third. Real page, Playwright 1.62.0, 1200 and 760 wide: switch off by default with the old tick, on makes every row checked and disabled, flipping it and pressing Enter saves settings before /api/chat with useTools true, still on after reload, off brings back the old tick, rows clickable. Chromium on mote, 18 of 18; WebKit on Linux (WSL magpie-desktop), 18 of 18, since WebKit on mote didn't launch within 180s (other sessions' WebKit processes were running there). Not tried: a real magpie window with real MCP servers and a real model call (the gateway in the browser run was absent; tool lists came from fakes); stdio servers under the switch (same pick, only http was run); macOS WebKit; languages other than Chinese (the page has no i18n). |
||
|
|
3d56e7e4d6 |
kiro 0.1.23: an effort without thinking asked for is sent no thinking (#538)
thinking() turned thinking on for any output_config.effort above low,
even when the request had no thinking object or had thinking disabled.
Claude Code's title and side requests carry an effort and no thinking,
and a turn with thinking turned off says disabled, so Kiro was sent a
<max_thinking_length> budget for them, or, for a model whose catalog lists
effort fields, adaptive thinking at that level. Low alone was spared.
Now only thinking.type enabled or adaptive asks for thinking, as
Anthropic's API and magpie's gateway (anthropic.go) read a request.
With thinking on, nothing changes: each of low, medium, high, xhigh and
max goes as additionalModelRequestFields {thinking: adaptive,
output_config: {effort}} when the model's schema lists it, else as the
10k/20k/30k/50k/50k budget.
Run: HOME=$(mktemp -d) bun test in packages/kiro on mote: 118 pass.
bun scripts/check.mjs: ok. Broken by hand: with index.mjs at HEAD~,
the new "an effort without thinking asked for" test fails, the
per-level test passes. A probe built the body for every level x
{adaptive, enabled, none, disabled} x {schema, no schema}.
Not tried: a live Kiro account whose catalog lists effort levels.
|
||
|
|
0b463793be |
page-chat 0.1.5: README names the settings.json gateway port (#542)
page-chat 0.1.5 documents the gateway port it now reads from magpie's settings.json (#534's follow-up). The README order now matches chat's code at |
||
|
|
20a3898bf5 |
page-chat 0.1.4: model brand icons, data-URI images only (a remote image is a link), gateway port from magpie's settings.json, by Magic_zero (#534)
page-chat 0.1.4, by Magic_zero (Magiczerowxy). This adds: - model brand icons in the picker and the transcript, from @lobehub/icons (MIT, chat/icons/models/NOTICE); - inline images, base64 data URIs only. A remote  image is shown as a link the user can click and is never fetched, so a reply can't send data off the machine through an image URL; - the gateway port read from magpie's settings.json, read-only and 127.0.0.1 only, after an explicit gateway or MAGPIE_ADDR; - a switch for the system prompt; - stdio MCP servers run in a workspace folder of their own; - code fences kept whole while a reply streams. The suggestion buttons and the 「模型」 label are gone from the empty state. finish() still renders a reply that arrives in one chunk (the fix from #498). Run at the reviewed head 8ded766, on the Mac mini (Bun 1.4.2, sandbox HOME): - bun test: 3871 pass, 0 fail, 9 skip. bun scripts/check.mjs: exit 0. - A Playwright probe ran the real service against a fake gateway that sends the reply in one SSE chunk, and recorded every request leaving 127.0.0.1. The reply carried md, http, protocol-relative and blob images, HTML img, srcset, picture, inline style url(), a <style> block, a link around an image, a reference-style image, a bare URL, KaTeX \includegraphics and \href, and a data:image/svg+xml with script, onload, <image href> and CSS url(); the probe also opened that SVG in the lightbox. No request left the machine and the reply rendered. Run in Chromium on the Mac mini, and in Chromium and WebKit on Linux (magpie-desktop). WebKit didn't launch on the loaded Mac mini. - Broken by hand: letting https images through safeImgSrc turns "the chat UI never auto-loads a remote image" red, and the probe records the request to attacker.example. finish() back to checking only .md-stable turns "finish() renders a reply that arrived in one chunk" red, and the probe shows an empty body. Not tried: the real magpie window, and a portable install's data/settings.json. |
||
|
|
659967c9bc |
agent-office 0.1.1: an agent another agent killed is stopped, and any agent not at work can be cleared
flying_crp (X, 2026-10-31): when one agent hands work to another and then
interrupts it from the command line, the delegated session hangs in the
Agent Office as abnormal and can't be cleaned up; it only goes once the
session is deleted in magpie.
The cause: a killed agent writes no end of turn. Reproduced in a sandbox
HOME with the real CLIs:
- Codex 0.165 under SIGTERM or SIGKILL: the rollout ends at the
function_call (on SIGINT it writes turn_aborted, which was fine).
- Claude Code 2.1.314 `claude -p` under SIGTERM: a tool_result
("Exit code 137") and no end_turn, and it removes its
sessions/<pid>.json. Under SIGKILL: the file ends at tool_use, and the
pid file stays with a dead pid.
The office read each file as at work, then "error · stuck" once quiet for
ten minutes, until hideAfter (6h, or never; a waiting session never
leaves). The page had no way to take one out.
The fix:
- lib/scan.mjs: for a source with a process folder (Claude Code's
<config>/sessions, also Qoder, WorkBuddy and CodeBuddy), a session
quiet mid-turn for 10s with no live process named in that folder is
read as aborted ("stopped"). A folder that can't be read, a
half-written file, or one that has never held a pid file means
unknown, and nothing changes. A pid file from another pidDomain (WSL)
counts as alive.
- page: Clear (清除) in the panel of any agent not at work (stuck,
error, stopped, done, waiting) hides it until its session moves again.
It is kept in the page's options as {key: at}, pruned to sessions
live.js still has. This covers Codex and every agent with no process
registry.
Run:
- On mote (mote-run): bun test in packages/agent-office gives 54 pass,
0 fail. bun scripts/check.mjs exits 0.
- killed.test.mjs uses the real killed files (test/killed, trimmed and
with paths replaced). With the old scan.mjs, 3 tests fail. With the old
model.js, 2 fail.
- End to end: the real office.hooks.mjs over a sandbox HOME holding the
killed Claude and Codex files and a live lead pid file. live.js had
claude "aborted" and codex "tool". Then the real page in list mode, zh,
at widths 1100 and 420: the Codex row shows 已 N 分 没有动静, its
panel shows 清除, clicking it removes the row, and options.set gets
cleared. Chromium ran on mote. WebKit ran on the Linux box (wsl-run),
because WebKit on mote didn't launch within 180s while ~108 WebKit
processes from other sessions were running. Screenshots were checked
at both widths.
Not tried:
- A Codex liveness signal: its thread-writer-locks are flock-only files,
which Node can't check. Codex relies on Clear.
- Windows: the pidDomain value and process.kill(pid, 0) there.
- Whether Qoder, WorkBuddy or CodeBuddy write pid files at all. Without
them, nothing changes for those agents.
- Gemini, Qwen, dsh and pi killed mid-turn: they have no registry and
rely on Clear.
- The page inside the real magpie window, and WebKitGTK.
|
||
|
|
d0d07168ef |
workbuddy 0.2.6: an empty tool_calls list is no call, so the filter's refusal is still caught (#540)
itspig (#540, 2026-10-31) ran magpie v0.1.2283 with workbuddy 0.2.5 on
the live account, through a [workbuddy, volcengine] group: the refusal
still reached the client and routing.jsonl had the workbuddy try
done/200 with firstText 3208, no try of volcengine.
The cause: copilot.tencent.com puts "tool_calls": [] on every delta, text
too (magpie f2c7536d7 recorded it for Qoder). unsaid let the reply
through at the first delta whose tool_calls was truthy, and [] is truthy
in JS, so the gate opened at the reasoning chunk and nothing was held or
taken out. itspig's paste had no tool_calls because it was read off
magpie after chatTidy dropped the empty list and Go re-wrote the chunk
with its keys sorted; 0.2.5's fixture was built from that paste.
unsaid now counts a tool_calls list only when it holds a call.
Run (on mote, mote-run):
- HOME=$(mktemp -d) bun test packages/workbuddy: 291 pass, 0 fail.
- bun scripts/check.mjs: exit 0.
- filtered.test.mjs: the paste's chunks with WorkBuddy's own framing
("tool_calls": [], "finish_reason": "" until the last, an empty
reasoning_content beside the line) cut every 1, 7 and 1MiB bytes; the
line split over deltas that each carry the empty list; a real call
still lets the reply through as it came.
- End to end, in magpie's plugin host (a magpie worktree's gateway test,
not committed there): this file loaded by the host behind a fetch
shim pointing copilot.tencent.com at a fake vendor, signed in with an
API key, in a group [workbuddy-plugin/deepseek-v4.1-flash, b/m], asked
as a streamed chat, a one-body chat, Messages (Claude Code's ask) and
Responses (Codex's ask). With 0.2.6, 8 of 8 hand on to b and say no
"Sorry", for the paste and for the wire framing.
Broken by hand:
- 0.2.5 (
|
||
|
|
b5cc78266f |
workbuddy 0.2.5: the filter's line is taken out with the newlines around it (#540)
itspig (#540, 2026-10-30) ran 0.2.4 against copilot.tencent.com and the refusal still reached the agent. The real chunk's content is "\nSorry, I can't respond to this question.\n" with finish_reason content_filter. filterSaid trimmed only the start, so the trailing "\n" made the text longer than FILTER_SAYS, the prefix test failed, and the chunk went out as an ordinary answer. filterSaid now trims both sides, and text that is only white space so far may still be the line (so a "\n" sent in a chunk of its own is held, not passed on). The reporter's suggested `t.startsWith(s)` is not taken: it would treat the line followed by real words as the filter's and drop those words at content_filter. `without` already removes the whole content field, so the newlines go with it. Run (on mote, mote-run): - HOME=$(mktemp -d) bun test packages/workbuddy: 286 pass, 0 fail. - bun scripts/check.mjs: ok. - filtered.test.mjs has itspig's literal last three SSE events (the " node" reasoning chunk, the refusal chunk, [DONE]), cut every 1, 7 and 1MiB bytes, plus newline-in-its-own-chunk, line-then-more-words and newline-then-answer cases. Broken by hand: - 0.2.4's trimStart filterSaid: the 3 literal-bytes tests and the own-chunk newline test go red (4 of 15). - The reporter's trim() + t.startsWith(s) with t !== "": the own-chunk newline and line-then-more-words tests go red (2 of 15). Not tried: a live WorkBuddy account; the trigger prompt was not run. |
||
|
|
4883f9437f |
workbuddy 0.2.4: the filter's canned line is taken out of a reply it ends content_filter (#540)
itspig (#540): deepseek-v4.1-flash on copilot.tencent.com, through a group, reasoned, said "Sorry, I can't respond to this question.", and ended finish_reason content_filter with 0 output tokens, all under a 200. magpie recorded the try done/200, never asked the group's next member, and DeepSeek Harness failed "The model refused to complete the request". unsaid() now reads a streamed chat's events: text that is still the filter's line (FILTER_SAYS, the issue's literal words) is held; when the reply ends content_filter with nothing else said, that text is taken out, so magpie sees reasoning then content_filter with nothing said, which it hands on (magpie holds DeepSeek's reasoning for that from its next release). Any other text goes as it comes, released at its first word that isn't the filter's; the same words ending stop, and a reply the filter cuts off after other words, go through byte for byte. Native (Messages) requests are not touched. Run on mote at this tree: HOME=$(mktemp -d) bun test: 3970 pass, 9 skip, 0 fail; bun scripts/check.mjs: every package ok. Broken by hand: without unsaid() in the chat path, the 5 refusal cases of filtered.test.mjs go red and the 4 pass-through cases stay green. Not tried: a real WorkBuddy refusal (I have no prompt that reproduces it); the stream's literal chunking is not in the issue, so the tests cut the line into one delta, three deltas, the finish chunk itself, and 7-byte writes. Only the English line from the issue is known; a Chinese variant would pass through as before. |
||
|
|
00de68a0f8 |
cursor 0.2.33: free credit (the plan's bonus and credit grants) on the card, with its limits
CryptoSarom on X (2116260605053321489): "magpie 似乎没法支持 cursor 的赠金读取,
以及赠金使用限制". The card read only the included pools and on-demand.
What Cursor exposes, as Cursor 3.x's IDE (workbench.desktop.main.js) and
cursor-agent 2026.10.01's schemas have it:
- GetCurrentPeriodUsage planUsage.bonusSpend (cents), remainingBonus (bool,
no amount) and bonusTooltip: the IDE's "+$X free usage on us" line.
- DashboardService/GetUsageLimitStatusAndActiveGrants activeGrants
(aiserver.v1.ActiveCreditGrant): totalCents, remainingCents, expiresAtMs,
allowedModelIds / allowedModelTags / allowedModelSelections (models it
may be spent on), allowedClientTypes ("glass" without "ide" is the IDE's
Cloud Agent credits), campaignName. The IDE's "Use your $X free credits"
banner reads it; it matches tags lower case with "-" as ".".
The card now shows Free usage (bonus spent, "more left" when
remainingBonus) and a window per grant (spent / total USD, runsOutAt and
runsOut at its expiry, models when limited, "(Cloud Agents only)" when
cursor-agent can't spend it). All are aside. Routing: a bonus with some
left, or a grant magpie can spend on every model, sets the spent pools
aside as on-demand does; a model-limited grant leaves its models out of
a spent pool (Cursor Models keeps a non-empty list, or goes aside). With
Included usage only on, none of this keeps an account served. A grants
read that fails leaves the card as before.
Run on mote at this tree: HOME=$(mktemp -d) bun test: 3960 pass, 9 skip,
1 fail (a test of my own, since fixed); then credit/usage/included-only
79 pass 0 fail; bun scripts/check.mjs cursor ok. Broken by hand: the new
credit.test.mjs against the old index.mjs, 9 of 9 red.
Real account (Premium, merged weekly, cursor-agent's sign-in, read only):
GetCurrentPeriodUsage, GetUsageLimitStatusAndActiveGrants,
GetCreditGrantsBalance, GetClientVisibleCreditGrants read; it has no bonus
and no grant, and the new plugin's card for it is unchanged (Weekly, Grok
Bot, On-demand). Those replies are credit.test.mjs's REAL_ fixtures; the
#1868 team account's real bonusSpend 14151 now shows "+$141.51 on us".
Not tried: a real account with a grant or remainingBonus true (none at
hand), so the grant fixtures follow the schema, and whether Cursor
really serves a spent pool on bonus is Cursor's word ("free usage beyond
what you've purchased"), not a request made past a spent pool.
|
||
|
|
f42a59adf5 |
codearts: an OfficeAce card for the same Huawei Cloud account (#522)
codearts: an OfficeAce card for the same Huawei Cloud account (#522, MYCF711) Adds the OfficeAce (AgentArts) provider to the codearts package, replacing officeace-auth; accounts signed in there keep working. Each card signs in on its own and holds its own record and refresh token, because a Huawei Cloud STS refresh token is spent once. A renewal writes only the record being renewed, so a removed account never comes back. Reviewed over eight rounds; reviewed head f7c2526. r8 is words only plus the writeSharedRecord -> writeProviderRecord rename (every caller and the test updated). Run at f7c2526 on mote: node --test packages/codearts/index.test.mjs 164/164 pass; bun scripts/check.mjs exit 0, codearts ok. Not tried: a real Huawei Cloud sign-in on either card. |
||
|
|
00f4d84b8f |
fingerprint 0.1.0: a page that checks whether a model answers like the one it claims to be (#516)
Adds the Fingerprint page plugin (packages/fingerprint): it checks whether a model behind the local magpie gateway answers like the model it claims to be.
Reviewed at 531ca11f4 (KaranocaVe). Run at that head merged with main
|
||
|
|
9d4c7ce558 |
kiro: xhigh and max go as Kiro's own effort levels; trailing system context goes before the question (#538)
Two problems from #538 (zengxiaosong): 1. xhigh and max both became a 50000 <max_thinking_length> budget. The plugin now reads each model's additionalModelRequestFieldsSchema from ListAvailableModels, as Kiro IDE 1.4.62 does: when the schema offers thinking.type "adaptive" and an effort enum under output_config (or reasoning), a level in that enum is sent as additionalModelRequestFields {thinking:{type:"adaptive"}, output_config:{effort}} and the XML budget is left out. A model with no such schema (every model on a Free account today: the schema is null), a level not in the enum, or thinking off, is sent as before. 2. System messages ending the conversation (Claude Code's environment context) were joined into the question. They now go as a user turn before the question, answered by "Understood." (Kiro IDE's placeholder for a missing assistant turn), and the question is the current message. Not moved when the question holds tool results or follows tool calls, so call/result pairs are unchanged. systemPrompt is not used: the reporter's account refuses it. Run (on mote, bun 1.4.2): - bun test packages/kiro: 115 pass. - Full suite as CI, HOME=$(mktemp -d) bun test: 3885 pass, 0 fail; bun scripts/check.mjs: ok. Broken by hand: - nativeFields never finding a model: the two schema tests go red. - contextFirst returning messages as given: the reporter's [user, system] test and the later-question test go red. - The new tests on origin/main's index.mjs: 6 fail (in part only because the new exports are missing there). Not tried: a real Kiro account whose catalog has a non-null schema. The only account here is Free, whose ListAvailableModels gives null for every model, so the schema shape is from Kiro IDE 1.4.62's source, and the fixture follows it. |
||
|
|
c38a364e6a |
nowledge-mem 0.1.1: return from the connection test page, by IceCodeNew (#537)
The connection test page no longer depends on window.name, which the app's frame navigation drops. The language travels as `/test?lang=xx` and the page always shows Back to settings, which calls history.back() in the frame. The page takes no return address. Host (loopback:<port>), the per-process token and Origin null/self are unchanged in handle(). 0.1.1: package.json and mem.mjs's User-Agent version were bumped together. Reviewed at 390130262eaaff2bf4bfd16b3483626c0c730d7c (every changed line in packages/nowledge-mem). Run at that head: - mote: `HOME=$(mktemp -d) bun test packages/nowledge-mem`: 53 pass, 1 skip (live), 0 fail. `bun scripts/check.mjs`: exit 0. - Broken by hand: dropping `history.back()` from the test page turned "the running service answers 403 ..." red. Dropping the `lang` query from settings.js turned "configuration page saves the Mem connection ..." red. Both passed again once restored. - Browser harness: a window frames the real page/settings.html under magpie's plugin-page CSP in an `<iframe sandbox="allow-scripts">` and runs the package's real service. Chromium ran on mote and WebKit on the Linux VM, because WebKit launches time out on mote right now. In both engines: Test connection opened /test?lang=zh, Back read 返回设置, and Back returned the frame to settings.html while the top window stayed at its own URL (it had a pushState entry before). The settings page was usable again afterwards. `lang` set to `"><img onerror>`, `__proto__` and `constructor` injected nothing. `lang` is only used as a key into a fixed table, and the label is set through textContent. Not tried: the real magpie app (its bridge.js was stubbed) and a real Nowledge Mem server. Nit, not blocking: `?lang=__proto__` or `?lang=constructor` gives empty button labels, because the lookup isn't Object.hasOwn. Only a hand-typed URL can do this. npm: @magpie-community/gateway-nowledge-mem has never been on npm. Its first version needs an owner (trusted publishing can't create a package), so magpie installs it from dist. |
||
|
|
28881086c5 |
zcode: the daily claim is tested on #503's real marketing/touch reply
kongbai01203 posted the real GET /api/v1/marketing/touch?seq=0 reply
(10-30 22:11 +08:00, comment 6526694290) for the account that claimed
ZCODE WEEKEND BUILD. It is in packages/zcode/testdata/touch-1030-wk.json
as their bytes. Their paste was cut inside
success_popup.description.content's HTML (2510 of 2628 characters), so
only the closing `"}}}}]}}` is added and their trailing "…" taken off.
0.1.39's parser handles it as it is; no change to index.mjs, no version
bump (the package's published files are unchanged):
- checkin: the one claim_zcode_plan button is claimed once with
{"plan_id":"zcode-v3-start-plan-1030-wk"}, named ZCODE WEEKEND BUILD;
the close button ("args": null) and the success popup's navigate and
copy_text buttons claim nothing, and nothing goes to touch/action.
- the same delivery with its claim button taken out is inactive, though
its background and success popup still carry the zcode_plan.
- after the claim, deliveries is empty (their second finding, count
theirs, bytes the real reply's top level): inactive, not failed.
- the card's claim line from the real feed: "1 · ZCODE WEEKEND BUILD".
What the real reply has that the 0.1.39 hand-made fixture didn't:
button text as {format, content}, a close button's args null, a bundle
background, resource_position and priority, and a success_popup inside
the banner repeating the zcode_plan.
Run on mote: HOME=$(mktemp -d) bun test (3880 pass, 0 fail) and bun
scripts/check.mjs (exit 0). Broken by hand: claiming a zcode_plan's
plan_id with no claim button turns "the real delivery without its claim
button" red (the hand-made closeOnly case stayed green); naming a plan
from a later zcode_plan when the first is the same turned the two
real-feed tests red. Not tried: a complete, uncut touch reply (the
reporter will post one at the next window), and a real claim through
the plugin.
|
||
|
|
2e580cfead |
zcode 0.1.39: gift plans are also claimed from the ZCode app's banner feed (#503)
kongbai01203 found on 10-30 that a ZCode claim banner's plan (ZCODE
WEEKEND BUILD, 500M GLM-5.3-Flash tokens) is in neither
/billing/preview nor /billing/current while the app shows the banner,
so 0.1.35's daily claim said "no ZCode gift plan to claim". The app
reads the banner from GET /api/v1/marketing/touch?seq=<n>: each
delivery's banner button with action type claim_zcode_plan carries the
plan_id, and the claim is the same POST /billing/claim. Their capture
has a real code 0 claim reply ("Plan claimed successfully.").
- toClaim reads both lists (the feed first, then the preview) and keeps
each plan_id once; claimDaily and the card's claim line use it.
- The feed goes out with what the capture shows the app sends: the
session, X-Device-Mid, X-ZCode-App-Version and X-Client-Language
(the system locale), seq counting up from 0 per process.
- A list that doesn't read is failed (asked again later), never
"nothing to claim"; a plan claimed beside it is still named.
- claimOne is unchanged; README says the two lists and that a plan just
claimed may show in neither billing list until its effective_at.
Run on mote (macOS, Bun 1.4.2, temp HOME), on
|
||
|
|
b177d69b83 |
loomy: a too-long refusal is reworded so magpie tries a longer window (#529)
When Loomy answers 400, 413 or 422 with a body that says the content is too long (内容太长了 / 内容过长), the plugin now rewords that body to 上下文超出长度限制, the phrase magpie's too-long matcher recognises. The status code is kept. magpie then treats the reply as a context-length refusal and tries a model with a longer window, where before it gave up on the request. The rewrite is in retryableRefusal() and runs on the loader's !res.ok path. fake.mjs gains chatRefusal. Version 0.1.0 -> 0.1.1. Reviewed at 2bb41e0 (Mac mini, Bun 1.4.2, through mote-run, sandbox HOME): - Repo suite (`HOME=$(mktemp -d) bun test`): 3813 pass, 8 skip, 0 fail. - `bun scripts/check.mjs`: exit 0. - Broken by hand: with retryableRefusal returning null, 3 loomy tests go red (the over-length Kimi-k2.6 chat test, the 400 rewrite, and the 413/422 cases). They pass again once it is restored. |
||
|
|
eee889afab |
devin 0.1.27: SWE-2 never goes as a paid -lightning variant or a bare family id, and an unreadable model list is said, not swallowed
zws13579 (magpie Discord #general, devin 0.1.26): a Devin Free plan
account ($0) can't use SWE-2 through the plugin, while Devin CLI/Desktop
can. They listed five places SWE-2 could be lost silently; checked each
against the code:
1. configsFor swallowed every error (real). Its reason is now kept
(c.error), logged once to stderr when the asks start failing (the host
routes it to magpie's log), and usage adds an aside row "Free models:
unknown: Devin's model list couldn't be read (<reason>)" when a quota
window exists and Devin has never answered for the account. The windows
still count every model then (a failed read means unknown).
2. notModels only rides on a window (as designed: with no window nothing
counts SWE-2). A plan with no quota window gives none and no error;
a test holds that. The real gap behind it was 1, now visible.
3. A family the account's list leaves out (picked from SNAPSHOT's list,
which the OpenCode config offers) went to Devin as the bare family id
("swe-2"). variantFor now falls back to SNAPSHOT's family, so it goes
as swe-2-high (swe-2-max at max). The listing is unchanged: no model
is added that the account's list doesn't have.
4. variantFor's effort-less default and listed()'s free check took
f.models[0]. Devin's captures (10-14, 10-15) list swe-2-high first, so
it isn't hit today, but a first -lightning variant (High cost tier)
would have sent effort-less SWE-2 to a paid variant and unmarked it
free. defaultModel skips such suffixed variants.
5. v2Models/v2Setup: not a magpie path. magpie's host loads server()
(DevinAuthPlugin), whose usage hook carries notModels; OpenCode 2 has
no usage hook, and a free model's cost there is already 0.
usage.test.mjs's stub answered GetCliModelConfigs with a JSON parse
error, so those tests ran with the model list unreadable; it now serves
a one-model list, so they test what they name.
Run (mote, from the repo root, as CI): HOME=$(mktemp -d) bun test:
3866 pass, 9 skip, 0 fail; bun scripts/check.mjs: every package ok.
Broken by hand: the new free.test.mjs against origin/main's index.mjs:
3 red (lightning default "swe-2-medium-lightning", bare "swe-2", no
"Free models" row), 6 green.
Not tried: a real Devin Free plan account. No Free plan GetUserStatus or
GetCliModelConfigs has been captured, so whether Devin gives a Free
account SWE-2 at the Free cost tier (its pricing lists free SWE-2 for
Pro) is unknown; nothing here assumes a shape for it.
|
||
|
|
1acaf4964c |
registry: add magpie-providers-hub (community, 5 providers) (#502)
Adds magpie-providers-hub (Gyl1219, third-party adapter of dsh-providers-hub) to registry.json as a community entry: hub-astudio, hub-accio, hub-lobsterai, hub-magicrew, hub-magicrew-intl. All five are the vendors' own products (iFlytek, Alibaba, Youdao, MagiCrew); no relays. Checked at reviewed head f7685c8: - npm 0.5.1 (latest dist-tag) tarball fetched into an empty dir, nothing run from it: shasum baafab667248930ef67e19dadd289414728965d5, 16 files. page/snapshot.js is the empty template; no AK-like strings, balances or channel data. Hosts are only the vendors' own domains and 127.0.0.1. - gitHead 8fe0abc exists in Gyl1219/magpie-providers-hub. Diff 0.5.0 -> 0.5.1: explicit files list, empty snapshot, buildSnapshot reuses a snapshot only when its runId is this process's. - On mote: HOME=$(mktemp -d) bun test: 3808 pass, 8 skip, 0 fail. bun scripts/check.mjs: passed. Not done: 0.5.0 and 0.4.7 are not deprecated yet (author's npm account blocked until 11-02). |
||
|
|
c5dc2e691c |
nowledge-mem 0.1.0: recall and opt-in capture from your Nowledge Mem, by IceCodeNew (#526)
Adds @magpie-community/gateway-nowledge-mem, an asynchronous gateway hook by IceCodeNew (#526): before each request it recalls from the user's Nowledge Mem (and the Context Bundle / Working Memory on a session's first turn), and, only when `capture` is turned on, imports completed conversations as Mem Threads. It applies to direct local requests and the `magpie-key` sharing key this computer writes into the user's own agents; other gateway keys, remote and unknown origins are never included. A page sets the connection and runs a real connection test through a loopback service guarded by Host, Origin and a per-start token. The package writes nothing into magpie's Library. registry.json gains one compact entry. Reviewed head 3f4ba91 (f9eb686 plus a maintainer commit adding a test that starts the service and expects 403 for a foreign Host, Origin and token). Run at 3f4ba91's tree on mote (macOS, Bun 1.4.2, HOME=$(mktemp -d)): repo `bun test` 3861 pass, 9 skip, 0 fail; `bun scripts/check.mjs` exit 0; packages/nowledge-mem 53 pass, 1 skip. Broken by hand: each of the service's four guards in handle() turns the new test red; earlier rounds broke the origin gate, the block escaping, the secret check and the cleartext-HTTP guard, each red. Not tried: a real Mem server, a real magpie with the plugin installed, Windows. Co-authored-by: IceCodeNew <32576256+IceCodeNew@users.noreply.github.com> |
||
|
|
5b4ef414e2 |
registry: PinK agent plugin (magpie-plugin-pink) (#514)
Lists PinK (magpie-plugin-pink, YuchenWell, MIT) as an Agent plugin. Only registry.json changes: one entry, unpinned, so magpie installs npm's newest version (0.1.1).
Reviewed at 78185d2 (the reviewed head):
- magpie-plugin-pink@0.1.1 from registry.npmjs.org: its sha512 matches dist.integrity. The dist diff against 0.1.0 is only the worker lifecycle fix (worker.mjs exits when its host's pid is gone; index.mjs refreshes launch.json before it spawns). There is no network call, no install script and no encoded code.
- Harness on macOS (sandbox HOME, mock PinK folder, network refused). Connect, switch and disconnect restore the files byte for byte. The worker exits within 1 s of its host, plugin on. On 0.1.0 it was still alive after 5 s. A second host spawns a new worker. A worker stays alive under host A after a short-lived host B leaves. No stray worker is left.
- The repo suite on a local merge with main
|
||
|
|
848497c40b |
orcaterm 0.1.1: QR sign-in null fields, OAuth quota, stable account identity (#510)
orcaterm 0.1.1 (hg1048596-pixel): - WeChat QR sign-in accepts the official bridge's null fields. - QR accounts read their AI quota through orcaterm.com's product API, with the token sent as the ot_session cookie only to https://orcaterm.com/cgi/api and redirects refused. - A QR re-sign-in reuses the same account, keyed by the stable OrcaTerm user id. - The README (en and zh) lists every host and what each one receives. Run at the reviewed head a9ab6853b (Mac mini, Bun 1.4.2): `bun test` in packages/orcaterm passed 101 of 101 with every non-loopback fetch and socket refused (none was attempted), and `bun scripts/check.mjs orcaterm` passed. Broken by hand at fa028746c, the last code change, each going red: the /cb null check, accountId on the QR result, and redirect: "error". |
||
|
|
c590a74057 |
codex-history 0.1.2: a group or fallback try is filtered with the tried provider's rule (#525)
A request through a Magpie group or fallback names the group, so 0.1.1's onRequest found no provider rule and sent old reasoning, ciphertext and item IDs to members whose filter was on. onProvider now filters each provider try with the tried provider's rule (`magpie:<ctx.provider.id>`, through aliases). A direct provider/model request filtered in onRequest is marked in ctx.state.historyFiltered and its tries pass it on. A try with no rule, a rule off, another protocol, the compact path or history that can't move is returned unchanged (onProvider can't reject). cases.json gains 10 synthetic provider-try cases in the shared scripts/middleware.mjs format (no real data). Run at the reviewed head c50f542 (on mote): - `HOME=$(mktemp -d) bun test`: 3776 pass, 8 skip, 0 fail. - `bun scripts/check.mjs`: exit 0. - PR's tests against the 0.1.1 middleware: 8 fail (the group/fallback cases and the export check), 34 pass. - Probes in magpie's own engine (moejs, origin/main 3bce283df, internal/middleware Run.Request + Run.Tried, not committed): a group with a filtered, an unfiltered, a rule-off member, a retry on the filtered one and a member with another include rule: each try filtered by its own rule, the retry byte-identical to the first, unfiltered tries byte-identical to the request. A direct request: filtered once in onRequest, its try, a retry and a fallback to another provider sent what onRequest left. ctx.state doesn't reach the next request. Red on 0.1.1 (group), red with the historyFiltered guard removed (fallback re-filtered) and red with onProvider setting the flag (retry unfiltered). - PROVENANCE: the shipped files' sha256 match unisong/magpie-codex-history-filter at 43e0b5c, which is on its main. Not tried: a real Magpie with real providers; a group whose members speak different protocols. |
||
|
|
254c3e7aef |
grok 0.2.3: Codex's output.encrypted_content is left out of include (#524)
Codex asks an OpenAI-named provider for output token replay with include ["reasoning.encrypted_content", "output.encrypted_content"] (codex-rs/core/src/client.rs). Grok answers 400 'Argument not supported: "output.encrypted_content" in "include" field'. rewrite() now drops that one value (and include when nothing is left), and its pre-filter also opens a body that names it, so an include-only body is no longer passed through untouched. reasoning.encrypted_content and the tool-output values xAI's docs list stay; store is not touched (Grok takes it). Tests: packages/grok/include.test.mjs, from the reporter's two bodies and Codex's include. Red on the old index.mjs (4 of 5; the 5th checks that accepted values stay). Broken by hand: without the pre-filter change the include-only case is red. Run on mote: HOME=$(mktemp -d) bun test (3782 pass, 0 fail) and bun scripts/check.mjs (exit 0). Not tried: a real Grok account; no Codex turn sent through Grok. Sealed copies an OpenAI model wrote earlier in a thread (encrypted_content on a message) are not stripped here; magpie's forVendor takes those out before a non-OpenAI provider. |
||
|
|
3968cdd75f |
workbuddy 0.2.3: a refused opening is said with a comma first, and remembered (#513)
A chat WorkBuddy refuses as an unapproved channel (11128) for an opening FLAGGED
doesn't know is sent once more with one more comma in the opening ("You are an
AI agent, powered by X.") before the system prompt is moved into the first user
message. The comma is set in system and assistant messages only; user messages
and tool results go out as written. A system prompt whose comma passed is
remembered (bounded at 256, like refusedSystems) and its next chats go with the
comma before the first send, so a tool loop is not refused on every step. A
refusal that stands names REFUSED.md (new) before the hint; that address is
only in the error returned to the client, nothing sent upstream names magpie.
Version 0.2.3.
Run at the reviewed head cb8a026 on mote (macOS), temp HOME, outbound network
denied by sandbox-exec (localhost allowed):
- packages/workbuddy `bun test`: 271 pass, 0 fail.
- repo root `bun test`: 3774 pass, 1 fail (layerfs import-limit, fixed on main
by
|
||
|
|
4d8d0310f9 |
codearts 0.2.6: an IAM internal id is never the account's display name (#518)
An account whose IAM phone read yields nothing no longer shows iam::<domain>:user:<name>, the hw... account name, a urn:, a uuid or a bare hex id as its card name. accountIdentityOf() walks the same candidates in the same order and skips any that looks like an id; with none left the name is "" and the host shows the provider's name. id/uid/accountId are unchanged (still the URN, as #483 settled), so no account is renamed. The only reader of .name is usage()'s `user` fallback. Reviewed at d8583da plus the reviewer's version bump (0.2.5 -> 0.2.6) at f77e5bb. Run on mote (macOS, Bun 1.4.2) at f77e5bb, from the repo root: - HOME=$(mktemp -d) bun test: 3763 pass / 0 fail (3771 tests, 298 files) - bun scripts/check.mjs: exit 0 Red on the old code: the PR's tests against main's index.mjs, 125 pass / 2 fail (both new tests). Broken by hand: displayNameOf without the looksLikeIdentifier skip -> "accountIdentityOf never makes an IAM id the account's name" red (126/1). Not tried: a real CodeArts sign-in whose phone read fails. |
||
|
|
3dd0f44c15 |
layerfs: the import-limit test uses a small limit, not 20,001 real files
The only red in `HOME=$(mktemp -d) bun test` at the root on mote ( |
||
|
|
57f3f90698 |
joycode 0.2.2: Responses efforts JoyCode refuses go as low, per measured model (#499)
On JoyCode's Responses models, an explicit reasoning effort that the backend refuses now goes as `low`. Which efforts are refused was measured per model on the live gateway on 2026-10-30. GPT-6 Astra and GPT-6.1 Sol refuse both `none` and `minimal`. GPT-6 Sol and GPT-5.6 Sol refuse `minimal` but accept `none`, which still goes as written. Unknown models, other protocols, and valid or missing efforts are unchanged. This answers the earlier review: every Responses model was probed, `minimal` is covered, and the full upstream errors with their supported values are in the PR.
Run at the reviewed head 3b654be, merged onto main
|
||
|
|
79b02cc568 |
workbuddy 0.2.2: DeepSeek Harness's opener keeps the harness's name (#511)
WorkBuddy refuses DeepSeek Harness's opener "You are an AI agent powered by DeepSeek Harness." as 11128 (#279). The plugin used to reword it into "You are an AI agent that helps the user with programming tasks.", which dropped the harness's name from the line the rest of a DSH prompt refers back to. It now adds one comma ("You are an AI agent, powered by DeepSeek Harness."), which the author measured passing WorkBuddy's whole-line check (400 11128 without the comma, 200 with it, copilot.tencent.com, 2026-10-30).
Run at the reviewed head 4830b16, merged onto main
|
||
|
|
5a9c776832 |
zcode 0.1.38: freeFirst, the plain model spends the account's gift first (#505)
freeFirst (a boolean plugin or provider option): a plain model request
spends the dual account's own live gift first, under the name the gift
lists, and falls back to the coding plan when the gift can't serve it.
Any gift failure (spent 1113/1005, block page, 4xx/5xx, its own
waited-out busy cap, a network throw) is replayed on the plan in the same
request with the plan's own busy patience; a caller's abort stays an
abort. -Trial entries keep their strict meaning. Off by default.
zcode 0.1.38.
Run at the reviewed head 7ae2ea15d (on main
|
||
|
|
7673cd06de |
zcode 0.1.37: an account with no gift plan to claim is no check-in event, not a failed check-in
hykql (Discord, magpie v0.1.2143, zcode 0.1.36) saw every ZCode account's
daily check-in fail with "gift plans to claim: no plan list in the reply",
a Start Plan account and one with no GLM Coding Plan alike. ZCode's
GET /billing/preview answers an account with nothing to claim with no
data at all, not data.plans []:
{"code":0,"msg":"","logid":"202610300535585c4e3de75769b684da87"}
(the owner's account, read 10-30 with GETs only, with and without the
X-ZCode-App-Version / X-Platform headers; both the same). #503's capture
of 10-29 had "plans": [], so 0.1.35 took a missing list as unreadable.
previewPlans now reads the list for both the claim and the card's claim
line: no data, data null, or data without plans (or plans null) is a
list of none, so the check-in is "inactive" (magpie shows "No check-in
event now"). call has already judged the code, so only a code 0 reply
gets here. Data that isn't an object, or plans that aren't a list, still
don't read and stay failed, never claimed.
Run (wsl-run on magpie-desktop, HOME=$(mktemp -d); mote was at load
220-250): `bun test` in packages/zcode, 152 pass 0 fail; the whole
repo's `bun test`, 3720 pass 0 fail of 3727 across 298 files;
`bun scripts/check.mjs zcode` ok. The new checkin test (the real
no-data reply, data null, data without plans, plans null) is red on
0.1.36's index.mjs (1 fail). Broken by hand: plans that aren't a list
read as none turns "a preview that doesn't read is failed" red; put
back, green.
Not tried: a real claim (no account has a plan to claim now), and the
official ZCode client's own parse of this reply (no ZCode app on hand);
the fixture is the vendor's real bytes. Not changed: #505 (freeFirst)
touches other parts of index.mjs.
|
||
|
|
219a8aa0a7 |
registry: add AWS Bedrock SSO (#508)
Lists the third-party npm package magpie-aws-bedrock-sso (provider id
bedrock-sso): Amazon Bedrock's Claude and GPT models through an AWS CLI
profile (SSO / IAM Identity Center), SigV4-signed, no Bedrock API key.
Reviewed at 5a66cee: registry.json only (+3 -1), based on current main.
The entry has package, name, providers and en/zh summary, no "community"
flag, as the other third-party listings (officeace-auth, @hoptoper/*).
bedrock-sso doesn't collide with magpie's bedrock / bedrock-mantle presets.
Package read in full from npm pack magpie-aws-bedrock-sso@0.3.3 (sha512
matches npm's dist.integrity; 9 files: index.mjs, lib/{credentials,
sigv4,models,converse,eventstream}.mjs, README, LICENSE, package.json).
No dependencies, no install/postinstall scripts, no telemetry. Requests
go only to bedrock-runtime.<region>.amazonaws.com (fetch refuses any
other host, port, query or redirect; region is regex-checked) and
bedrock.<region>.amazonaws.com/inference-profiles for the model list.
Credentials come from `aws configure export-credentials`, `aws sts
get-caller-identity` and `aws sso login`, run through execFile/spawn with
argument arrays; they are kept in memory only. Files read: section names
of ~/.aws/config and ~/.aws/credentials, and magpie's ~/.cache/magpie/
models.json. Nothing is written. Not a relay: Bedrock is the vendor's
own platform.
Run on mote at 5a66cee: a registry check (JSON parses, 61 entries,
unique packages and provider ids, en/zh summaries), HOME=$(mktemp -d)
bun test (3718 pass, 8 skip, 0 fail) and bun scripts/check.mjs (all ok).
Not tried: the package itself with real AWS credentials.
|
||
|
|
498358c04e |
kiro 0.1.21: choose direct AWS sign-in for a remote magpie (#507)
The Kiro browser sign-in asks first which way to sign in:
- AWS Builder ID registers a client with AWS OIDC (us-east-1) and opens
AWS's authorize page directly.
- IAM Identity Center asks for the organization's HTTPS Start URL and AWS
region (blank is us-east-1), then opens that region's AWS authorize page.
- Kiro sign-in page keeps the portal (Google, GitHub, other ways); a caller
without inputs (OpenCode's CLI) keeps it too.
The direct ways skip the portal's first loopback callback, so a magpie on a
server or in Docker needs one pasted callback address instead of two. Still
authorization code + PKCE, same scopes, same hosts (oidc.<region>.amazonaws.com,
Kiro's own API). The callback handler now takes each stage's own state and
path once, answers a stale or foreign address with 404 without ending the
sign-in, says 409 to a second paste while a code is traded, sends a repeated
portal address to the same AWS page, and a new sign-in ends the one left
behind and frees its port at once. Kiro's page's region and AWS issuer are
checked for shape (a region can no longer put another host into the OIDC
address). Version 0.1.20 -> 0.1.21.
Reviewed head: 236db712518305415f15651178696a59a72c4a8b (base
|
||
|
|
f6412abc6f |
GoAnyAPI: the Discover card shows its own logo, a homepage link and new summaries (0.1.1) (#506)
GoAnyAPI: the Discover card shows its own logo, a homepage link and new summaries (0.1.1) (#506) registry.json's icon was an https URL. magpie's icon() reads any name as a bundled icon file, so the mask failed and the card fell back to the generic cube. Without the registry icon, the card uses the package's magpie.icon, which magpie fetches and stores. Also adds the package's homepage and rewrites the en/zh summaries. Reviewed at 33624fbc: metadata only (+4 -3). Checked icon() in internal/gui/assets/app.js on magpie origin/main: an http(s) name goes to maskSpan("icons/<url>.svg") and falls back to generic, as the PR says. CI test and on-npm green. Kilo, Search1API and PowerContext's registry icons hit the same fallback; that is fixed on the magpie side. |
||
|
|
b9cbb9dd01 |
workbuddy 0.2.1: an enterprise (教育公益版, team) sign-in is named with its enterprise, kept beside the personal one
A person's personal account and their enterprise account (a team, or 「WorkBuddy 教育公益版」, picked on WorkBuddy's sign-in page after the phone sign-in) share the uid and the nickname. magpie's plugin host keeps one account per name and uid (settle in host.js), so signing in to the education account replaced the same person's personal account, and the two could never sit in one pool. A browser sign-in that WorkBuddy places in an enterprise is now named "nickname · enterprise name": the name from /login/account, else from the matching /v2/plugin/accounts entry, else "enterprise <last 6 of id>". A personal account's name is unchanged. Old data: an enterprise account signed in before keeps its old name until its Sign in again, which uses the same key and renames it in place; its free-model window, read from ledger rows under the old name, starts again (README says so). Run (mote, HOME=$(mktemp -d)): bun test in packages/workbuddy, 256 pass 0 fail; bun scripts/check.mjs ok. Broken by hand: accountName returning the nickname alone turns the 4 new enterprise.test.mjs tests red. Not tried: a real education account (the owner has none; the live /v2/plugin/accounts shows only a personal entry), so enterpriseName's presence in WorkBuddy's replies for 教育公益版 is from the web client's SelectAccount code, not a live reply; the id fallback covers its absence. |
||
|
|
63748b9d67 |
zcode 0.1.36: a gift bucket beside a Coding Plan is named by its model first (#504)
Danbuth's GLM Coding Max account had claimed ZCode's Start Plan (plan_id zcode-v3-start-plan-1029, named "ZCODE GLOBAL BUILD") and found no Start Plan on magpie's card. The plugin did read it: usage asks /billing/balance beside /quota/limit and adds every live gift plan's buckets after the Coding windows, whatever the plan type, every plan and not only the first. The bucket was the panel's third ring, named "ZCODE GLOBAL BUILD · GLM-5.3-Trial", which magpie's ring and account row cut to "ZCODE GLOBAL BUI…": neither the model nor the plan's kind. ZCode 3.16.3's own popover (host getStartPlanSnapshot, renderer "Today's balance") lists these buckets by show_name, apart from the Coding Plan's windows. So a gift bucket's name now starts with that (the picker's -Trial id when it counts a model) and the plan follows: "GLM-5.3-Trial · ZCODE GLOBAL BUILD". A gift-only account with several plans names them the same way round. Run (on mote, HOME=$(mktemp -d)): `bun test packages/zcode`, 151 pass 0 fail; `bun scripts/check.mjs`, every package ok, exit 0. The new test uses a real /quota/limit reply (owner's account, read in a sandbox HOME copy with GETs only) and the real ZCODE GLOBAL BUILD plan row from #503, times moved to now. Broken by hand (old label order): the new test and five others red; put back, green. Not tried: a real balance of the ZCODE GLOBAL BUILD plan (the owner's account has none), so its buckets take the shape of ganlerk's Start Plan balance. Not changed: magpie's tray panel shows at most three rings and the account row two windows, so beside a Coding Plan's 5h and weekly only the first gift bucket is on the panel; the rest are in the tooltip and on the Usage page. |
||
|
|
8ebbaa5880 |
zcode 0.1.35: claims each account's ZCode gift plans daily through magpie's check-in (#503)
ZCode hands out gift/resource plans that sit on an account until claimed,
and an account used only through magpie let them lapse. The plugin now has
auth.checkin, so magpie's daily check-in (`magpie accounts checkin`, and
Settings -> Daily check-in, where ZCode is off until the user turns it on)
claims them, the shape the MiniMax, Qoder and Loomy plugins use.
claimDaily reads GET /api/v1/zcode-plan/billing/preview (the list the card
already read) and POSTs {"plan_id"} to /billing/claim for each plan it
lists, with the account's ZCode jwt, X-Device-Mid, X-ZCode-App-Version and
X-Platform, as kongbai01203 captured them. The claim is judged by the body's
code: 0 claimed, 1003 "target already exists" (HTTP 200) done, 3007 or a
captcha message "captcha" (claim it in the ZCode app), anything else, an
HTTP error without a code or a body that isn't JSON failed. A failed read is
never taken as claimed, and no answer carries signIn, so a failed claim
leaves the account as it was. Nothing listed is inactive; a key-only
account is ineligible; an expired ZCode session is failed with no request.
A plan claimed now drops the account's cached route, so the next request
uses it. One failed among several makes the whole answer failed (with the
claimed ones named), so magpie asks again later and the claimed ones then
answer 1003.
Run (on mote, HOME=$(mktemp -d)): `bun test` in packages/zcode, 150 pass;
the whole repo's `bun test`, 3698 pass 0 fail of 3706 across 297 files;
`bun scripts/check.mjs zcode` ok. checkin.test.mjs covers preview empty,
one plan claimed with code 0 (request body and headers checked), 1003,
3007, seven unreadable claim answers, five unreadable previews, one
claimed + one failed then asked again, and key/expired accounts asking
nothing. Broken by hand: 1003 -> claimed and an unreadable reply ->
claimed turned three of these tests red; put back, green.
Not tried: a real claim that answers code 0. No account has a plan to
claim right now (every preview answers plans: []), so the code 0 body is
a fixture carrying only its code, and nothing else of it is read. On
10-06 a claim without the ZCode app's Aliyun captcha was answered 400
code 3007 (#30); if ZCode still asks that for a fresh plan, the check-in
says "captcha" and the plan is claimed in the app, as before. The real
1003 reply is in the tests as captured.
|
||
|
|
9608d0311d |
grok 0.2.2: Responses requests ask for Grok Build's loop checks (yetone/magpie#3594)
Grok Build 1.0.67 sends `x-grok-doom-loop-check: 1024` and `x-grok-exact-repetition-check: 64` on every /v1/responses request (seen in a mitm capture of the real CLI; the strings are in its binary next to "server reported doom-loop triggers for this response"). The plugin sent neither. Without them cli-chat-proxy lets a reply that repeats itself run on: it cut "* " repeated after ~4,265 output tokens, and a looser loop runs to max_output_tokens (128000 from Pi). That is the "repeats until max output, ends in Internal error during token generation" of #3594, seen on Pi -> magpie -> Grok but not in Grok Build. The fetch now sets both on a Responses request unless the caller set them already. Ruled out while diffing the CLI's request against magpie's: the system prompt. `instructions`, a system message and a developer message in `input` all reach the model (same input_tokens, 1266 vs 1249 without, same reply), so magpie's `instructions` is not lost. Run: - bun test in packages/grok on mote: 85 pass 0 fail. - bun run check (whole repo) on mote: exit 0. - Broken by hand: loop-check.test.mjs against index.mjs at HEAD: 2 of 3 fail (the headers are missing); with the change 3 pass. - Real account (owner's SuperGrok, sandbox magpie on origin/main with this plugin from disk, requests through mitm): the same "* " x3000 prompt over /v1/responses, /v1/chat/completions and /v1/messages each carried both headers upstream and was stopped after ~1,020 deltas (~1K tokens) with "Internal error during token generation", against ~4,265 tokens without the headers (direct curl, earlier). Not tried: the CLI's client-side doom-loop recovery (it resamples a confident tool-call loop with a reminder). The proxy's response.doom_loop_check event (a soft loop it reports, not stops) goes through as it came and nothing acts on it yet. |
||
|
|
24d0d428f0 |
registry: GitHub Copilot's card shows GitHub Copilot's logo
Its listing named no icon, so magpie's Discover page drew the generic plugin glyph for it, beside every other subscription's vendor logo. "githubcopilot" is the icon magpie bundles (internal/gui/assets/icons/ githubcopilot.svg) and already uses for the built-in Copilot. Run: registry.json parses as JSON; the icon file exists on magpie main. |
||
|
|
acb85ed880 |
autoclaw 0.2.13: Hermes Agent's identity lines are rewritten, not a 406
01huadalang (Discord #feedback, 10-30) runs Hermes Agent 0.22.1 through
magpie on AutoClaw 国内 (autoclaw-cn), and every chat came back
"406 Not Acceptable" with REFUSED_HINT: FLAGGED had no entry for Hermes.
Hermes opens every chat with its SOUL.md. Its seeded text (DEFAULT_SOUL_MD
in hermes_cli/default_soul.py, the same as DEFAULT_AGENT_IDENTITY in
agent/prompt_builder.py, read at tags v0.22.1 and v0.22.5) starts "You are
Hermes Agent, built by Nous Research.", and HERMES_AGENT_HELP_GUIDANCE adds
"You run on Hermes Agent (by Nous Research)". The run the gateway matches
wasn't probed (no AutoClaw account here), so both are broken, the way
"DeepSeek Harness" is:
- "You are Hermes" / "You are Hermes Agent" -> "You are the agent Hermes"
- "Hermes Agent" elsewhere -> "Hermes-Agent"
"Nous Research" is left as written: nothing shows the gateway matches it.
The class: agents magpie connects whose opening line names them as
"You are <name>", read from their own source, get an entry too, though
none has been seen refused: Gemini CLI (packages/core/src/prompts/
snippets.ts @2245ebd), the Python kimi-cli ("You are Kimi Code CLI",
agents/default/system.md @9ab1286) and goose ("You are goose",
prompts/tiny_model_system.md @361003e; its main "an AI agent called
goose" is left alone). Not covered, source closed or not read: Grok
Build, the new Kimi Code, Droid, Qoder, Copilot and the other agents in
magpie's internal/agent. REFUSED_HINT names Hermes Agent only, the one
seen refused.
As before: system and developer messages only, fixed strings so a cached
prefix stays put, both channels.
Run (mote, HOME in the run's folder): bun test packages/autoclaw: 48 pass,
0 fail; bun scripts/check.mjs autoclaw: ok.
Broken by hand: HEAD's index.mjs with the new tests: both new tests red;
the "Hermes Agent" entry alone removed: both red.
Not tried: a real AutoClaw request (no AutoClaw account here), so the
rewritten line is not yet confirmed a 200 on the gateway.
|
||
|
|
db0a9cdafd |
page-chat 0.1.3: smoother streaming, rename, width sync, English effort names (#498)
page-chat 0.1.3 (Magiczerowxy): streaming renders the settled blocks once and only the tail per frame; conversations can be renamed (PATCH /api/conversations/:id, title only, token-guarded); a Sync switch keeps the conversation and composer widths equal (composerWidth floor 35); effort names in English with xhigh; a draft row for a new conversation; a status line under each reply. An empty configDir now reads the library from the real config folder.
Reviewed at 7c0f68df74bef05ece6f037d574f0c50688c2bb8 (third round; the two earlier reviews' points were checked at this head).
Run on mote (macOS, Bun 1.4.2, Node 22, Playwright 1.62.0), sandbox HOME:
- packages/chat: bun test, 20 pass / 0 fail.
- Whole repo at the PR head: bun test 3284 pass / 8 skip / 0 fail; bun scripts/check.mjs ok.
- Whole repo at the PR head merged with origin/main
|
||
|
|
280d522830 |
kimi-work 0.1.15: renew membership tokens and keep existing accounts (#218)
Explicit sign-in now imports Kimi desktop's membership access/refresh pair when the desktop has one, and magpie renews it through the host's auth.refresh (conditional commit under the auth-store lock). Accounts saved through 0.1.14 (reference-only, no pair) keep reading the desktop's web token for usage, with no reconnect, no import and no refresh spent. The usage card is one monthly meter, with Code's share as text. Request-body reads follow the caller's abort signal. Kept from main (0.1.11 to 0.1.14): callback errors split into no session / Work 401 / HTTP-timeout-network (#425), per-uid account ids `Kimi Work · <uid6>` (#440), share-folder-missing as kept (#444), spent-quota 403 -> 429 (#465). Reviewed head 96f7f52501082e4747ef649d836d955a8ece3f4c, merged onto origin/main |
||
|
|
fdc5002319 |
orcaterm 0.1.0: Tencent Cloud OrcaTerm's assistant as a provider, with WeChat QR sign-in (#460)
New package @magpie-community/opencode-orcaterm-auth 0.1.0: Tencent Cloud OrcaTerm's own AI assistant (its monthly question allowance) as provider `orcaterm`, with WeChat QR sign-in (the same sign-in OrcaTerm's clients use) or a pasted console cookie. Credentials go only to Tencent's hosts (orcaterm.com, *.cloud.tencent.com) and WeChat's widget (open.weixin.qq.com, res.wx.qq.com). The nine models OrcaTerm's picker offers are listed; others resolve only as aliases. Per-account pacing at 10 chats/min, maxConcurrency 1; a JSON or SSE refusal inside a 200 becomes 429/401/502. registry.json gains its entry. Author: hg1048596-pixel (#460, replaces #422) The last review's three points are fixed at this head: the index.mjs header, toUpstreamBody and plugin-entry comments describe the code; the README's License links the package's own LICENSE; /cb accepts a bridge error without a code and shows it, and a later scan still finishes. Run at a75a2ae0fb554b3cb6ae879d5571b5dd7b2300a7 on mote (macOS, Bun 1.4.2), HOME=$(mktemp -d) as CI: - bun test packages/orcaterm: 88 pass, 0 fail - bun test (whole repo): 3624 pass, 8 skip, 0 fail - bun scripts/check.mjs: every package ok, orcaterm included - npm pack: 5 files (index.mjs, wechat.mjs, README.md, LICENSE, package.json); the extracted index.mjs imports with bun and its plugin returns provider orcaterm; node scripts/dist.mjs packs opencode-orcaterm-auth@0.1.0 - The earlier review's fake-upstream script against the packed package: 27 of 27 (JSON 429 with and without rate-limit words, SSE quota, rate and sign-in errors, envelopes in stream and JSON mode, per-account pacing, bearer headers, nine listed models, credentials only to lightai.cloud.tencent.com) - The /cb script against the packed wechat.mjs: foreign, missing and rebinding origins 403, wrong state refused, right origin and state finish the sign-in Broken by hand: requiring a string code again turns "callback preserves bridge errors without a code" red (87 pass, 1 fail). Not tried: a real OrcaTerm account, so neither the QR sign-in nor the real upstream. |
||
|
|
ecc4df3076 |
kiro 0.1.20: accept object tool schemas and run native web search (#492)
Kiro answers 400 REQUEST_BODY_INVALID to a tool schema whose root has
properties and no type, or is {}: the root is now sent as type "object"
(copied; nothing under it changed, another explicit root type left alone).
Anthropic's hosted web search (web_search_20250305) is searched with Kiro's
own web_search, sent as kiro-cli 2.35 sends it: InvokeMCP at the runtime's
root (AWS JSON 1.0, x-amz-target AmazonCodeWhispererStreamingService.InvokeMCP),
a JSON-RPC tools/call with {query} only, the profile ARN in the body and in
x-amzn-kiro-profile-arn. The model is offered kiro-cli's own web_search spec
(with __tool_use_purpose, which is stripped before the caller sees it and
never searched). At most 10 searches per request (max_uses honoured), a
turn cap of uses+2 (pause_turn), 30s timeout and a 1 MiB cap per search.
The config hook says searches: true, which the user's own setting overrides.
Other web_search versions are a 400 that names provider.kiro.searches: false.
kiro 0.1.19 -> 0.1.20.
Author: SemonCat (#492)
Run at 993f9bae5628cd3d525a838bdc0319cc58968c03 on mote (macOS, Bun 1.4.2),
HOME=$(mktemp -d) as CI:
- bun test packages/kiro: 94 pass, 0 fail
- bun test (whole repo): 3563 pass, 8 skip, 0 fail
- bun scripts/check.mjs: every package ok, kiro included
- npm pack --dry-run in packages/kiro: 0.1.20, 3 files; node scripts/dist.mjs
into a scratch folder packs opencode-kiro-auth@0.1.20
Broken by hand, each red in packages/kiro: schema root sent raw (5 fail),
profileArn left out of the search body (1), the 10-search cap removed (1),
__tool_use_purpose kept in the caller's input (1).
Checked against kiro-cli 2.35.0's binary: the web_search description, the
query's description and maxLength, the __tool_use_purpose text and the
InvokeMCP target/content type are its strings; the fixture's result fields
(title, url, snippet, publishedDate, domain, id, maxVerbatimWordLimit,
publicDomain) are the output its tool spec documents.
The search goes to the same runtime.<region>.kiro.dev host as inference.
Not tried here: a live search (the author's record has one OAuth account,
Haiku 5.5, us-east-1); an API-key search live.
|
||
|
|
3b3209e0dd |
zcode 0.1.34: a gift plan that starts later is named with its start, and gift buckets beside a Coding Plan carry their plan's name
windy (Discord): "添加zcode供应商的时候,好像无法区分Coding Plan 和Start Plan的额度?
例如今天23点要生效的Start Plan就没显示".
- A plan on /billing/balance whose starts_at is still to come serves
nothing yet: startPlan no longer routes to it (an "active" plan with a
future start would have been), and its buckets don't count. The card
names it in an aside line "ZCode gift plan not started yet", display
"<plan> · <start in local time>", soonest first.
- A coding account with a ZCode session reads the gift on every card
read, not only while a gift is live, so a coming plan shows beside the
Coding Plan. The route cache is read again when the coming plan starts.
- A gift-only account whose only plan starts later gets a card with that
line instead of "ended or never started".
- Beside a Coding Plan, every gift bucket is prefixed with its plan's
name ("Start Plan · GLM-5.1-Trial"), one plan or several.
Not known: which status ZCode gives a plan that hasn't started. The
fixtures use starts_at as the real balance/preview replies carry it
(Unix seconds) and try both "active" and an unknown status word; any
status but "expired" with a future starts_at is taken as coming. No
real account with a pending plan was read.
Run on mote: HOME=$(mktemp -d) bun test in packages/zcode, 142 pass
0 fail; pending.test.mjs under TZ=UTC, Pacific/Kiritimati and
America/Los_Angeles, 7 pass each; bun scripts/check.mjs, every package
ok. Broken by hand: with the old index.mjs, 6 of pending.test.mjs's 7
tests fail (the 7th, a plan whose start has come, passes on both).
|
||
|
|
01f6c09100 |
goanyapi: GoAnyAPI tools plugin, dynamic MCP catalog (#472)
Adds the GoAnyAPI tools plugin: its live MCP catalog (35 tools plus catalog and call_dynamic) behind OAuth or an API key. Reviewed at 02f69af53. Maintainer fixes in 19808db: offline loading, a cached failed read, isError propagation, one User-Agent. Run at this head: bun scripts/check.mjs ok; packages/goanyapi bun test 8 pass. The author ran a real sign-in through magpie on macOS: an OAuth sign-in, a tool call from Codex, a refresh after expiry, and an error path. |
||
|
|
3f73907aac |
workbuddy 0.2.0: WorkBuddy (China) daily check-in through the billing meter (#177)
WorkBuddy (China) claims its daily check-in credits through the billing meter's /v2 activity status and daily-checkin. Outcomes are done, ineligible, inactive, claimed and failed, all of which magpie's host accepts. A request that gets no answer is thrown, for magpie's 1-minute backoff. The AI build has no hook. The review merged main (0.1.48) in, resolving the conflicts in meter, the hook list, _internal and README. It also made an API-key account ineligible without sending a request, and set the version to 0.2.0. Run at d66f51c on mote, with a temp HOME: - bun test packages/workbuddy: 253 pass, 0 fail - the whole repo: 3521 pass, 0 fail (3529 tests) - bun scripts/check.mjs workbuddy: ok Broken by hand, each red: - dropping the API-key line: its new test - the hook on the AI build: "WorkBuddy AI's plugin has no check-in" - an unreadable 200 not thrown: the usage test and the check-in test Not covered: main's own invalidToken flag on a refused meter reply has no test that fails without it. That gap is on main and was kept as it is. |
||
|
|
676198bbb9 |
kimi-desktop 0.1.5: Retry-After is kept, and an owner record is never left half-written (#225)
Kimi Work's 429/503 through the desktop adapter now keep the upstream Retry-After (seconds and HTTP-date); no other upstream header is copied. The adapter's owner record is written whole to a temp file and published with an exclusive hard link, so a crash mid-write can no longer leave an empty adapter-owner.json that blocks every later host. A malformed record reports adapter_lock_invalid (and an access failure adapter_lock_unavailable) in status.json and the log, instead of failing silently; the README says how to recover. Review merge: main (kimi-desktop 0.1.4) merged in, package.json the only conflict, version 0.1.5. Run at 3f65c63 (HOME=$(mktemp -d)): - mote: bun test packages/kimi-desktop 36 pass, 0 fail. - Windows (xiaomi-gpu, win-run): 36 pass, 0 fail (hard links on NTFS). - Broken by hand, each reverted: Retry-After not forwarded -> its test red; the owner record written in place instead of linked -> 3 lock tests red; a malformed record silently returning false -> the malformed-record test red. Not tried with the real Kimi desktop app. |
||
|
|
f0ed150573 |
workbuddy 0.1.48: WorkBuddy AI's card shows the free model's daily token window (#299)
WorkBuddy AI's free model (deepseek-v4.1-flash) has a daily token window of its own (about 1e8 tokens per account per 24h) that the credit meter doesn't show. The plugin rebuilds it from magpie's usage.jsonl and adds it to the card as "Free model tokens" beside Credits. WorkBuddy AI only; the China build is unchanged. Review merge: main (0.1.47) merged into the branch, conflicts in index.mjs (imports, _internal) and package.json resolved, version 0.1.48. Added a test that the window reaches the WorkBuddy AI card from a ledger in the sandbox HOME, and that the China build's card has none. Run at 09718f5 on mote (HOME=$(mktemp -d)): - bun test packages/workbuddy: 237 pass, 0 fail (before the new test). - bun test (whole repo): 3499 pass, 0 fail; bun scripts/check.mjs: ok. - Broken by hand, each reverted: the card no longer pushing the window -> the new usage test red; an unreadable row time ending the read -> "a row whose time cannot be read is passed over" red. Not tried against the live service (no WorkBuddy AI free account). Co-authored-by: keeuu <keeuu@users.noreply.github.com> |
||
|
|
421cad6b25 |
qoder 0.2.50: a phone account's card shows its phone, not its uuid (#487)
A Qoder CN / QwenWork phone account's card shows its masked phone
(phoneLabel / cardName, usage's `user`), a real email first, instead of its
uuid; accountId stays exactly what main computes. A renewal reads the name
outside the plugin-wide lock from the account's own site (a VPC token never
goes to the public hosts) and renames nothing. Rebased on
|