dff29df4022d07e62e4d325fb319b4dda1d43bee
359
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
dff29df402 |
autoclaw 0.2.2: ZCode's and pi's identity lines are rewritten for the CN managed gateway (#245, #236)
autoclaw-cn's managed gateway (autoglm-acceleration-api.zhipuai.cn) answers
406 when the system text carries an agent identity line FLAGGED doesn't
cover. Two more entries, in the table's own style:
- "You are ZCode" (any case, anywhere; #245's probes) -> "You are the ZCode
agent". #245 found "You are an interactive ZCode agent ..." answered 200,
so the gateway reads the literal run, which the rewrite breaks.
- "operating inside pi, a coding agent harness" -> "operating inside the pi
coding agent harness" (#236). pi's line wasn't probed, so the rewrite
breaks both "inside pi" and "pi, a coding agent harness" and keeps pi's
name for the model.
Both rewrites are fixed strings, so the same prompt always leaves the same
way and a cached prefix stays put. Only system and developer messages are
rewritten, as before. Claude Code's entry is unchanged. REFUSED_HINT names
ZCode and pi.
No general fallback: agents such as opencode put the user's own AGENTS.md
into the system text, so a pattern like "You are X, a ... agent" would
rewrite the user's words, and nothing shows the gateway matches that shape.
Tests use each reporter's literal line: unflagged, unflag's role scoping
(ZCode in a system part rewritten, the same line in a user message and pi's
in a tool message untouched), and the CN managed path end to end.
Run (worktree at origin/main
|
||
|
|
47fbf634e7 |
grok 0.1.17: the sign-in page opens once, not twice (andyfmyth on X)
"magpie里的grok 登录验证 在mac下 似乎每次都会弹两次验证, 在浏览器窗口里": `grok login --device-auth` (Grok Build 1.0.50, the webbrowser crate) opens the device page itself, and magpie opened the same URL again. Reproduced in a sandbox HOME/GROK_HOME on macOS: grok's own device-code tab appeared in Chrome with magpie not involved, with and without SSH_CONNECTION set. What decides grok's own open, from the binary's strings and webbrowser 1.2.4's source: - macOS: NSWorkspace, $BROWSER never read (the macOS binary has no "BROWSER" string); - Windows: ShellExecuteW, no $BROWSER either; - Linux and the rest: $BROWSER, else xdg-open, skipped with no display. So the sign-in now says `opened: true` on darwin and win32 (magpie then opens nothing; magpie >= the commit that raises the grok mover min reads it), and elsewhere gives grok BROWSER=true, a no-op, so the opener stays the only one to open the page. OpenCode ignores the extra field. Tests: login.test.mjs runs the sign-in as darwin/win32 (opened, $BROWSER untouched) and linux/freebsd (not opened, BROWSER=true reaches grok). Both fail on 0.1.16's index.mjs (10 pass, 2 fail). Run: HOME=<scratch> bun test packages/grok: 49 pass, 0 fail; bun scripts/check.mjs: exit 0. |
||
|
|
ab38da681a |
workbuddy 0.1.25: WorkBuddy AI's "x0.34 credits" rates are read, not unknown (#216)
WorkBuddy AI's /v3/config gives fast-model, balanced-model and primary-model their credits as "x0.34 credits", "x0.59 credits" and "x3.31 credits". 0.1.24 read those as unknown, so the three had no rate. 0.1.25 carries |
||
|
|
c89cee5b2b |
workbuddy: a model's credits given as "x0.34 credits" keep their rate (#216, lokic7123-star)
WorkBuddy AI's /v3/config gives some models' credits with a unit:
"x0.34 credits", "x0.59 credits", "x3.31 credits" (fast-model,
balanced-model, primary-model). creditsOf passed "0.34 credits" to Number,
got NaN, and so treated a known rate as unknown. It now strips a trailing
whitespace-separated "credit"/"credits" before the same strict conversion.
Any other trailing text ("x0.34 bananas"), "credits" alone, "x-1 credits",
"xNaN credits", "xInfinity credits" and "" stay unknown, never free.
Reviewed at head 2dda6eb5d42e271e948e4fb5aef6d3e5db7627b5, merged with
origin/main
|
||
|
|
5a836745fb |
zed 0.1.10: the organization with a plan is the one asked under, not a default without one, and a 402 for the saved one moves the account (#232, ReneXiong)
ReneXiong's account has two organizations: the personal one on
zed_student and a non-personal default with no plan. orgOf() always took
default_organization_id, minted the model token for it, and /models and
/completions answered 402 "Organization does not have an active
subscription". planOf() fell back to the account's plan_v3, so the card
said Student over an organization with none.
What Zed's editor does (zed-industries/zed 56934ec): user.rs
update_authenticated_user starts in the default organization, else the
first; the title bar's organization menu calls set_current_organization,
which the LLM token's auth context (language_models cloud.rs
ClientTokenProvider) follows; plan() is plans_by_organization[current],
none when it has no entry (current_organization_has_no_active_subscription
treats a missing entry as no subscription; an unknown plan as Free). The
plugin has no switcher, so it now picks as a user switching would:
- the organization the sign-in saved, while it still has a plan that
calls models (any but Free) and models aren't turned off for it;
- else the default, if it has one; else the personal one with one; else
any with one;
- none with one: what Zed picks (saved, else default, else first).
planOf names the picked organization's own plan ("" without an entry);
only a reply with no organizations falls back to plan_v3.
A sign-in saved before this under the unsubscribed default is moved on
the first 402 (llm_tokens, /models, /completions) or empty list: the
account is read again, moved if another organization has a plan, the
move saved through client.auth.set (and kept in memory in case the save
doesn't land), and the request asked once more. The usage hook re-picks
the same way. The model-token cache and the model list are keyed by
organization now, so a move mints and lists anew. There is no explicit
organization choice in the plugin or in magpie to respect; the saved
organization is the sticky one.
Run (bun 1.4.2, macOS, worktree at origin/main
|
||
|
|
8cdf2d2020 |
grok 0.1.16: a sign-in with no email is kept by its xAI user id, and a login that leaves none says where it looked (llllleo9 on X)
llllleo9 couldn't add Grok: grok login --device-auth exited 0, and the
sign-in failed with "grok login finished without an account".
Grok Build 1.0.62 was run in a sandbox HOME. The stand-in auth.x.ai sat
behind an HTTPS_PROXY MITM, with its CA passed through
GROK_EXTRA_CA_BUNDLE, and sandbox-exec denied opening a browser. The CLI
takes email and user_id from the id_token's claims alone. With no email
claim (an xAI account signed in through X), it writes "email": null and
still prints "✓ Signed in". When Grok Build's own home is already signed
in, the plugin signs in beside it and demanded an email, so that sign-in
failed.
- An account is now told apart by its email, else its user_id, else the
token's sub. saved() and the refresh path's remember() use the same
account id.
- GROK_AUTH_PATH is now left out of the CLI's run. With it set, 1.0.62
keeps the sign-in at that file, and the home the plugin reads stays
empty (seen in the same sandbox). The login always runs with envFor(home)
now, not process.env.
- A login that finishes with nothing readable now says what grok said,
which file it read and what was there (no file, not JSON, no token,
or no account). It also points to "Use Grok Build's current sign-in".
Run:
- TMPDIR and HOME set to a scratch dir, bun test packages/grok: 47 pass,
0 fail. The six new login tests FAIL with 0.1.15's index.mjs.
- bun scripts/check.mjs grok: ✓.
- node --check and git diff --check are clean.
- The plugin was run against the real grok 1.0.62 and the stand-in x.ai,
with the CLI home already signed in:
- id_token without email: 0.1.16 returns success with accountId
"user-1". 0.1.15 returns "grok login finished without an account",
the reporter's message.
- GROK_AUTH_PATH set: 0.1.16 returns success, 0.1.15 fails the same way.
- login.test's "a login's link is still handed on" timed out at 5s in 2 of
10 runs alone, on 0.1.15's code too. That is #160, which another session
has taken; the data point was added there.
Not tried with a real xAI account: whether xAI's token for llllleo9's
account lacks the email claim, and whether their Grok Build was already
signed in.
|
||
|
|
779388ba04 |
zed 0.1.9: a signed-in account whose model list was never read says why, instead of showing the six pre-sign-in models as its own (#229, ReneXiong)
ReneXiong's Zed Student account (an organization without an active subscription) showed "zed (Zed, 6 models)" with no error: the six models the config hook declares before sign-in, with their hard-coded limits. provider.models handed those back whenever /models failed and no list had been read for the account. The likely path for this account is a 200 whose models are all disabled: parseModels throws "Zed lists no models for this account", the hook returned the declared list, and magpie's host, seeing the last fetch answer 200, didn't mark the list as fallen back, so nothing said it wasn't the account's. Now, with no list ever read for the account, the hook throws the reason (Zed's own "Zed: ... (status)", "Zed lists no models for this account ...", or "Zed: this account's models couldn't be read: <cause>"). magpie's host takes a thrown models error as fellBack with that message as listError, and the editor and `magpie providers` show "couldn't list its models: <reason>". A list read before is still kept on a later failure, as it was. A 401 for the model token still marks the sign-in expired. Tests (bun 1.4.2, packages/zed): models.test.mjs 7 pass. With the old index.mjs and the new tests, 3 fail: "the list refused with the token just minted", "Zed down before any list", "a 200 listing nothing callable" (each got the declared models back). Whole package: 33 pass, 0 fail. Siblings: minimax, qoder, trae, raccoon, workbuddy and opendesign also return provider.models on a failed list. Each of those checks a response status magpie's host sees, so a failed read is marked as fallen back with its HTTP status; not changed here. Not tried against a real Zed account. |
||
|
|
0a998a8a7f |
antigravity-cloak 0.1.0: Claude Code and Claude Desktop on an Antigravity account
Antigravity answers a system prompt that reads as Claude Code's or the
Claude Agent SDK's with a 429 "Resource has been exhausted", whatever
quota is left (xzplzpl on X). Tried with a real account, it matches
"x-anthropic-billing-header:" and "You are a Claude agent, built on
Anthropic's Claude Agent SDK", and lets the same prompt through with a
U+200B inside each. This middleware puts one after the first letter of
both words, in system text only (Anthropic system, Chat/Responses system
and developer messages, Responses instructions, Gemini
systemInstruction), and only in what an Antigravity account is sent: it
uses magpie's new onProvider hook (v0.1.1283), so a Claude subscription
or any other provider in the same routing group gets the prompt as the
agent wrote it. Options: extraWords, accounts, off. The README says the
ban risk and what happens if Google changes its match. After hexiaolv's
magpie-antigravity-cloak (MIT), which changes every request.
scripts/middleware.mjs: a case's "provider" runs the request on through
onProvider with ctx.provider, and expect_request is that try's body.
Run:
- HOME=$(mktemp -d) bun test: 1783 pass, 0 fail (the package's 12 cases
among them). bun scripts/check.mjs: every package ok.
- Real use: magpie built from e44b9aef3 in a sandbox HOME, a real
Antigravity account, this package added from its folder. Claude Code
2.1.302 `claude -p` on antigravity/gemini-3-flash answered; with
{"off": true} the same run got the 400. /v1/messages with the billing
line, the SDK line and Claude Code's three system blocks: 200 each on,
400 each off.
|
||
|
|
d556ef8dda |
zen-free 0.1.11: a call of a tool the agent doesn't have reaches the agent as called (#209, xiotbox)
#209: since 0.1.3 (#76) a call whose name the agent has no spelling of
(DSH with pwsh declared: psh, pash, ppwsh, pshh, bash, shell_command) was
left out with a text note, and a reply of only such calls was rewritten
to a plain stop. DSH read that as a finished answer: 16 of xiotbox's 19
cases ended an autonomous turn, and the model never saw an error it
could correct.
Now nameGuard answers the model's own name when no declared tool folds
to it, so every protocol (Chat JSON/SSE, Responses, Messages) hands the
call on with its id, arguments and tool-call finish, as every other
provider in magpie does. The agent answers an unknown name itself (DSH's
ToolRuntime, Claude Code's "No such tool available", Codex's
"unsupported call", OpenCode's invalid tool) and the model corrects it.
Case and separator folding (todowrite -> todo_write, bash -> Bash) is
unchanged, and an ambiguous fold is still never guessed: it goes on as
called. Only a call with no name is still left out with the note. Any
correction budget is the agent's, as with any provider; the plugin keeps
no per-turn state.
Tests: the #76/#209 names (bedit, bcp, ash, mcp__netcatcatty__unused,
psh, pash, ppwsh, pshh, shell_command) alone and beside a declared call,
JSON and streamed, in all three protocols: the call arrives with its id,
no note, no error, a tool-call finish; a Responses or Messages stream
comes through frame for frame. index.test's plugin-level case (loader
fetch against a local fake Zen) now expects an undeclared `edit` handed
on as a tool call. The leave-out machinery tests use a nameless call.
Run:
- packages/zen-free `bun test`: 174 pass, 0 fail. With nameGuard put
back to `|| null`: 28 fail.
- `node --test` (Node 25.8.2 and 22.22.0): 171 pass, 3 fail, the
"sends OpenCode's own headers" tests, red the same on origin/main
|
||
|
|
0a2496bb3a |
cursor 0.2.19: conflicting native batch counts rebuild once from history before any output (#207, nicegui)
A Cursor native Run whose step lists two different tool counts (a Codex-to-Cursor failover hit "inconsistent native tool count") now retires the owner instead of throwing. When no native result was submitted to that Run and no Chat output was exposed, the request is rebuilt once from Chat history (the same stateless rebuild the missing-count case uses), with reason=inconsistent-batch-count in X-Magpie-Cursor-Continuity. A Run that had a result submitted, or a stream that already sent output, still returns the error. The decoder stops reading the failed Run at once. Cursor 0.2.19. Reviewed at c43b93c (on main |
||
|
|
0b58032fa3 |
qoder, workbuddy: README on credit-model refusals while credits remain (#201)
README sections for WorkBuddy and Qoder on why a request can be refused while the account still shows credits. They cover: - the exact model id versus the display name; - WorkBuddy 5.6+'s encrypted desktop sign-in and the browser route around it; - 11140, the restricted account (magpie#1849); - Qoder's 10605, a queue answer, not a lapsed sign-in (#185, 0.2.18); - a CLAIMED check-in that is not a new grant (magpie#2696). This is docs only. Reviewed at 76cfb6d: two README files, +66 lines, no code. Checked each claim against the source: - packages/qoder/busy.test.mjs exists; - workbuddy usage.test.mjs covers sign-in, usage and chat against a sealed desktop file, and asserts the file is unchanged; - magpie's `plugin use` and `plugin list` exist (internal/cli/plugins_cli.go); - magpie#2696 is the open native-check-in cache issue. bun scripts/check.mjs qoder and workbuddy both pass. No version bump. |
||
|
|
992cff84af |
trae: the README's check-in outcomes and the 9074 test name say what the code does
#178's README called 9095 done and 9074 failed. The code answers both as ineligible, the same as magpie's built-in check-in, so that 9074 isn't asked again that day. The test asserting ineligible was named "is failed". Docs and a test name only, so no version bump. bun test packages/trae/native-checkin.test.mjs gives 9 pass, and check.mjs trae is ok. |
||
|
|
1d58133eaa |
trae 0.2.17: Trae CN's daily check-in through the plugin (#178)
Trae CN's daily check-in moves into the plugin as auth.checkin. It asks
/trae/api/v2/ug/checkin_credits/status and then /claim through ownRequest,
so it carries the same JWT renewal, IDE headers, {req_source: 1} body and
16-digit ugDevice (#194) as every other ug page. Trae Global answers
inactive. 9095 on the claim is ineligible, the same as magpie's built-in
traeRefused. 9074 on the claim is an answer for the day: ineligible, with a
hint to check in in the Trae CN app. The built-in calls that own-app, which
the plugin protocol doesn't have. trae 0.2.17.
Run at the reviewed head 4e9bb87 (on top of origin/main 63a3d2a..c397e96):
- bun test packages/trae: 160 pass, 0 fail. The global.test.mjs and
stream.test.mjs failures the author saw did not reproduce.
- bun scripts/check.mjs trae: ok.
- Broken by hand, one at a time, and each turned native-checkin.test.mjs red:
9074 mapped to failed; the ugDevice line in ownRequest removed; the
unreadable-claim guard removed.
- magpie's plugin host (yetone/magpie 85eef5d87 build, sandbox HOME, a copy
of the package pointed at a fake Trae on 127.0.0.1:18764), via
`magpie accounts checkin --json`. The results were claimed 100, 9074
ineligible with the app hint, 9095 ineligible, and checked_in done 100
with no claim sent. Status and claim both went out with
x-device-id 2866487253502651 and {"req_source":1}.
|
||
|
|
c397e96b77 |
qoder 0.2.18: a trimmed or wrapped 10605 is busy, not a lapsed sign-in
Releases #185. Run at this head: bun test packages/qoder: 138 pass, 0 fail; bun scripts/check.mjs qoder: ok; git diff --check clean. |
||
|
|
29746c7c1e |
qoder: test that a BOM before a stream chunk's body doesn't drop its text
#185 trims a chunk's body before parsing it in events(), and nothing tested it. The envelope carries the BOM JSON-escaped, so the response's own decoding doesn't strip it. Run: bun test packages/qoder: 138 pass, 0 fail. With JSON.parse(inner) back, the new test goes red (1 pass, 1 fail in stream.test.mjs). |
||
|
|
656f3a1fb5 |
qoder: a trimmed or wrapped 10605 is busy, not a lapsed sign-in (#185)
`failure` parses the trimmed body, so a BOM-prefixed 10605 (the SSE envelope carries it as a JSON-escaped U+FEFF that `res.text()` doesn't strip) keeps its 503/Retry-After instead of reading as a lapsed sign-in. An outer body with no code, or code 401/403, whose message is a 10605 body is unwrapped to it; explicit 105/110/406 codes stay authoritative, and malformed or array messages are not unwrapped. Refs #167, #181. What was run at c9e39e0 (reviewer, bun 1.4.2, macOS): - bun test packages/qoder: 137 pass, 0 fail. bun scripts/check.mjs qoder: ok. - Broken by hand: without the unwrap, the 8 wrapper tests go red; parsing `text` instead of the trimmed `msg`, the BOM test goes red; unwrapping regardless of the outer code, the explicit-code test goes red. The `inner.trim()` in events() had no test; a follow-up commit adds one. - magpie (yetone/magpie main 85eef5d87) in a sandbox HOME, a copy of this package with api3/openapi pointed at a local fake, a planted plugin-auth.json, `magpie provider test qoder`: a 403 `{"code":403,"message":<10605 body>}`, the SSE `{"message":<10605 body>}` envelope and a BOM-prefixed 403 each gave 503 "Qoder is busy for efficient (this plan's queue: p3); try again in 30s"; a 105 still gave 401 lapsed. main's package gave 401 lapsed for the first two. - Not tried: real Qoder accounts. |
||
|
|
a73237c74c |
codex-history 0.1.1: historical web_search_call replayed as text after reasoning is filtered (#204)
Historical native `web_search_call` items become a labeled assistant text message (recorded status, action, queries and sources; no item id, no internal turn metadata) once the filter has removed the reasoning they depend on. Other native tools keep their ids; tool call/result pairs, unsafe-reference rejection and passthrough for providers without the rule are unchanged. Split out of #168 as asked in its review. codex-history 0.1.0 -> 0.1.1. What was run at 61b6f0b (reviewer, bun 1.4.2, macOS): - bun test packages/codex-history: 29 pass, 0 fail. node --test packages/codex-history/web-search.test.mjs: 6 pass. bun scripts/check.mjs codex-history: exit 0. - Broken by hand: with the web_search_call branch disabled, 5 bun tests and 4 node tests go red. - magpie (built from yetone/magpie main 85eef5d87) in a sandbox HOME, middleware added from the PR's package, a custom Responses provider `demo` pointing at a local fake, options {"providers":{"magpie:demo":{"historyFilter":true}}}, gateway on 127.0.0.1:18763 (moejs). A Codex-shaped request with reasoning + web_search_call + function_call pair: the fake received the search as the labeled assistant text, no rs_/ws_ ids, no PRIVATE_TURN, the call pair intact, store false. With main's 0.1.0 file swapped in, the fake received the bare web_search_call. - Not tried: a real Codex session or real vendors. |
||
|
|
f6adc99a9c |
autoclaw 0.2.1: CN managed gateway, request shaping on both paths, OAuth guide opened by the host (#197)
Brings together #191 (CN managed gateway), #196 (request shaping and identity lines) and the #183 sign-in fix. - autoclaw-cn chat goes to AutoClaw 2.1.0's managed gateway (autoglm-acceleration-api.zhipuai.cn/autoclaw-proxy/proxy/autoclaw/chat/completions, on Zhipu's domain) with 2.1.0's headers and its four-model catalog. A 401/403 there marks the sign-in expired. - Both providers get the same request shaping: - the official one-sentence system prefix, merged into the caller's system message (string or array); - max_tokens and max_completion_tokens dropped; - other agents' identity lines in system/developer messages rewritten (FLAGGED/unflag, from #196); - no X-Harness-Type. - On the overseas path, a 406 explains itself and keeps the sign-in. Overseas chat now sends AutoClaw's own User-Agent instead of the host's. Its catalog drops zai_glm-5-turbo and the tdpsk models (400 upstream) and keeps the old limits. - Overseas OAuth: authorize returns the loopback guide URL once the listener is up, and the host opens it, so there is no shell spawn any more. Navigating to the authorization page no longer aborts the session. - autoclaw 0.2.0 -> 0.2.1. What was run at 1fe91be (reviewer): - bun test packages/autoclaw: 21 pass, 0 fail. bun scripts/check.mjs autoclaw: ok. git diff --check: clean. Merges cleanly onto main. - magpie plugin host (magpie main cb05dc2d1), sandbox HOME, with a copy whose three hosts point at a local fake: - overseas: authorize gave http://127.0.0.1:18432/, the guide returned 200, and /open-auth plus /auth/callback-google finished the sign-in; - CN: SMS sign-in worked; - streamed chat on both providers returned 200; - the fake received the prefix with "You are Claude Code" rewritten and no max_tokens on both paths; User-Agent AutoClaw/2.1.0 on CN and AutoClaw/1.18.1 overseas; no X-Harness-Type. - Not tried: real accounts or the live gateways (no credentials used). Co-authored-by: HuHong_Tao <3596843010@qq.com> |
||
|
|
571790bc22 |
factory: reword update-config's refused sentence in the guide agent's system prompt too (#198)
Factory refuses one sentence in Claude Code's built-in update-config skill description. The plugin reworded it only when the entry was a whole line in the skill-list reminders, and only without a slash. claude-code-guide's own system prompt renders the entry as `- /update-config: …` under "# User's Current Configuration", so its first request was 403. This change matches the entry by name, with or without the slash. It rewords only "not Claude" to "not the assistant" inside that entry. The rewording now also runs on system prompt blocks (promptText) and at the existing call sites (bareSkills, announcedSkills, announcedContext, generatedContext, userBlockText). factory 0.1.32 -> 0.1.33. What was run at af6422e (reviewer): - bun test packages/factory: 153 pass, 0 fail. bun scripts/check.mjs factory: ok. git diff --check: clean. - Broken by hand: with promptText's configSkillText call removed, 2 of the new tests fail. - magpie plugin host (magpie main cb05dc2d1), with a copy whose API/WorkOS hosts point at a local fake: - API-key sign-in worked. - /v1/messages with a claude-code-guide-shaped system prompt went out with block 0 as the Droid identity and the update-config entry reworded. A user's "/custom: Keep not Claude" entry was left unchanged, and the stream came back 200. - No new hosts, telemetry or dependencies. |
||
|
|
63a3d2aeb9 |
trae 0.2.16: a Trae CN account checks in on its own device in the client's 16-digit shape (#194)
XcodeFish's A/B on one account (#194): with the same Cloud-IDE-JWT, headers and body, Trae CN answered a claim 9074 on the plugin's 19-digit x-device-id and took it (code 0, +100) on a 16-digit one. The IDE's own id is server-issued: Trae's main process registers at log.snssdk.com/service/2/desktop/device_register (read in Trae.app's out/main.js, iCubeDeviceRegisterMainService). Real clients keep it as iCubeAuthInfo://icube-dc:<id>, and the ids seen in #808 and #1705 are 15 or 16 digits. - A new Trae CN sign-in names a 16-digit device_id. Trae Global keeps 19 digits, since nothing says its ids are shaped otherwise. - ugDevice: a check-in from an account the local client isn't signed in as goes on the account's own id when that is 15 or 16 digits. Otherwise (19 digits, signed in before 0.2.16) it goes on a 16-digit id hashed from that account's device id and uid. The id is the same on every check-in, never rotated and never another account's. A 9095 is still the day's answer. Chat pages and the renewal keep the device the account signed in with. - README: the Sign-in and Daily check-in sections say this. Run: - bun test packages/trae: 151 pass, 0 fail. Breaking it by hand: with the ugDevice line removed, 7 tests fail; with newDevice back to digits(19), 4 fail. - bun scripts/check.mjs: ok. - magpie's plugin host (origin/main 7660399a1, sandbox HOME), with the plugin's web/auth hosts pointed at a local fake: - signed in on 0.2.15 (device 9375744633732288271), claim on 19 digits; - added 0.2.16 over it: status/claim/claim all went on 2849759837088686, and the pay page kept 9375744633732288271; - a new 0.2.16 sign-in named 2348824360597085 (16 digits) and used it for check-in and chat. - Not tried against the real api.trae.cn; there are no real accounts here. The 16-digit claim being taken is the reporter's measurement. |
||
|
|
3e966bb4b5 |
kimi-work: test that the Work token goes only to the official chat endpoint
#190 dropped the old guard assertion with the error-body test it lived in. The guard (index.mjs:106-109) is unchanged; this puts its test back and widens it: another host, another path, a query, credentials in the URL and GET are all refused before any fetch. Run: bun test packages/kimi-work (18 pass); bun scripts/check.mjs kimi-work (ok). Removing url.search from the guard turns this test red. |
||
|
|
6017ebc383 |
kimi-work 0.1.4: pass 429/5xx through unchanged, 401 marks the sign-in expired (#190)
Kimi Work 0.1.4: a 401 marks the sign-in expired. A 429 or 5xx passes through unchanged (status, headers including Retry-After, and body), so magpie classes rate vs quota from Kimi's own words. A network error keeps its cause code or message. Reviewed head de33725f5a4cca882852ea69d0d828d5e1f4e605. Every changed line was read. What was run: - `bun test packages/kimi-work`: 17 pass, 0 fail. - `bun scripts/check.mjs kimi-work`: ok. - Run in magpie's plugin host (main 7660399a1, a throwaway internal/gateway test with a sandbox HOME). The plugin was a copy with its BASE, MEMBER and desktop-file path pointed at an httptest fake, and the sign-in went through `plugin.Authorize` then `plugin.Finish` on a synthetic config.json. - The stream returned 200. - A 429 "Too many requests" returned 429 with Retry-After 7 and type rate_limit_error. A 429 "exceeded your current quota" returned 429 with Kimi's words. A 502 returned 502. - A 401 surfaced the expired message. - Each upstream request carried only the Work token and the plugin's own User-Agent. - The endpoint guard (index.mjs:106-109) is unchanged. Its test was removed with the old error-body test, so a follow-up commit adds it back. |
||
|
|
5fa537146e |
kimi-desktop 0.1.1: ordinary Kimi takes the Library's instructions, MCP and skills (#189)
Ordinary Kimi (agent-kimi-desktop) becomes a Library target: agent.library names ~/.config/magpie-kimi/AGENTS.md, library-native/mcp.json (format kimi) and library-skills. bootstrap() links library-native to Kimi's daimon/runtime/kimi-code/home and library-skills to daimon/skills (junction on Windows, dir symlink elsewhere); a different object at either path stops with library_path_conflict. The adapter reads AGENTS.md on every inference request and inserts one separate system message after the leading system/developer ones; an unreadable or non-UTF-8 file answers 503 instructions_unavailable. Run at the reviewed head 5b9f445 (by the reviewer, sandbox HOME, no real credentials): - bun test packages/kimi-desktop: 14 pass, 0 fail (95 expects), bun 1.4.2. - bun scripts/check.mjs: every package ok (agent packages are skipped there). - Against magpie's own Library code (origin/main e085d6e92): a throwaway Go test in internal/library loaded this kimi-desktop.agent.js through agentplug, ran prepareLibrary on a fake Kimi tree, then SaveInstructions, SaveServer and InstallSkills to the kimi-desktop target. The MCP server landed in the native runtime mcp.json beside the existing entry, the skill in daimon/skills, library-native stayed a symlink; applyInstructions put the written block in as a second system message. RemoveServer, RemoveSkill and clearing the instructions left the existing MCP entry and skill, and applyInstructions then added nothing. - CI on the PR: test and on-npm green. Not tried: a real Kimi desktop (the author's COMPATIBILITY.md records it on Windows 11 and macOS). agent-kimi-desktop is not on npm yet; it is served from the dist branch until the owner's first publish. |
||
|
|
5d7fb87f84 |
qoder 0.2.17: native daily check-in through auth.checkin (#179)
Adds auth.checkin to Qoder and Qoder CN. It lists the account's campaigns and claims a CLAIMABLE CLAIM_BENEFIT campaign, and the list and the claim go through the plugin's own campaigns path: device token, one rotation on 401/403, VPC host and native machine identity. The outcomes match magpie's built-in qoder_checkin.go: - a CLAIMED campaign is done only while its startAt/endAt window is open; - a daily campaign that is neither claimable nor active-claimed is failed, so it is asked again later; - no daily campaign at all is inactive; - a list or claim reply that can't be read is failed, never inactive or claimed. The credit is the claim's own benefit.amount, else the campaign's. Bumps the package to 0.2.17. Reviewed head 128ed2a. Ran at that head: - bun test in packages/qoder, sandbox HOME/TMPDIR: 127 pass, 0 fail - git merge-tree onto origin/main: clean - PR CI: test and on-npm pass - read every line of the checkin hook against magpie's internal/provider/qoder_checkin.go. The campaign shape and its seconds-based startAt/endAt match the real campaign JSON in qoder_checkin_test.go. |
||
|
|
b3a860c115 |
think-tags 0.1.1: a </think> inside Markdown code no longer ends the stripped thinking (#176)
With "strip" on, a reply that opened with <think> was cut at the first
literal </think>, even one the thinking wrote out as an example in
inline code or a fenced block. Kane-Kuroneko's reply ("使用
`<think>...</think>` 标签") then began mid-sentence, as the gateway's own
Chat decoder did before yetone/magpie d4a1b9baa (#2634).
- findClose ports magpie's mdCode (internal/gateway/chat.go): </think> is
looked for only outside Markdown code. An inline span ends with its
line, so a stray backtick can't swallow the answer, and a fence is a
block. A run of backticks or a close split across chunks is held back.
- Streamed (strip) and whole (stripWhole) replies both use it, for Chat,
Anthropic and Responses.
- A Chat stream that ends inside the block no longer gives held-back
text to the answer: inside, that is thinking (a held "``" would have
leaked; before, so would a held "</th").
Run at
|
||
|
|
fc9cf6a7b0 |
minimax 0.1.2: claim the account's daily check-in (签到) (#140)
minimax 0.1.2 adds an `auth.checkin` hook for MiniMax Code's daily check-in (每日签到).
- It reads the panel at `/minimax-cloud/api/v1/signin/status` and claims the day at `/signin/claim`.
- Both requests are signed by the package's own `accountCall()`: the same headers, query and x-signature as the rest of the account API, and a `{}` body on the claim.
- On the China site they go to `agent.minimax.cn` (`site.llm`), the host magpie's built-in check-in uses.
- Failed reads come back as `failed`: a non-2xx reply, no panel, or a malformed panel (not 7 days numbered 1-7, or more than one today or claimable day).
- With no day marked today it returns `inactive`, and nothing is claimed.
- The streak counts back from today's index. 401 and 403 are `failed` with the HTTP status.
- The README says the check-in is opt-in. OpenCode ignores the hook.
Run at d21543b76cf0fa19b6e345e6b2d2f0d29976ee93, merged locally onto origin/main
|
||
|
|
646776060f |
kimi-desktop: Kimi desktop Work as an agent, through its local runtime (#169)
Adds agent-kimi-desktop 0.1.0 (kupakupar): Kimi desktop Work on magpie's
Agents page. It moves the runtime's daimon-kimi-code baseUrl to a
loopback bridge and back, through Kimi's local control API.
Re-reviewed at dd8ed2c against the last review at 6c584bb:
1. menu-hook.cjs and selection.mjs are removed; no injected code ships.
2. No full config backup is written. Only before-menu-models.json (the
model list and current choice) is kept, and it is removed on a clean
disconnect.
3. providers.json and settings.json are never opened. The catalog comes
from the gateway's /v1/models with the agent's key and its registered
UA "Desktop Kimi Work".
4. No signal handlers and no process.exit. Restore runs on the 'exit'
event, which fires when magpie closes the host's stdin (host.js
rl.on("close") -> process.exit(0)). The README gives manual recovery
after a SIGKILL.
5. macOS record: COMPATIBILITY.md (macOS 26.6.2 arm64, Kimi 3.2.17
build 3.2.17.4, magpie 0.1.1276, Bun 1.4.3). All four control methods
succeeded, a streamed request returned 200, and a restore followed.
The README says what happens when a private method fails.
6. Search and fetch pass Kimi's own request, with its own key, to Kimi's
own origin, unchanged. This is the user's own account used by that
user, the same rule as #171, so it is accepted.
Run at dd8ed2c, and merged onto origin/main
|
||
|
|
adcc7252d0 |
kimi-work: a Kimi desktop Work subscription through the desktop's own sign-in (#171)
Adds kimi-work 0.1.3 (kupakupar): a provider for the Kimi desktop's Work
subscription, using the desktop app's own local sign-in. It stores only
a hashed account reference, rereads the desktop's tokens on each call,
writes nothing to disk and logs nothing.
Re-reviewed at d9fe48d against the last review at fc3e395:
- (1) the desktop credential: decided acceptable (same as WorkBuddy,
Qoder, ZCode: each user's own allowance).
- (2) macOS record: COMPATIBILITY.md, macOS 26.6.2 arm64, Kimi 3.2.17
(3.2.17.4), magpie 0.1.1276 (released 2026-10-16 17:11Z, before the
20:09Z run), Bun 1.4.3. The path and four field names match readDesktop.
- expireTime: resetsAt dropped, window renamed 会员共享额度.
- efforts: every advertised level is kept (redacted real catalog fixture).
- kimi-work-opencode overlap: the README credits it and says not to
enable both.
- Request input: handled; body, headers and signal are kept, and the
desktop credential replaces any caller Authorization or Cookie.
- Icon is shipped once (package.json); the UA reads the package version.
Run at d9fe48d, and merged onto origin/main
|
||
|
|
2ea25b925b |
cursor: the latency test's far events show once their step has answered, and a step's wait is counted in asks, not ms (#159, #162, #165)
#159 and #162: the "far from Cursor" fake showed a Run's usage event SHOWS (225 ms scaled) after the Run's stream closed. The step's wait takes its last look about 180 ms after that close, so only ~45 ms stood between "the event is not there yet" (what the test means) and "the event is already there" (the step owns it and the sum moves). A loaded machine eats 45 ms. #162's title guessed an earlier test's cached usage; it was the step's own event showing inside its wait. The fake now holds a far Run's event until the step whose Run it is has answered, and shows it at once if that step already has: the state the test is about, not a duration. #165: test 1 bounded each step's wait in milliseconds, which load stretches. Each wait asks once and the round trip is most of it, so the bound is now at most 2 asks per step (its own event, plus what earlier steps owe). Run (bun 1.4.2, load average 280-295 throughout): - Old test, cause injected by showing the event earlier (SHOWS - 50 ms): #159's failure; SHOWS - 80 ms: #162's. New test with the same injections: green. - packages/cursor/latency.test.mjs: 9 of 9 green. - packages/cursor whole package (HOME=$(mktemp -d) bun test): 3 of 3, 272 pass, 0 fail. - Broken by hand in index.mjs, each turned the new test red: the step waiting for its own event removed; owed() not gathering at the end; the ask bound raised (a step asking 3+ times). Not run: the whole-repo suite (test-only change in one file). |
||
|
|
be7b03e090 |
autoclaw: the refresh test reads the expiry between the clock before and after, not the clock again
"refreshTokens orders hosts by the token's source_id and falls back on
400002" compared the expiry refreshTokens computed (Date.now() + 3600s -
10min) with Date.now() read again after it returned. On a millisecond
boundary between the two reads it is off by one: publish run 38885546686
(devin 0.1.20's push,
|
||
|
|
3d0a546aa3 |
usage 0.1.1: the tab is named in the window's language, and the tiles fill four across or two by two
magpie.page.titles names the page in zh, zh-TW, ja and de; a magpie that doesn't know titles still reads title. The tiles were auto-fill, which left a hole in their row at most widths; now four across, two by two under 640px. Run: bun test in packages/usage (6 pass). Tried in the magpie sandbox app's dev UI with the real usage.jsonl, WebKit, dark and light, zh and en, at 900 and 560px. |
||
|
|
29adee2688 |
devin 0.1.20: a tool's images go to Devin with its result, as the built-in sends them
magpie's built-in Devin (internal/gateway/devin.go buildDevin) sends the images a tool returned on the tool message that answers the call (inlineImages(p.Images), field 10). A chat's tool message holds text alone, so magpie's gateway hands the plugin those images in the user message after the results (buildChat's seeLater: "[From the result of <tool> (tool call <id>):]" then the images, and the result's text ends "[The tool returned an image; it follows in the next message.]"). The plugin sent them to Devin as a user message of their own, and a tool message's own image_url parts were dropped. build() now puts each result's images back on its tool message: the images under a heading naming a result just sent, up to the number its note says (so the user's own images after them stay the user's), and a tool message's own data: image_url parts. The note is taken off the result's text when every image it names went back with it; an empty result is "(no output)", as the built-in words it. Images without bytes (URLs) are left out, as inlineImages leaves them. A heading that names no result just sent is left as the user's text. Run: - bun test in packages/devin under a mktemp HOME: 93 pass, 0 fail. - bun scripts/check.mjs devin: ok. - tool-images.test.mjs against the old index.mjs: 3 of its 4 tests red (the fourth guards a heading naming no result, which held before too). With the count limit broken by hand (images past the note's number taken as the tool's), the two-results test goes red. - The fixtures in testdata/ are magpie's literal buildChat output at origin/main b03031738, captured with a throwaway test in a separate magpie worktree (codexViewImage, and an Anthropic request with two Read results and the user's own image). Not tried: a real Devin account (whether Devin's model reads a tool message's images better than a user message's was not measured); OpenCode itself, outside magpie, whose own shape for a tool's images was not read. |
||
|
|
8fc3833aa7 |
commandcode 0.1.13: the Credits window renews at the plan's period end, the CLI's free models are free, and a Go request's max_tokens stays within 200,000
Three things magpie's built-in Command Code did that the plugin didn't, ahead of retiring the built-in: - The Credits window had no reset, though the month's credits come back when the plan's period ends, which billing/subscriptions' currentPeriodEnd says (sub.until, already the card's "until"). allowanceOf now puts it on the window as resetsAt (yetone/magpie#2454). No period end, no reset. - The models the CLI marks FREE (magpie's cmdFree, all 11: Space Bunny Alpha, Pixel Canary, Laguna S 2.1, the Ling 3.0/3.1 Flash ones, the MiniMax M3/M2.7 free ids, LongCat 2.0 free, Tencent Hy3) now say free: true on every list: the Provider API's, Go's, and Go's table when the list can't be had. - A Go chat's max_tokens sent to /alpha/generate is kept within 200,000, the most Command Code takes ("Too big: expected number to be <=200000 at params.max_tokens"; magpie's CommandCodeMaxOutput in cmdRequest). Before, a 384,000 ask failed the whole request. Run: bun test in packages/commandcode: 49 pass, 0 fail. parity.test.mjs is new; usage.test.mjs's two plan-with-period cases now expect the reset. Broke each by hand and watched red: no resetsAt, 3 fail; no free flag, 3 fail; no cap, 1 fail. bun scripts/check.mjs commandcode: ok. Live, with the owner's GOAT key: the card's Credits window says resetsAt 2026-10-28T16:16:42Z, the subscription's until; its list (71 models) has poolside/laguna-s-2.1-free free, the only one of the 11 Command Code lists today. Not tried live: a Go request over 200,000 (no Go key here). |
||
|
|
0c35adbf03 |
cursor 0.2.18: a failed tool result tells Cursor isError, and a refused keychain read is not asked again for ten minutes
Two things magpie's built-in Cursor did that the plugin didn't, ahead of
the built-in's retirement:
- The stateless path (conversation) sent every tool result with
isError false. A chat tool message with is_error: true (what magpie now
sends for a failed tool, as the built-in's cursorResult told Cursor
isError) is marked isError, as the native path already did.
- cliToken ran `security` on every call. It now reads the Keychain as the
built-in's cursorKeychainToken (internal/provider/cursor.go; magpie
#746, #2408): a read is kept 10s; a read that failed with anything but
exit 44 (no such item) may have been a dialog the user said no to, and
is not asked again for 10 minutes; reads go one at a time, so callers
at once share one run. A sign-in and the read after `cursor-agent
status` read afresh, as forgetCursorStatus / cursorTokenOf(true) did.
README's "read on every request" says so now.
What was run (bun 1.4.2, macOS, load average ~280-300):
- parity.test.mjs (new, 5 tests): green. Broken by hand, each watched
red, then restored: is_error ignored (1 red), cache check removed
(3 red), denied backoff at 10s (1 red), exit 44 treated as refusal
(1 red), no read serialisation (1 red).
- `security find-generic-password` for a missing item gives execFile
err.code 44 (number) on this Mac, as the mapping assumes.
- Full `bun test` in packages/cursor, 7 runs: 272/272 green in 4; the
other 3 red only in latency.test.mjs ("events never show in time",
#159; "nothing naming the session", #162), which the change doesn't
touch. On clean origin/main
|
||
|
|
47a8bb40d2 |
zed 0.1.8: a free account's card says "No plan", as the built-in's did, and the README says what the plugin and magpie now do
What changed:
- usage: magpie's built-in zedLoginQuota showed a free account's card
(plan_v3 zed_free, or none) as "No plan", unless an overdue invoice was
its error, while the account row kept zed.PlanName's "Free". magpie's
card knows "No plan" (app.js noPlan) and translates it. The plugin's card
said "Free". It now says "No plan" in the same case; the sign-in still
saves planName "Free", and an overdue free card keeps "Free" with its
error, as the built-in's switch did.
- README: "Not included" listed the plan display, which the usage hook has
shown since 0.1.x, and several accounts and the web-search stand-in,
which magpie gives a plugin provider itself (plugin_accounts.go, the
gateway's generic searchReply path). It is now a "Usage" section and an
"In magpie, not the plugin" section.
What was run:
- usage.test.mjs: the free-account test (zed_free, "" and an overdue free
account) fails on 0.1.7's index.mjs ("Free" for "No plan"), passes now.
- packages/zed under a scratch HOME: 31 pass, 0 fail (4 files).
- bun scripts/check.mjs zed passes.
Not tried: a real free Zed account.
|
||
|
|
09f946b5e6 |
zcode 0.1.19: a GLM Coding Plan's own resets show on the card, each with its end, a team's say so, and a Start Plan refusal says what to do, as the built-in did
What changed, for parity with magpie's built-in ZCode before it retires:
- Personal resets. The built-in's zcodeQuota read
/api/biz/customer-package-reset/list?targetType=PERSONAL with the plan's
key (zhipuPersonalResets, yetone/magpie#1191) and showed the count, by
window, and each reset's end. The plugin read only the team's list.
codingUsage now reads the personal list alongside the subscription list,
so a Coding Plan card (and a dual gift + Coding Plan card, built on it)
carries resets: {count, byWindow, fiveHour, weekly, until, each}.
- Team resets now carry team: true and each, as zhipuTeamResets set Team.
Both lists are read by one resetsOf: only available ones count, each
{until?, window} sorted soonest first with an endless one last
(sortResetCards), nothing on a failed read or none left.
- Start Plan refusal. A Start Plan answer that is a 405, the block page
("request has been blocked" / errors.aliyun.com) or code 3012 / "unusual
activity" now comes back, same status, as {type:"error", error:{message:
"<vendor's words, or the status for a block page> — <hint>"}}, the hint
word for word magpie's provider.ZCodeStartBlockedHint, as the built-in's
zcodeStartExplain / Provider.Explain put it. The block page's own words
are left out, so magpie's APIError no longer reads it as a network
firewall's (BlockedHint). Coding Plan and team answers are untouched.
- README: the resets and the Start Plan's hint.
What was run:
- usage.test.mjs: a new test with #1191's literal reset list (the
built-in's zhipuResetList) fails on 0.1.18 (no resets); the team test,
now expecting team and each, fails on 0.1.18 too.
- start.test.mjs: the new refusal test fails with the startBlocked line
disabled by hand (block page passed through), passes with it.
- Every packages/zcode test file under a scratch HOME: dual 25, gift 20,
models 1, moved 1, own 6, signin 3, start 11, usage 16 (83 pass).
- bun scripts/check.mjs zcode passes.
Not tried: a real account's reset list or a real Start Plan refusal.
`team` and `each` reach magpie's card from its next release; older magpie
ignores them.
|
||
|
|
4a35799021 |
factory 0.1.32: a model's token multiplier reaches magpie as its rate (#158)
Every model in MODELS carries the tokenMultiplier droid 0.241.1's registry has for it (testdata/droid-0.241.1-costs.txt, byte for byte). A promotion running takes its discount off it, with the multiplier before it as rateWas; one that has ended or not begun is no discount. The rate reaches magpie through a provider hook (host.js reads rate/rateWas from its models; a config hook's models carry no rate there). Fast Mode entries stay last. Reviewed at 498b8723e5350657aa26f8f0e2bb1d859f59803b: - each multiplier and promotion checked against the testdata excerpt; gpt-5.6-sol's expired M promotion is skipped and Pt (20%) applies, as droid's first-running-promotion rule gives - host.js info(): the provider hook's list replaces the config list, and the request path strips temperature for OpenAI models in droidBody, so capabilities.temperature=true in providerModel changes nothing sent - factory unchanged on main between the PR's base |
||
|
|
aec06bdf96 |
devin 0.1.19: a chat's response_format is told in the instructions, as the built-in told it
Devin's GetChatMessage has no field for the answer's format, so magpie's built-in Devin (internal/gateway/devin.go, req.inSystem()) told the model in the instructions: the json_schema's schema, or any JSON object for json_object. The plugin dropped response_format, and magpie's generic plugin path falls back to inSystem only when an upstream answers 400 naming the format, so a moved user asking for JSON got prose. build() now adds the built-in's words (format.go's instruction) after the system messages, ahead of the tool descriptions, at the head of the first user message. A json_schema with no schema asks for any JSON object, as the built-in's openAIFormat reads it. Checked against the built-in, no change needed: - Lightning variants (swe-2-high-lightning, swe-1-7-lightning-medium): the built-in's tiers are fast and priority only (devinTiers), so a -lightning id is no effort and no tier and is listed as its own model, as the plugin lists it. - A failed tool's result: magpie sends its content as "Error: …", and build() passes a tool message's text to Devin as it came; a test now holds that. Run: HOME=$(mktemp -d) bun test in packages/devin: 89 pass, 0 fail. structured-output.test.mjs: 3 of its 5 tests red with the index.mjs change taken out (the other two: no format unchanged, and the "Error: " pass-through). bun scripts/check.mjs devin: ok. Not run: a real Devin account, nor magpie end to end. |
||
|
|
060bda8f65 |
kiro 0.1.12: a request's structured output (output_config.format) is told in the system prompt, as the built-in told it
Kiro's generateAssistantResponse has no field for the answer's format, so magpie's built-in Kiro (internal/gateway/kiro.go, req.inSystem()) told the model the schema at the end of the system prompt: "Respond with a single JSON value and nothing else, matching this JSON schema:\n<schema>." The plugin dropped output_config.format, and magpie's generic plugin path falls back to inSystem only when an upstream answers 400 naming the format, which the plugin never did, so a moved user asking for JSON got prose. buildKiro now says the schema the same way, after the caller's system prompt and before the thinking budget prefix. The AI SDK's output_format is read too. A JSON object with no schema needs nothing here: magpie's Anthropic body already tells it in the system prompt. Run: HOME=$(mktemp -d) bun test in packages/kiro: 46 pass, 0 fail. structured-output.test.mjs: 3 of its 4 tests red with the index.mjs change taken out (the fourth checks a request with no format is unchanged). bun scripts/check.mjs kiro: ok. Not run: a real Kiro account, nor magpie end to end. |
||
|
|
fe5631c1cb |
zen-free 0.1.10: the sign-in says a personal OpenCode key belongs in the built-in OpenCode Zen (TradingLife on Discord)
A user typed keys made under several OpenCode accounts into Zen Free's key field and expected several accounts. The method's authorize() always returns key "public", and magpie's host stores result.key over the typed key (host.js save), so every such sign-in is the same shared credential and the typed key is dropped. The label and README now say so and point own keys to magpie's built-in OpenCode Zen provider (several keys, rotation and failover). Run: bun test in packages/zen-free, 174 pass 0 fail. Read host.js apiKey/save on magpie 63be47717 to confirm the stored key is "public". Not tried: a sign-in through magpie's GUI with the new label. |
||
|
|
9fd59cf6e8 |
trae 0.2.15: a model Trae's list marks multimodal takes images, and they reach it (#161)
Reported on magpie's Discord (#help): through magpie, Trae CN's doubao
model said it couldn't read images, while in Trae it reads them.
Every model was listed as text-only (MODEL's modalities), and partText
put "[an image, which this model can't see]" in every image's place, so
no image ever reached Trae.
What changed:
- Trae's lists mark each entry `multimodal` true or false
(config_info_list). A listed model's flag now decides
capabilities.input.image, attachment and modalities, over a fallback
entry's word. Doubao-Seed, Kimi K3/K2.6, Qwen 3.7 Plus and MiniMax M3
are true; GLM-5.x and DeepSeek V4 are false.
- An image sent to a model that takes images goes to llm_utils_chat as
an OpenAI image_url part ({url}) after the text part. That is the
shape TRAE's ai-agent carries (LLMRawMultiContent/LLMRawChatImageURL,
in the ai-agent binary's strings) and what autumnsentiment/Trae2api-cn
passes llm_utils_chat unchanged.
- A model marked false still gets the placeholder.
- The fallback list marks kimi-k2.6 and qwen-3.7-plus as taking images,
as Trae's SOLO list does.
The list fixture is two entries of a relay's capture of the SOLO list
(wangqi233/trae2api scripts/_solo-models-clean.json).
Run:
- images.test.mjs: 6 pass on this change; 5 of 6 fail on 0.2.14's
index.mjs (only the text-only case passes there).
- packages/trae: 146 tests, 0 fail.
- HOME=$(mktemp -d) bun test across the repo: 1616 pass, 0 fail.
- bun scripts/check.mjs: ok.
Not tried: a real Trae account. Magpie's owner has none signed in, so no
real image request was sent to Trae.
|
||
|
|
3dbaa0b16f |
cursor 0.2.17: a tool-result continuation in a Run's last minute rebuilds before writing results, not 502 at the lifetime (#157, nicegui)
Run at this commit: packages/cursor `bun test` (isolated HOME) 267 pass, 0 fail; `bun scripts/check.mjs` ok. Version bump only. |
||
|
|
0b821908bc |
cursor: a tool-result continuation in a Run's last minute rebuilds before writing results, not 502 at the lifetime (#157, nicegui)
The 15-minute absolute lifetime spans all of a retained Run's tool
roundtrips. A tool-result continuation that arrives with no more than
min(60s, lifetime/10) left now retires the owner (410 "retired before
lifetime deadline") and rebuilds from the supplied history before writing
any result, instead of resuming and failing mid-segment with "native Run
lifetime expired". Replays of an already submitted batch keep their path.
Merging main resolved a conflict with
|
||
|
|
a7614aa2ff |
cursor: the lifetime-expiry test brings a Run's lifetime in after its first answer, not before it starts (#143)
The native retention test set NATIVE_LIMITS.lifetime = 65 before the
first ask. The lifetime counts from the Run's start, so on a loaded
machine the first Run expired before it answered: 410 where the test
wants 200. NativeSession now sets its deadline through expireIn(ms), the
constructor giving it the whole lifetime as before, and the lifetime case
calls owner.expireIn(65) after the first answer. The resultWait case
still sets its limit up front, since that wait counts from the answer.
The plugin's behaviour is unchanged, so there is no version bump.
Run:
- Injected: on the old test, a lifetime of 0–10 ms is red ("Expected: 200
Received: 410"); 15 ms and up is green. The new test is green.
- HOME=$(mktemp -d) bun test, whole repo: 10 runs in a row, 0 fail
each. On current main
|
||
|
|
7687314d07 |
codex-history: opt-in Codex Responses history filter middleware (#152)
An opt-in gateway middleware for Codex Responses history after a provider or account switch. For a provider whose rule turns historyFilter on, it drops old reasoning items and items typed encrypted_content, removes the optional server id from message and tool items, and sets store false. It keeps text, tool arguments, results and call_id pairing. It rejects previous_response_id, conversation, item_reference, encrypted compaction and /responses/compact with a message, instead of dropping them silently. Every provider passes through unless configured. No network, file, env or child-process access. Run at the reviewed head 96881ead, merged with origin/main: - bun test packages/codex-history: 22 pass, 0 fail. - The same 22 cases.json cases through magpie's own engine (moejs, via internal/middleware Begin/Request in a throwaway test): 22 ran, all equal. - Broke it by hand (reasoning items kept): bun 4 fail, moejs 4 BAD; restored. - Whole repo: bun test 1606 pass, 0 fail; bun scripts/check.mjs exit 0. |
||
|
|
2dd4328d5a |
cursor 0.2.16: a multi-step turn's last step reports its own share of usage, and a step's calls get batchWait from the latest one (#156, #155)
Run at this commit: packages/cursor `bun test` (isolated HOME) 266 pass, 0 fail; `bun scripts/check.mjs` ok. Version bump only. |
||
|
|
c7c6498d85 |
cursor: a multi-step turn's last step reports its own share of usage, and a step's calls get batchWait from the latest one (#156 erzay, #155 midmirror)
#156: a native Run of N tool steps ended with TurnEndedUpdate's totals as the final step's prompt_tokens (1,105,934 on erzay's ~21-step turn, where the real context was ~61K), and Codex compacted at once. The final step now keeps its last model call's share, max(that call's chars/4 prompt estimate, turn total / model calls), split proportionally across input, cache read and cache write; the rest goes into usage.magpie_deferred (merged with any settled stateless debt), so magpie still bills the whole turn. On erzay's numbers that is ~52.7K reported, ~1.05M deferred. #155: waitForBatch armed once, at a step's first call, so a step whose calls arrive one by one as the model writes them (13 calls, 9 long-arg) failed 502 "did not complete its declared native tool batch" ~30s after the first call even though it never paused that long. The deadline now restarts on every call, answered call, count and text/reasoning frame. Run at this commit: packages/cursor `bun test` (isolated HOME) 266 pass, 0 fail, three times; `bun scripts/check.mjs` ok. The three new tests fail on 4e64f26's source (prompt 1105934; sealed step failed at 300ms; stall failed 303ms after the first call instead of after the latest). |
||
|
|
423e78e49c |
autoclaw 0.1.0: AutoClaw (Zhipu OpenClaw) provider plugin (#53, hubo1989)
Adds packages/autoclaw, @magpie-community/opencode-autoclaw-auth, for AutoClaw (Zhipu OpenClaw). - Providers autoclaw (oversea, web sign-in through Google or z.ai) and autoclaw-cn (CN, phone SMS). - Reads the credit balance and runs the daily check-in through auth.checkin. Since the 10-08 review, this fixes: - The OAuth callback takes a code only with the state the authorize page handed out (login CSRF). The legacy /callback is gone. - The local server closes after 10 minutes even if magpie never calls callback, so port 18432 isn't held. - The registry entry no longer uses ZCode's icon. - The User-Agent names the real arch. - The check-in row's used is 0. - A 401 or 403 the upstream answers without an envelope marks the sign-in expired. - New tests with a fake fetch cover loader().fetch, refreshTokens and the callback's state check. What was run, at 356fb53 (8a0fd3a plus a merge of origin/main 118cf2e; the merge resolved registry.json, raccoon's entry beside autoclaw's): - HOME=$(mktemp -d) bun test packages/autoclaw: 9 pass, 0 fail. - Whole repo, HOME=$(mktemp -d) bun test: 1584 pass, 0 fail. - bun scripts/check.mjs: all ✓. - Broken by hand, each turning a test red: - Dropping the callback's state comparison: 1 fail. - Dropping the expired mark on a non-envelope 401: 1 fail. - The package isn't on npm yet. magpie serves it from the dist branch until an owner publishes its first version. Not verified: a real AutoClaw account, and the 10-minute server close (read, not tested). |
||
|
|
118cf2edcc |
raccoon 0.1.0: SenseTime Raccoon (商汤小浣熊) provider plugin (#88, yijiemaooo-ux)
Adds packages/raccoon, @magpie-community/opencode-raccoon-auth, for SenseTime Raccoon (商汤小浣熊, xiaohuanxiong.com).
- Sign-in: through the browser, or reusing Raccoon desktop's live sign-in.
- Lists the models and makes chat requests.
- Reads account credits (balance and bills).
- Runs the daily check-in through auth.checkin, plus the desktop's first-login grant. The grant is marked settled only when the vendor gives a definite answer.
What was run, at the reviewed head 6078f92 merged onto origin/main
|
||
|
|
4e64f2680c |
factory 0.1.31: an OpenAI model's request goes without temperature and top_p, not 400 (sweanng424, Nowledge Mem on gpt-6.1-sol, magpie's Discord)
OpenAI's reasoning models turn temperature and top_p away with a 400, and droid sends neither. droidBody now takes both out of a Responses request for a model whose upstream is openai, also when the body already opens with droid's line. configModels says temperature: false for those models, so OpenCode doesn't send it either. Grok and the chat-completions models keep theirs. Run: bun test in packages/factory, 144 pass. The new test fails on 0.1.30's index.mjs (temperature still in the body). Not tried against Factory's API with a real account. |