e4e9eb0928becfa4e48484dde85ef5032671d582
682
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
c01988e439 |
routing: a group's Small context first sends a request to the smallest window that holds it
yg6888 on X (tweet 2123308968848379920): in a group routed Smart, Cursor Plus's Composer and Grok 4.7 were never used. Not a bug: Smart orders by allowance tier, then soonest renewal, then listed order, and never weighs the context window, so the 1M members listed ahead always answered. The small ones were only ever reached as a fallback. Smart itself is unchanged; changing its order would move every Smart user's traffic. A group gets a new routing instead, `fit` (Small context first; 小上下文优先, 小上下文優先, 小さいコンテキスト優先, Kleiner Kontext zuerst): - routes.SmallFirst takes Smart's order and sorts it stably by band (a provider set to be used first, the rest with room, the all but used up) and then by window, the smaller known first, an unknown one last. - Its strategy sets ByWindow, so weighRouted fills Seat.Window from windowIn (the provider's own Contexts, else the catalog's). - roomy already leaves out every member the request is estimated past, so the first left is the smallest that holds it: a small model is never asked for a request too long for it, and keeps its last-resort place as under every routing. - The trace's rows carry `context`; the Routing page says "its 200K context window is the smallest that holds this request". - A group's only: provider.normalize already drops it from a provider and the CLI refuses it there. GUI menu, hint, why-lines, TUI and CLI (`routing=fit`, small-first) carry it; docs/reference.md, the gateway-routing and plugin-runtime pages and the en/zh/ja start pages say it, with the search index rebuilt (via docs-index.mjs; #7065). Run first at the tree rebased on origin/main |
||
|
|
6a46bad344 |
gui: Settings' search finds settings on every page, ⌘K opens it (canlee886 on X)
canlee886 asked for a search that reaches a setting by keyword even when it lives outside Settings, such as routing group strategy and members. Settings' search now lists, under its own results, hits from the other pages, each under that page's name: Routing groups (a group by name, its strategy, its members), Providers (the editor's fields, e.g. Proxy, per provider), Agents, Library and Usage. Open goes to that page and row (a group's editor at the field, a provider's editor with the field lit) without scrolling anything the user didn't ask for. ⌘K / Ctrl+K, or the header's new magnifier, opens the search from any page. - The finder is a lazy module, finder.js (like provlinks.js), loaded on the first search. app.js only calls it, so TestCoreScriptBudget's budget is unchanged: core 1272271 (310 under), app 1087580 (668 under), at fe038cfac rebased on |
||
|
|
2926b7beff |
usage, routing: the model id a request went out under is kept and shown
daoche_wuzui on X asked how magpie serves Antigravity and whether a
request goes out under a suffixed model: nothing showed the id actually
sent. Antigravity's plugin turns gemini-3.7-flash at high effort into
gemini-3.7-flash-high, and a relay's upstream name (ModelWires) renames
a model too; the ledger and Routing showed only the routed model.
- A plugin's reply may carry X-Magpie-Sent-Model
(provider.SentModelHeader). forward() reads it from plugin providers
only (a non-plugin's header is ignored) and deletes it, so it never
reaches the agent. Without it, provider.SentNameOnIn (the upstream
name, or Antigravity's variant) is used.
- wireName keeps the id only when it differs from the model. It goes in
usage.Record.Wire (`wire`, omitempty), the trace's Try.Wire, the
ledger cache and a last CSV column, sent_model (docs/reference.md).
- Usage › Requests: the Sent cell and the detail show the sent id when
there is one, with "model → sent id" on hover. Routing: a try sent
under another id gets one aside line, "Sent to the vendor as {model}"
(zh, zh-TW, ja, de).
- Antigravity's mover min is 0.2.4: plugins 67fb1258 sets the header on
every reply (stream, whole and errors); its tgz is on the plugins
repo's dist branch.
Run at this head (
|
||
|
|
c1934262ab |
routing: a group member sent Ultrafast says Ultrafast, not fast
OoopsHh on X: with Ultrafast picked on a routing group's member, the group list's card still said "· fast". The Routing page's summaries (the card's member line, the member menus' notes and the route view's tag) read Group.Fast alone. They now say Ultrafast where the group sends the member so and an account offers it (memberJSON.Ultra), as the editor's speed button and `magpie group` already did. The TUI's group view did the same and now says Ultrafast too. The route trace's Weighed gains Ultra so the route view's tag can tell the two apart (#7095). Fixes #6881 and #7095 (paul-tian). ggbdpq took #6881 and posted a patch on it; its TUI test and the Codex GPT-6-Astra fixture are ported here with credit. Siblings checked: `magpie group` (groups_cli.go) and the Agents page (agentspeed.js) and search tags (fastTag) already said Ultrafast; the tray has no group speed summary. Tests: - group-member-fast.test.cjs: a group "Astra" with an Ultrafast member; its card says "gpt-6.2-sol · Ultrafast" / "· 极速" (en, zh; Chromium, WebKit). Red on |
||
|
|
1c9c359f9d |
gui: Usage cards keep their place as they come in (liuzhengdong99 on X)
liuzhengdong99 on X: 用量界面每张卡片取数的时间不一致,导致卡片渲染时高度一直 跳动——滑到上面看某张卡片,视图会被拽回下面. The allowance cards come in at different times: each vendor's read (the page asks again every 1.5s while X-Magpie-Reading says a read is under way), then the curves' history. Every answer redraws the cards (renderQuotas), and packUsage grows the ones above the card being read. Nothing kept that card in place: the view's scroll guard (keepInView) only knew elements by node, and the cards are new nodes on each draw, so the browser's anchoring was the only thing holding them. It anchored on nodes that were being replaced, and the reader ended up dragged down. Fix: - The Overview keeps the card being read in place: the highest card (or part of the page under the cards) that starts in sight, found again by its data-key after a redraw (keepInView's new `only` mode with pinnedAt), and followed after every packUsage (followPin). The browser's own anchoring stays on while nothing is kept: at the page's top, on another tab, and while the cards are dragged or moved by keys (unpin, so a dropped card lands where its slot showed). - Placeholders from the last known height: each card's height drawn in full is kept by its key (localStorage magpie.usageCardTall, 1s debounce, 200 keys at most). A card still waiting on its read or its curve (usageWaiting: quotasReading, the new flag loadQuotas sets, or no history answer yet) is packed and held at least that tall, in the column count the cards were last whole in at that width. On the next start, no card in sight moves. - loadQuotaHist counts its first answer even when it is empty, so a user with no history isn't left waiting (found by usage-pack: the cards held their first packing at 560px). No new animation, nothing scrolls the page on its own (click-scroll passes), and the layout is unchanged once the cards are in. Run (mica, Playwright 1.62.0, Chromium + WebKit): - usage-cards-steady.test.cjs (new): 20 tests, all 5 languages, 1100px and 420px. On the old assets (MAGPIE_ASSETS) it was red 8 of 8 in en and ja. With the hold disabled, the second visit goes red. - At |
||
|
|
1c29e2c7dd |
gui: dark quiet text at 4.5:1, the masking count in the app's own numbers (CHENGJIAHEGOXIS on X)
CHENGJIAHEGOXIS on X: the masking card's big number was a thin, tall
face ("瘦长的比较别扭"), and some text in dark mode was very dark: Library
› MCP's project help under 项目服务器.
The masking count (.msk-num, redact.css) drops its own SF Pro Display at
weight 100 for the interface's font at 600 and -.035em, as .si-pct b and
.kpi b have; its 52px and line-height stay, so the card's layout doesn't
move.
The help is .lib-aside, drawn in --faint. The dark theme's --faint was
#56565f: 2.39:1 on --bg, 2.16:1 on --card. It and --muted are raised in
both dark blocks and the dark panel's:
--faint #56565f -> #90909a (panel #7c7c87 -> #90909a)
on --bg 2.39 -> 5.49, --card 2.16 -> 4.95, --card-2 2.26 -> 5.19,
menu (--pop-bg) 2.07 -> 4.76, panel bg 2.34 -> 5.38, panel card
2.08 -> 4.77
--muted #8b8b94 -> #9c9ca6 (the panel's own value already)
on --bg 5.14 -> 6.38, --card 4.64 -> 5.76, menu 4.46 -> 5.54,
--pill 4.05 -> 5.03
fg-2 > muted > faint is kept. With a picture behind the page (84% veil,
appearance.go), --faint holds 4.5:1 up to a mid-grey #808080 picture
(4.52); a picture brighter than that under the words can't keep 4.5:1
for any grey quieter than --fg-2 without a heavier veil, which is left
as it is. .effort-ends loses its .8 opacity over --muted. The light
theme's --faint (1.95:1 on white) needs both light steps moved
together: #7153.
New test dim-text-contrast.test.cjs, Chromium and WebKit: the dark
--faint and --muted at 4.5:1 on every dark ground in the window and the
panel, with the steps kept; Library › MCP's two .lib-aside lines at
4.5:1 on the dark page, with no picture, #262626 and #808080 behind it,
in zh/en/zh-TW/ja/de at 1100 and 420 (web), no sideways scroll; the
masking count's weight and family the same as .si-pct b's and .kpi b's,
its tracking no tighter, fitting its card in dark and light, every
language, 1100 and 420.
Run (mote, through mote-run):
- old code: dim-text-contrast red 6 of 6 (--faint rgb(86,86,95) on
--bg reads at 2.39:1; weight 100, the app's big numbers 600).
- this commit's tree (on
|
||
|
|
426a707a19 |
library: each subagent is kept in a Markdown file to edit, or one of the user's own in a git repo (JonahFu on X)
JonahFu asked on X (tweet 2123236872940073039) for each subagent's local path in Library > Subagents, to edit it with an LLM, or to keep a subagent in a git repository. Each subagent of the library (not a plugin's) is now kept on this computer in <library>/subagents/<name>.md as well, in Claude Code's shape (name, description, model, skills, mcpServers, the prompt), or in a file of the user's own set under the editor's Advanced (folded unless one is set), in a repository say: - FileHash is what the file said when magpie last wrote or took it in. An edit there (by hand, by an agent, a git pull) is taken in at the next sync and before a change made on the page, and every ticked agent gets it. While magpie runs, KeepLinked's loop syncs when a file's hash differs, once per edit. - An edit that can't be read as a subagent (no front matter, another name, no prompt) is left as it is, the agents keep what it said before, and the editor says why. magpie writes a file only when it is missing, or still as magpie left it; never the user's edit. - A file of the user's own that is there already is what the subagent says (a bad one refuses the save). It must be an absolute .md path, not a folder, not inside the library, not one another subagent uses, and not a file magpie writes for an agent. - Rename and remove take the library's own file only while it is as magpie wrote it; the user's own file always stays. - File and FileHash are this computer's: Collect leaves them out, Put keeps this computer's. The editor shows the path (click reveals it, Copy copies it), a line that edits there reach the agents, and the error when one wasn't taken in. i18n in zh, zh-TW, ja and de. docs/subsystems/library.md: a row for the subagent's own file and its tests. Run at the tree before |
||
|
|
3132fa1cd9 |
library: Rules, a folder of rules given to Claude Code, Cline and Kiro CLI (JonahFu on X)
JonahFu asked on X (tweet 2123237371739316685) for Claude's rules folder in the Library. A new Rules tab keeps rules once and gives each to the agents ticked for it, in the folder each reads by itself: - Claude Code: <claude dir>/rules/<name>.md. `paths` is the only front matter key it reads (code.claude.com/docs/en/memory). Checked on real 2.1.327 in a sandbox: it reads every .md under the folder, loads one without paths at launch, and one with paths when Read/Write/Edit touches a matching file. - Cline: <cline dir>/rules (CLINE_DIR, else ~/.cline). Cline 3.0.70 reads every rule always and has no paths key, so a rule with paths isn't written for it; the agent gets a problem and the editor says why under the paths. - Kiro CLI: ~/.kiro/steering, `inclusion: fileMatch` + `fileMatchPattern` for paths, else always. A rule named "agents" is refused there (it would be AGENTS.md on a disk that ignores case). - Not listed: Cursor (user rules live in its settings; .cursor/rules is per project), Codex (its rules are execpolicy), Droid (command permissions), Gemini CLI, Qwen Code and OpenCode (no rules folder). A body starting with --- gets an empty front matter first. Files are recorded with their hash in Applied.Rules through the same syncOwnFiles as subagents and slash commands: a file of the user's own by that name, or one magpie wrote that the user edited, is never written over or taken away. Bundles (backup, WebDAV) carry rules; a bundle from an older magpie leaves this computer's alone. The editor lists each agent's file to reveal. No CLI yet. docs/subsystems/library.md: a Rules row and its tests. Run (mica-run, at this tree): - go vet -tags nogui ./internal/library ./internal/gui ./internal/davsync ./internal/cli: ok. gofmt -l: none. - go test -tags nogui -timeout 45m ./internal/library ./internal/davsync: ok (TestRulesEachAgentsFile, TestRulesKeptToTheirPaths, TestRulesLeaveTheUsersFiles, TestRuleCheck, TestRulesCarried). - node --test library-rules, library-subagents, library-commands, library-hooks, library-loading, library-groups, i18n-keys, i18n-en-no-cjk (Chromium and WebKit, 420 and 1100 wide, en zh zh-TW ja de): 78 of 78. - The full suite and cross-OS vet ran at the next commit, which this one is under. - Real use: Claude Code 2.1.327 in a sandbox HOME loaded a rule without paths at launch and one with paths only on touching a match; a sandbox magpie on mica wrote ~/.claude/rules/go-style.md with paths: ["**/*.go"]. Not tried: Cline and Kiro CLI loading the files for real, project-level rules (.claude/rules in a repository), Copilot and CodeBuddy (not verified, not listed), Windows and Linux. |
||
|
|
a18ed4995f |
memory: a memory of several lines keeps them, folded to its first line (_meouwu on X)
_meouwu on X: a memory added by hand in several lines showed as one line with its breaks gone; it should keep its format and, folded, show the first line and an ellipsis. Cause: the store never lost the breaks. A memory file's body is m.Text as written (encode/apply trim only the ends). They were lost where it was shown: the Library row clamped the name to two lines with white-space normal, the digest given to agents went through oneLine (strings.Fields), and so did memory_search / memory_list in the memory MCP. Now: - Library: a folded row and a suggestion show firstLine(text) (first line, " …" when more follow); an open row shows the whole text pre-wrap. The editor already kept "\n". - Digest and memory MCP: memory.Indented keeps each line, the lines after the first indented two spaces so the memory stays one list item. - Dream and distill listings stay one line on purpose: the model's reply is read line by line, and a user's memory is Fixed, never rewritten by them. Written in docs/subsystems/memory.md. Memories saved before: their files already hold the breaks, so after updating they show, edit and reach agents in their own lines. Nothing to redo, no migration. Run at 3fabaf8f2 (on origin/main |
||
|
|
4e24994a6e |
gateway: a key let use Magpie Memory reaches it from another computer
Niapyaya on X reaches their own MCP servers through the MCP hub from a remote machine, but not magpie-memory: memory answered the agents on this computer alone, on /mcp/magpie/memory ( |
||
|
|
88b65d7584 |
library: the skills sheet says why an agent gets copies (4kT1FohCTP97031 on X)
The report (X, tweet 2123056163587780891): "Claude Code can only copy
skills, never link them; every other agent can use paths." Claude Code
already takes links: real claude 2.1.327 in a sandbox HOME and
CLAUDE_CONFIG_DIR loads a symlinked skill folder and a symlinked
SKILL.md, and reads the files beside it. The row that said 只能用副本
with no reason and no switch was Claude Desktop's (Cowork), which
really does skip a linked skill (Claude Desktop 2.7032; see
desktop_skills.go), so it keeps copies.
- AgentView gains CopyWhy and CopyWith (copyWhy in skill_how.go):
desktop, liveagent, wsl (a WSL agent on a Windows drive), junction
(agy/antigravity/crush on Windows), and shared, for an agent that reads
the same folder as one given copies. A shared agent was shown as
"Gets links" while syncSkills gave it copies (l.copies with sharers);
its How is now copy and the row names whose copies they are.
- The How sheet's row says the reason ("Only ever takes copies: Cowork
skips a linked skill"), in en, zh, zh-TW, ja and de. Without a known
reason it still says "Only ever takes copies".
- docs/subsystems/library.md says so.
Not changed: agy/crush on Windows take copies even where a symlink
could be made (#5107, #6610 decided that); not part of this report.
Tests:
- TestSkillHowSaysWhyCopies: Claude Code link, Claude Desktop
desktop, Codex reading Claude Code's folder as copies -> Claude Code
how copy, shared, ["Codex"], a copy on disk, and links again after.
Red on the old behaviour (fields kept, copyWhy and the How override
dropped): "Claude Desktop: why """ and "Claude Code: how "link"".
- skill-how.test.cjs: the desktop row's reason, a shared row, a bare
must-copy row, and a new all-languages test (en zh zh-TW ja de) at a
phone width. Red on origin/main's plugins/library client.js and
i18n.js in every language (expected the reason, got the bare words).
Run:
- gofmt -l clean. go vet internal/library and (-tags nogui)
internal/gui on Linux, GOOS=windows, GOOS=darwin (wsl-run): ok.
- go test ./internal/library -count=1 at this head (rebased on
origin/main
|
||
|
|
b400566f96 |
library: a resize no longer works out every agent chip's style again (lexrus on X)
lexrus's Skills page (196 skills, By source, about 24 agent chips a row, dark) crawled while the window was resized. Each row's chip strip was a size container, and the chips' gap used cqw. Chromium invalidates every style with container units on each change of the viewport width (ViewportUnits), so every chip was recalculated on each resize step. Now handGap works the gap out in whole pixels from each row's content-box width, which a ResizeObserver on the .lib-row hands over, so there is no forced layout and no container query. The CSS clamps --lib-gap as before, and the gap is set only when it changes. While the window is resized, .lib-resizing (held 600ms after the last step) turns the chips' translate transitions off, which WebKit was paying to start on every step. Measured with a Playwright probe at the reporter's scale (259 rows, 6425 chips, every group open), 30 resize steps between 1200px and up, CDP Performance.getMetrics and tracing, on mote: - Chromium: resize wall 24.4-29.3s -> 2.7s; style recalc 18.2-22.1s -> 1.3s; layout 0.47-0.71s -> 0.17s; long tasks 53-65 (6.8-8.0s) -> 15 (1.7s). - WebKit: resize wall 25.9-31.6s -> 9.2s; average frame 235-277ms -> 48ms (hiding every chip gives 1.8s, the floor). - Scroll is unchanged (about 31ms frames in Chromium, 20ms in WebKit). content-visibility was tried and dropped: it made scroll worse. skill-name-many-agents.test.cjs now resizes 866px -> 560px and checks the strips match a fresh 560px render, and a guard fails if library.css uses container units again. Broken by hand (handGap run only once): 3 pass, 3 fail. Restored: green. Run on mote at this head (rebased on |
||
|
|
454f9d023a |
library: the Tools on demand row names the agents the gateway gives every tool
The row under the MCP router said "Claude Code, Claude Desktop, Codex and
Pi find tools themselves and are given every one", but hubOnDemand gives
every tool to Droid and omp too (hubSearchesItself). The words now come
from the code: gateway.HubFindsItself (the ordered list hubSearchesItself
is built from) and gateway.HubOnDemandOver reach the library's view as
hubFindsItself (each agent by its name, its id when none is found) and
hubOnDemandOver, and the row joins them with the language's list
separator. Two keys replace the old sentence in zh, zh-TW, ja and de; the
CJK sentences follow each other with no space.
Tests:
- TestHubFindsItselfIsWhoGetsEveryTool: every named agent (and its WSL
id) is given every tool, every agent given every tool is named, and
other agents get theirs on demand.
- TestHubFindsItselfInTheView: /api/library carries the gateway's list
and threshold, each agent by its name.
- library-mcp-router-tools.test.cjs: the row's text is built from the
view's list and count (fixture: 12, six agents), names each one, never
says 10, and has no "。 ".
Run (wsl-run, magpie-desktop; mote was at load 46-49 of 18, mica's disk
full), at this tree on
|
||
|
|
4d79bebfa7 |
usage: speed counts all output, reasoning and tool calls too, from the first output (Archivemylife on X)
Archivemylife on X: speed should be the upstream's usage over the local time, with no split into reasoning, tools and answer, since reasoning and tool calls are tokens too. Speed is now every output token the vendor's usage counts (reasoning and tool-call arguments included) over the time from the first output of any kind to the end of the reply. The first output is the earlier of the first content (TTFT) and the first sign of reasoning, firstToken.reasoningMs in ttft.go, which works the same in every protocol: - a Responses reasoning item's start; - an Anthropic thinking or redacted_thinking block's start; - sealed (hidden) thinking; - reasoning deltas spread over 100 ms or more. Deltas that came at once are a buffered burst and tell none. A summary is no sign (summaryPart: a Responses reasoning summary, a Gemini thought, or a summary translated from another protocol via firstToken.summarized), because it is written after some of the reasoning it sums up (#1463). A reply that reasoned with no sign of when it began counts only its answer, its output less the reasoning, from its first text, and none with no text. Before this, a reply that reasoned always counted only its answer, and a reply that wrote tool calls after reasoning told no speed. Burst and held-content checks judge the answer's part. The same definition holds everywhere: - gateway: speed.go, trace.go, codex_backend.go; - usage.DecodeOf, for the Usage cards, rows and `magpie usage`; - the Usage page's ledDecode; - the Routing page's decodeOf and its ranking (fast routing reads noteTrySpeed, which uses DecodeOf). settledCountVersion goes to 8, so settled heat totals are counted again. The rule text is in en, zh, zh-TW, ja and de. Docs: reference.md, and gui-shell.md under "Streamed output speed". Red on the old code (scratch worktree at |
||
|
|
1c0ecec0f6 |
library: a magpie in Docker keeps skills and prompts for its clients
fenglian980510 on X: in the Docker gateway the Library had MCP and no Skills. Since |
||
|
|
5cf1d3846a |
sessions: an agent left off in the first "allow selected" is asked about once more, on Sessions and Usage › Requests
baysonfox on X: with magpie installed after Antigravity 2.0, the app's
sessions and calls made without magpie never showed in Usage, while agy
CLI's did. The first consent named the app off beside agy, and a named
agent was never "new" again, so nothing asked about it and nothing on
Usage said why. The reader is fine: the app's calls come from its own
SQLite steps (antigravityRead), read once allowed.
Nothing is turned on by magpie: the gate is the user's privacy choice.
Instead:
- settings.SessionReads gets Kept: agents turned off on their own (a
sessions/reads post without `all`: Keep off, a Settings › Privacy row,
`magpie sessions read off <agent>`). A post setting it on takes it out.
- readsNow's New: off, found here and not Kept (was: never named). So an
agent left off in the first choice's list is asked about once more,
as one found later already was.
- Usage › Requests shows a line above its rows for those agents
(readsLater in the usage plugin): Count {names} / Don't count, the
same {agents} posts as the Sessions page's laterCard. Gone after
either answer; sessions/reads read at most once a minute.
- Old data: an agent turned off in Settings before Kept existed has no
entry and is asked once more, for every user with such an agent.
Tests:
- TestSessionReadsUncheckedAgentAskedAgain (count, keep off): sandbox
HOME with testdata/agy-sessions and the real Antigravity 2.30
conversation (antigravity-2.30-tools); after the first choice the app
is off and New, has no rows in /api/usage/requests; Count brings its
rows in, Keep off keeps none, and neither is asked again. Red on the
old code (New false after the first choice).
- TestSessionReadsTurnedOffNotAskedAgain: off on its own, under all true
and all false, is neither on nor New.
- usage-reads-note.test.cjs: the Requests line in Chromium and WebKit,
en/zh/zh-TW/ja/de at 900/420/390px, both answers, buttons inside the
line, no sideways scroll; red on the old code (no #ledReads).
Run on mica (mote was full: load 40+, another GUI suite on it), rebased
on
|
||
|
|
8634c4ad08 |
library: a repository's card counts the skills its sheet lists once the repository is read
bdefdc319's repository card counted the skills skills.sh lists, while
its sheet, once Find skills' probe had read the repository, listed what
the repository holds: mattpocock/skills read 55 on the card and 39 in
the sheet, a number that changed on click.
A repository's read is now kept for the session (repoRead). Once it is
read, the card behind the sheet says the sheet's count at once, keeps
it when drawn again, and takes its Added from the read too; reopened,
the sheet lists the read repository straight away, the skills just
installed greyed, while it is read again. A later read that fails keeps
the one before; one with no SKILL.md drops it.
Run (mote, at origin/main
|
||
|
|
bfddc9cfba |
routing: DimCode's requests read as DimCode, with its mark, by key too
Yayoi_no_yume on X, a Docker magpie (v0.1.4350): DimCode (dimcode.dev)
on another computer, calling with a gateway key named "Magpie", drew
the Routing page's client node as the cube and "Magpie", and the
request's story said "DimAgent asked for the routing group Step 5
Preview".
Two causes:
- DimCode was no client magpie knew, so usage.AgentOf named it by its
product name: npm's dimagent 0.5.29 sends "DimAgent/<version>" to a
provider set to send its identity (resolveDimOAuthIdentityHeaders)
and "DimCode/<version>" otherwise (read from the published binary).
A client "dimcode" (DimCode, UA dimagent/dimcode) now names it,
apart from the Dim alpha magpie starts ("dima"/"dimcode-alpha" stay
Dim's, by name first). Its icon is dim-color: dimcode.dev's favicon
(dimagent-favicon.svg, "Official DimAgent mark") is the same artwork.
Routes and ledger records kept before are named again through
AgentOf (Route.routedAgain), so old "DimAgent" rows read as DimCode.
- A keyed request's node read the key's name alone (
|
||
|
|
bdefdc3191 |
library: a repository's skills on skills.sh are one card, opened to install all or a few (Ethereal499 on X)
skills.sh lists a repository's skills one by one, so mattpocock/skills showed as 55 cards side by side in Library > Skills > Discover. Two or more listed from one repository are now one card, the repository, where its first skill comes in the list: its name, how many skills the list has, their names and their installs summed. magpie's own featured skills and a repository with one skill listed keep their own cards. Only a skill's own card asks for its about. Opened (the card or its Choose...), the sheet shows the list's skills at once, ticked, and reads the whole repository through Find skills' probe (library/skills/probe): once it answers, every skill the repository holds is listed, the list's still ticked, the ones the library has greyed, with Select all and a filter past 8. Install takes the picked paths in one skills/install. A repository too big to read whole (#2794) keeps the list's skills, with the reason, and installs each as its card's Add does (market/skill). The "in the library" list already groups skills by repository (skillGroups), so it is unchanged. Strings in zh, zh-TW, ja and de. No backend change. Run (mote, at base |
||
|
|
67f24d7422 |
usage: every cache hit rate to two decimals, its exact share on hover; a speed's dash says why
shangyuan0818 on X: in Usage › Requests the ranking's model hit rates
had no decimals or one ("98%" beside "99.6%"), the request table mixed
them too, and hovering showed no exact value.
- hitPct gives every hit rate two decimals (98.00%, 99.60%), the same
in the ranking, the request table and its details, the Cache hit
rate card, the cache-read tiles, the model and agent rows, Sessions,
the tray panel, Routing's rows, figures and group averages, and the
context window's Prompt cache. It still never says 100.00% or 0.00%
of a prompt not all or none cached (99.99%, 0.01%).
- Each of them has the exact share on hover, in its title (hitTip):
"9,800 of 10,000 prompt tokens read from the cache: 98%", the share
to six places with no trailing zeros. One new string, translated in
zh, zh-TW, ja and de.
ohblue on X: 速度 shows "—" for many 200 requests (491 in, 93 out,
first token 6.3s, total 6.4s), "≥133 token/秒" for others.
- That speed can't honestly be counted: 93 tokens in the 120ms after a
6.3s wait would read ~775 tok/s, which is a reply written during the
wait and let go at once (ledHeldShort_). The dash already had its
reason as a title, but nothing showed it was there. It now has the
help cursor (the cache column's dash too), the Speed column's head
says what a speed is on hover, and a request's details say "— " and
the reason in words, for a reader who can't hover.
Budget: app.js and the core grew by my hitTip, cacheHitTip and the
titles. To stay inside both budgets with no raise, setQuotaRange moved
to plugins/usage/page.js and PLACEHOLDER to plugins/redact/page.js (each
read by that page alone), cacheHitOf and cacheHitTip share cachePrompt,
and hitPct is one expression. Core 1,272,578 of 1,272,581; app.js
1,087,887 of 1,088,248.
Run on mote/mica, this change on origin/main, both engines, every
language, at the widths each file covers:
- usage-hit-exact.test.cjs (new): green. Red with the old hitPct
('hit rate 98%') and red with the help cursor and the details' line
taken out ('pointer' !== 'help').
- 85 GUI files (every test that reads a hit rate, quota range or
masking, Usage, Routing, i18n-keys, gui-ja/de/zh-tw): 1318 pass, 30
fail. All 30 are red alike without this change, and all are filed:
agent-menu-label webkit panel (#6371), zcode-models webkit de
(#6566), quota-credits (#6807), quota-curve (#6789), usage-fold's
17 subscriptions (#3415, #6003), usage-ledger (#4078, #3104, #4626),
usage-ledger-chart (#6790). usage-fold's 'several accounts' went red
only under the 85-file run and passes alone on this tree (#3415,
commented).
- go test ./internal/gui on mica: ok (TestCoreScriptBudget included).
- Red alike on a HEAD checkout without this change, already filed:
usage-ledger "newest live route needs no return-to-live button"
(#4078, #3104, #4626), usage-ledger-chart "the metric is remembered"
(#6790).
Not run before the push: the whole GUI suite and go test ./... (both
machines had other sessions' full suites running); they run after it
and their result goes on record. Not tried: Windows WebView2, the
reporters' own ledgers, the real app.
|
||
|
|
42c43c0020 |
sessions: an agent found after Allow selected is asked about once (Antigravity 2.0)
baysonfox on X: Antigravity 2.0 desktop sessions showed on the Sessions
page only while the app was connected to magpie; agy CLI's always showed.
Cause: not the file reader. Real Antigravity 2.30 (signed out, no model,
sandbox HOME on the Windows box) writes ~/.gemini/antigravity/
conversations/<id>.db, conversation_summaries.db and brain/, and
internal/sessions parses them. The gate is settings.SessionReads:
"Allow selected" (and the Usage readsNote's "Count …") saves all:false,
so an agent installed after that choice is never read and never asked
about again. Gateway-recorded sessions skip the gate, hence "only when
connected".
Fix: /api/sessions/reads marks a found agent `new` when the choice was
made, it isn't read, isn't named in Agents and is on disk (Found(), which
checks every OS's path). The Sessions page shows one quiet card for those
(laterCard): "Show their sessions" names each on, "Keep off" names each
off, so it isn't asked again. No new endpoint; the card posts the
existing sessions/reads.
Tests: TestSessionReadsNewAgent copies the real 2.30 files
(internal/sessions/testdata/antigravity-2.30, sandbox paths only, no
tokens) beside agy-sessions, with agy allowed by name: antigravity is
off and new, nothing listed; after the answer it is not new, settings
keep all:false/agy:true, and its one session is listed only when shown.
TestSessionReadsNewOnlyWhenNamed: not asked, allow all, all with agy off
mark nothing new. sessions-reads.test.cjs: the card, both answers, posts
and no card after reload, Chromium and WebKit, 5 languages, 900/390px.
Run at d7d62d889, on mote, then rebased onto
|
||
|
|
61c714ed01 |
sessions: By tokens selects the small sessions, to delete them at once
A user asked for a way to delete every session under 10K or 20K tokens (yansheng1003 on X). Selecting sessions on the Sessions page now has a "By tokens" button beside Delete. It opens the app menu (openProtoMenu, no native select) with 10K, 20K, 50K and 100K, each showing how many of the sessions on screen it would select. A pick replaces the selection with the deletable rows on screen (search and filters apply) that used fewer tokens than that. Tokens are counted with sessTokens, the number each row shows. A session that is streaming now (speedOf().live) or was written in the last minute is never picked. The server already refuses one written in the last minute (sessions.Delete's ErrActive). Delete is the existing path: each agent's own delete, gateway-only and forgotten sessions handled as before, files moved to magpie's trash. The existing confirmation names how many sessions go and that Trash puts them back. When the selection is still the By tokens pick, it adds "Each used fewer than 20K tokens". A selection changed by hand drops that line. Only the Sessions plugin changes (client.js, i18n.js in en, zh, zh-TW, ja and de, sessions.css). No server change. New test: sessions-small-delete.test.cjs, in Chromium and WebKit, every language, against a faked API. It covers the menu's head and counts, the pick (running, live, read-only and larger sessions left out, cache counted as the row counts it), a smaller size replacing the pick, a search narrowing it, the dialog's size line, Cancel posting nothing, Delete posting the 4 ids, a 420px bar, and no native select. Run: - At the pushed tree (on origin/main |
||
|
|
87af7281e2 |
gui: Connected means an agent goes through magpie; the Library's list says Using the library
"Connected" meant two things: an agent routed through magpie, and an agent that uses the Library's servers and skills (item 18). The second is now "Using the library"; Connected keeps the first. Own tests: agent-app-restart, library-mcp-hub. Run (mote, Chromium and WebKit, en zh zh-TW ja de): - before the rebase, 23 GUI files: every one green except plugin-provider-options (my bug, fixed in this branch before the push) and settings-groups' "warm-ups and check-in in each service's provider editor", red the same way at fresh origin/main |
||
|
|
6facdb2461 |
gui: a provider's limit is Requests at once, as on gateway keys and accounts
The provider editor called it Concurrency while gateway keys and accounts said Requests at once (item 18). One name now, in every language; the old key is gone from i18n.js. Own tests: provider-concurrency, provider-rpm, lane-limit, gateway-key-concurrency; Go: internal/access. Run (mote, Chromium and WebKit, en zh zh-TW ja de): - before the rebase, 23 GUI files: every one green except plugin-provider-options (my bug, fixed in this branch before the push) and settings-groups' "warm-ups and check-in in each service's provider editor", red the same way at fresh origin/main |
||
|
|
28430c9b90 |
gui: magpie's own paths are written with ›
A path through magpie's own screens was written with › in some places and → in others (11-17 scan, item 18). Every one the user reads is now ›: Settings › Network and sharing, Settings › Privacy, Library › MCP servers, Providers › … › Use it anyway, Settings › Usage, in the GUI and in the Go errors and notices that reach it, in every language. The GUI matches errNotAsked by its prefix, so it still finds it. Left as they are: gateway errors written for agents, AiHubMix's and Claude Desktop's own menu paths (their apps' words), the image MCP tool description (it goes to agents), and comments. Own tests: chatgpt-usage-why, websearch-places, library-mcp-hub, i18n-keys; Go: internal/library (TestPrivateRepoInstallsWithToken, red on the first try because skills.go still had →), internal/plugin (notplugin_test), internal/pii, internal/provider. Run (mote, Chromium and WebKit, en zh zh-TW ja de): - before the rebase, 23 GUI files: every one green except plugin-provider-options (my bug, fixed in this branch before the push) and settings-groups' "warm-ups and check-in in each service's provider editor", red the same way at fresh origin/main |
||
|
|
039719491c |
gui: Sessions' Settings › names the session terminal too, beside history
The Sessions page's head had one Settings › link, and it went to Privacy's Agents' session history. The other setting the page uses, the terminal a session opens in (General's Session terminal), had no way there from Sessions. Where that row exists (a Mac, or a terminal found on Windows or Linux), Settings › now opens the app's menu with both, each noting its tab (Settings › Privacy, Settings › General), and each opens Settings at its row, lit, with Back to Sessions. Without a terminal row it goes straight to Privacy as before; gateway mode still has no link. When the row shows is one rule now (window.sessionTerminalShows in sessions/settings.js), asked by both. No new strings; the core is unchanged. Run (mote, at this tree): - sessions-to-settings (now also on a Mac: the menu, both items, each reaching its row, nothing moved, the menu inside the window at 420), sessions-reads, gateway-mode-sessions, settings-search, i18n-keys, Chromium and WebKit, every language: 104 of 104 pass. - go test ./internal/gui -run 'TestCoreScriptBudget|TestI18n|TestCSS': ok. Broken by hand, each red, then put back: - Settings › going straight to Privacy always: sessions-to-settings 20 of 20 red. - the terminal item aimed at the history rows: 20 of 20 red. Not tried: the real app window. |
||
|
|
2957d16e5e |
gui: every alert row says when notifications won't show, in sight; Bark says it gets them all
The scan's item 9. When the system blocks magpie's notifications, or
can't show them, Settings › Usage's four alerts said so after their
description, but the Masking alert in Settings › Privacy didn't. Both
take the line from one helper now (notifyWarn in app.js), and the
Masking alert appends it as the others do.
On a computer with a pointer that warning was never in sight anyway:
Settings holds a row's explaining line out of sight for the hover card
(app.css, 11-02), and the warning sat inside that line. The comment
there says a warning stays; the rule didn't. A line holding a .warn now
stays in place, so the warning is read without hovering.
Bark gets every notification magpie shows (sendAs → barkPush), even
while the system's are turned off. Its row now says so, in every
language, rather than following a separate set of choices.
New test notify-warn-places.test.cjs: denied and unavailable, the
Masking alert's and the usage alert's warning on screen (wider than the
1px a held line gets, no clip-path), none when nothing is wrong, Bark's
line, nothing past the edge; every language, 900 and 380, both engines.
Run (mote, at this tree; mote at load ~50 and mica at ~160, mote the
lighter):
- notify-warn-places, mask-alert, builtin-places, i18n-keys, bark,
settings-hints, usage-alert, reset-reminder, turn-done, settings-search,
settings-search-reach, settings-groups, gui-de, editor-hints,
privacy-hides-accounts, Chromium and WebKit: reds only these, each red
on an origin/main
|
||
|
|
93fa1d661c |
library: a Claude plugin's parts keep their own agents through sync, and each says which plugin it came with
givePlugin gives every part of a Claude plugin (skills, MCP servers,
hooks, subagents) the plugin's agents. putPlugins' settle ran it on every
sync put, even when the plugin's own agents and switch hadn't changed.
So an agent ticked or unticked on a part's own row was put back on the
next sync without a word. Now settle gives the parts the plugin's agents
only when those agents or the switch change. A part's own edit stays
until then.
The Library never showed `bundle`, so nothing on a part's row said it
belonged to a plugin. Each such row (Skills, MCP, Hooks, Subagents) now
carries an "In {plugin}" tag. Its tooltip says that changing the
plugin's agents, or turning the plugin off and on, gives the part to the
plugin's agents again. The tag is in en, zh, zh-TW, ja and de.
Tests:
- TestPluginPartOwnAgentsKeptBySync: tdd set to claude alone survives a
sync of the same plugin, and changing the plugin's agents gives tdd
the plugin's agents again.
- library-plugin-parts.test.cjs (new): one bundled part and one own part
on every tab. Each bundled part has the tag, with its text and tooltip
in each language, and the own part has none. Nothing is wider than the
window at 1100 and 420. Chromium and WebKit.
Run (mica, at this tree on
|
||
|
|
888d4eba52 |
library: the MCP market puts the most used servers first, counted from the day's report
gugediyige666 and freedomf26 on X asked for an MCP list ranked by
downloads, searchable and installable. Search and install from the list
were already there; skills were already ranked by skills.sh's install
counts. What was missing was a count of who uses each MCP server.
- internal/library/market_public.go: PublicServers names the Library's
servers that an agent is given and that the market lists from what
ships with magpie (featured, or the registry snapshot), by market id
only, matched by serverKey. A bare command names no package and is
never matched; a server of the user's own, one found only by a
search, and its address, command or keys never go.
- internal/stats/plugins.go: the day's plugin report carries them as
"servers" (at most 50), and goes when either list has something.
PluginCounts returns a Board with plugins and servers.
- site/pluginstats.js: servers are kept as mcp:<id> beside the plugins,
pruned apart (D1 binds at most 100 values a statement; the test's
stand-in now enforces that), never liked, and /api/plugins/stats
returns them under servers.
- GUI: with nothing searched, a server with 20 or more users comes
first, most used first, with a person chip of its count; the rest
keep the curated order. Counts are waited for at most a second, so a
drawn list never reorders; a search keeps the registry's ranking; a
failed ask is tried again after a minute, not with every search.
- Privacy text: READMEs (en, zh), site privacy and start pages (en, zh,
ja), reference.md, the Settings privacy row (zh, zh-TW, ja, de),
llms-full.txt and search indexes rebuilt; docs/subsystems/library.md.
Run (mote, rebased on 18fe1e2dc; budget, TestI18n*, i18n-keys, market-used and privacy-usage-stats again at
|
||
|
|
eca40383f7 |
routing: a group's routing and window read as a provider's do
The same setting had two names. The Routing page called the "usage"
routing "Least used", while the provider editor, Smart's own hint ("pick
In turn or Least used first"), Built-in plugins and the account reasons
call it "Least used first". A group's Advanced named the window agents
are told "Context", where a provider's Advanced, Agents and the context
card say "Context window". Both now use the provider editor's word
(translations already there in zh, zh-TW, ja and de). Stays, Rate
limited and Compact at already read the same on both pages and are left.
Run (mote, at this tree; load 27 on 18 cores, mica 26 on 12):
- group-context, routing-group-strategy, account-arrange, routing-save,
routing-key-windows, i18n-keys, group-compact and settings-search,
Chromium and WebKit: 118 pass, 2 red: account-arrange in both engines
(53 !== 52), red the same on origin/main
|
||
|
|
3c44ed92bb |
routing: a group's Save refuses a Slow to start, Context or Compact at that doesn't read
Typing "abc" into a group's Context, Slow to start minutes or Compact at
marked the box, but Save went on and sent the last good value (or the
one the editor opened with), so the user saw "Sol saved" for a number
they never typed. Save now stops on the first such box: Advanced opens,
the box takes focus, and the status line says what is wrong with it.
Compact at, which only set aria-invalid, now says it under the box too
("abc is not a length of tokens like 200k or 1m", the string Context
already has in every language); an empty box is none, not an error.
Run (mote, at this tree; mote's load was 27 on 18 cores, mica's 26 on
12, so neither had room and mote took it):
- group-compact, group-context and group-first-token, Chromium and
WebKit, every language each covers: 34 of 34 pass.
- go test ./internal/gui -run 'TestCoreScriptBudget|TestI18n|TestCSS|Budget': ok.
Broken by hand: the three tests on the old client.js are 34 of 34 red
("a bad time is not saved", "a bad context is not saved", "a bad
length is said, not only marked").
Not tried: the real app window.
|
||
|
|
a265632dae |
routing: a model in a group at one reasoning can be added again at another (visamzh on X)
visamzh on X: in a Routing group, the same model can no longer be added a second time at another reasoning effort (gpt-6.2-sol at xhigh and at high). It used to work. Cause: |
||
|
|
69233d6bcf |
docker: the image has npx, node, npm, uvx and python for the Library's MCP servers
Passings_z on X: in magpie's Docker image, adding Chrome DevTools' MCP
server from the Library said "npx not found". The runtime stage is
debian:12-slim with ca-certificates and curl only, and the Library's
servers run in the container (gateway mode keeps Library's MCP servers
and the router), so every featured entry but the remote ones failed the
same way: npx for chrome-devtools, playwright, filesystem, memory,
sequential-thinking, brave, firecrawl, tavily and everme, uvx for fetch,
git and time, and the registry's npx/uvx entries.
The image now copies in Node 24.22.3 (node, npm, npx, from the official
bookworm image, matching Debian 12's glibc) and uv 0.13.7 (uv, uvx, from
astral's image). python and python3 are a two-line shim onto uv's own
Python, which uv downloads into the volume on first use (UV_PYTHON=3.14).
UV_PYTHON_PREFERENCE=only-managed keeps uv from taking the shim as an
interpreter: without it uvx recursed and hung looking for one.
Size (docker image inspect / du -sxm / as root):
origin/main 74,636,782 B compressed, 190 MB on disk
this 142,667,379 B compressed, 370 MB on disk (+68 MB, +180 MB)
node is 127 MB of it, npm 19 MB, uv and uvx 43 MB. Bun in place of npx
was weighed and left: agents in the container read PATH themselves, and
Bun's Node compatibility isn't every server's.
The image still has no browser (Chrome would be ~300 MB more for every
user). Chrome DevTools' and Playwright's servers start, list their tools,
and every tool then fails: "Could not find Google Chrome executable for
channel 'stable' at: /opt/google/chrome/chrome" (seen in the image). The
check now reports such a server, run by npx/bunx/pnpx in a container with
no /opt/google/chrome/chrome and no option pointing it at a browser
(--browserUrl/-u, --wsEndpoint, --executablePath, --channel,
--autoConnect; --cdp-endpoint, --executable-path, --browser,
--extension), as Why "nobrowser" with its tools still counted. The row
says "no Chrome here", and its tooltip points at Magpie Browser or the
server's option for a Chrome it can reach; the hub's text says the same.
Desktops, macOS and an image with Chrome are unchanged. A docker-launched
(OCI) entry still says docker not found: there is no Docker in the
container. Docs (en, zh, ja docker.html) get an "MCP servers" section;
the Docker workflow's smoke test runs node/npm/npx/uvx/uv -v and finds
python3 and python.
Run:
- Docker on xiaomi-gpu, origin/main's Dockerfile vs this one, web mode
with a fresh volume, servers added with `magpie library mcp add` and
checked through POST /api/library/mcp/check:
- origin/main: chrome-devtools, memory: notfound "npx"; fetch:
notfound "uvx" (the report).
- this: memory ok, 9 tools; fetch (uvx mcp-server-fetch) ok, 1 tool,
Python downloaded on first run; chrome-devtools error nobrowser
--browserUrl, 33 tools.
- tools/call over stdio inside the container with a small node MCP
client: memory create_entities returned the entity; fetch fetched
https://example.com; chrome-devtools new_page returned the Chrome
error above.
- go test -run 'TestNoBrowser|TestCheckSaysNoBrowser|TestCheckStdio'
./internal/library on mote: ok. Broken by hand (the hook in
checkServer turned off): TestCheckSaysNoBrowser red, "got {State:ok
Tools:3 …}".
- GUI on mote, Chromium and WebKit, en zh zh-TW ja de, 1100 and 390:
mcp-no-browser (new), mcp-home-health, library-mcp-health, i18n-keys,
i18n-en-no-cjk: 58 of 58 pass.
- gofmt -l clean; go vet ./..., GOOS=linux go vet -tags nogui ./...,
GOOS=windows go vet ./... and go build ok on mote.
- go test -timeout 45m ./... on mote at this head (on
|
||
|
|
60b10c69a7 |
gui: Routing's live note gives way before its buttons in a narrow window (#6669)
Since Routing groups › (11-06) and Settings › ( |
||
|
|
223b900b48 |
library: a skill from GitHub or git syncs as its source, and what a sync leaves out is said (#5715)
JJasonsun (Discord #help, #5715): a skill over a sync's 64 MiB budget was left out of the server's file while Settings > Sync said the sync worked, so the other computer silently didn't have it. A library skill from GitHub or another git repository whose folder is still what was fetched (editState known and unedited, or Pending) now goes as its source, as a plugin does (plugin_carry.go): CarriedSkill gets Fetch, Hash and Commit, and the receiving computer fetches it itself after Put lets go of the library lock (fetchSkills, through updateSkills). Its files still go as far as the room the skills carried as files leave, so a magpie from before this, which ignores Fetch, writes the skill as it did. On the receiving side (fromSourceHere): same version is kept; one changed here is kept and, when the other computer has another version, said as a problem ("Update replaces them"); another version or a skill new here is fetched, unless the carried files are already the whole of it. A skill that can't be fetched stays Pending, shows "Not fetched yet" on its Library row, and is said as a problem until Update fetches it (library.Unsettled drops a settled one). A skill changed here, one from a folder, and one from a link holding a token (whose link must not be synced) go as their files, as before. What a sync still leaves out is said: state.LibraryLeft names skills and plugins whose files were too big (or that this computer never got, Skill.Missing, carried on as Left so a third computer isn't told it has them), state.LibraryProblems what the last sync bringing the library in couldn't put here. Status gives them as libraryLeft and libraryProblems, and Settings > Sync shows them in red under the status (askPreviewRows). Strings in every language. Run at this head (rebased on origin/main |
||
|
|
b1f044fc1e |
library: a Claude plugin goes to another computer whole, its hooks naming that computer's folder (#6685)
A plugin installed from Library > Claude plugins didn't reach the other
computer by sync: the bundle carried its parts as plain items, with
${CLAUDE_PLUGIN_ROOT} already resolved to the first computer's
<library>/plugins/<name>, and neither the plugin record nor its folder.
Hooks there pointed at a path that doesn't exist, Windows' too.
Now Bundle.Plugins carries each plugin's record (name, version, source,
pick, agents, Off, parts taken out by hand) and never its parts:
- A GitHub or git link goes as its source. The receiving computer
installs it from there, as UpdatePlugin does, after the library's lock
is let go. Re-installing from the source was chosen because the files
stay the vendor's and an update keeps working there; a fetch that
fails keeps the plugin Pending (shown on its row, "Update tries again")
with a problem, and the next sync or Update tries again.
- A plugin from a local folder, or from a link holding a token (whose
link must not be synced), goes with its files on the skills' budget,
executables kept executable, and is installed from them.
- Either way the parts are read again there, so every hook, server and
skill names that computer's own plugin folder. A plugin the bundle no
longer has is removed with its folder; Off spreads.
- A bundle from an older magpie has no plugins list: this computer's
plugins keep their parts over the same-named items it carries.
- An empty list hashes as before, so computers without plugins don't
see a change; the preview names each plugin, its files as one digest.
- Sibling: a plugin installed from a marketplace under a name other
than its manifest's named the manifest's folder in its parts.
- The sync settings' text says Claude plugins go with the Library (en,
zh, zh-TW, ja, de); "Claude plugins" moved into the core i18n.js since
the core now says it.
Run at this head (54e682dc5's tree on
|
||
|
|
ae94571d70 |
library: a project's own instructions, in the file each agent reads
@VictorHong1022 on X asked to manage AGENTS.md per project beside a project's skills, so the shared instructions keep only general rules. A project in the Library now has instructions of its own (the Instructions tab, expand a project; `magpie library project instructions <dir>`). magpie writes them into the project file each picked agent reads there, by that agent's own name for it: Claude Code CLAUDE.md (or .claude/CLAUDE.md when that is the one there), Codex and pi their override first, Gemini GEMINI.md (or its context.fileName), Qwen QWEN.md, CodeBuddy CODEBUDDY.md, the rest AGENTS.md. magpie owns only a marked part (<!-- magpie:begin … --> to <!-- magpie:end -->): the user's own text around it is kept byte for byte, CRLF included, a hand edit of magpie's part stays until the project's text changes, a file magpie made is listed in the repo's .git/info/exclude and removed when emptied, and an agent's user-wide instructions file is refused. Worktrees of the project follow it. A first text goes to the agents the shared instructions are on for, else every agent here that reads a project file. Problems show as the project's "instructions" problem. Tested: - internal/library: 8 new tests (block kept around user text, CRLF, hand edit kept, made file excluded and removed, renamed files, global file refused, worktrees). Four broken by hand, each red. - internal/cli: TestLibraryProjectInstructionsCmd; red with the default agents dropped. - GUI: project-instructions.test.cjs, en and zh, chromium and webkit, 6 of 6. Red when Goose (no project file) was offered, and red when the defaults ignored the agents the instructions are on for. - Real use on mote: the built binary, sandbox HOME and project. add, text, agents; CLAUDE.md kept CRLF with the part appended; AGENTS.md and GEMINI.md made and excluded; the user-wide CLAUDE.md untouched; zed refused; an edited part survived `library sync`; `agents none` put CLAUDE.md back byte for byte, removed the made files and emptied the exclude block. - Full Go suite (go test ./... -timeout 45m) on mote: 103 packages ok, gofmt clean, go vet darwin, linux (nogui) and windows rc=0, at this change on origin/main |
||
|
|
5bfa57e3d3 |
usage: check one model on one provider with a few fixed-answer calls, kept beside the other providers
skingstyle48487 on X runs more than ten relays and asked for something like the "pelican test" to spot one that waters a model down. In a follow-up (2122694296054972815) they said speed, failures and the model's name show whether a relay is fast and stable, not whether the model got weaker. They asked for small tests with known answers, the share of right answers and of right tool calls, and relays compared side by side. On Usage › Requests › Model speed › Providers, each row has a Check… that opens a dialog. Opening it sends nothing; only its Check makes the calls. POST /api/relay-check (gateway.CheckRelay) makes 6 small streamed Chat Completions calls through the gateway, pinned to provider/model as an agent would, three at a time: - write 1 to 40; - 1234 × 5678, 987 × 654 and 2468 × 1357; - weather in Paris and time in Tokyo, each call offering both tools, so the right one has to be picked. Each part says what it found, never a verdict on the provider: - whether the answer was the expected one, and what came back; - the model the reply named, when the ledger would call it another model (usage.Swapped, not SameSpelled or ListedAs); - the provider that answered, when the call was handed on; - how many input tokens the 118-character prompt was counted as; - first token, tok/s and the whole time. The dialog heads the parts with "Answers right: n of m" and "Right tool calls: n of m". The numbers come from the gateway's own usage records (a tap in appendUsage keyed on the request's context), not from each protocol's reply. The tally of each provider's last check is kept in the window's storage. The Providers table then shows Answers and Tool calls columns: sortable, amber when short of all, a dash for providers not checked, so relays are compared side by side. The dialog code is a lazily loaded root script (relaycheck.js), as app.js has no room left. Run, at this head: - mote: go test -timeout 45m ./internal/gateway ./internal/gui ./internal/cli ./internal/usage: ok (the full ./... suite passed at 41d88731c, before the fixed-answer calls; mote and mica were each running another session's GUI suite at this head); - gofmt -l, GOOS=linux go vet -tags nogui ./... and GOOS=windows go vet ./...: clean; - go test -run 'CheckRelay|ReadChatStream' -v ./internal/gateway (5 tests pass); - usage-model-speed.test.cjs, chromium and webkit, en, zh, zh-TW, ja and de at 400px: 12/12; - i18n-keys and old-webkit: their only reds are the three on origin/main, each filed (#6877 ", with an image", #5919 :has(), #6030 headerpresets.js); - TestCoreScriptBudget and the app.js budget: ok, not raised. Broken by hand: - taking tapUsage out of appendUsage turns TestCheckRelayAnsweredAsAsked and TestCheckRelaySaysWhatDiffers red; - dropping the tool-name check turns TestCheckRelayCountsEachAnswer red (get_weather for Tokyo read as right); - pressing Check as the dialog opens turns the GUI test red ("opening the dialog sends no call"). Not tried: - the whole GUI suite at this head (both machines busy with another session's suite); - a real relay (fakes only); - a context-window probe; - a comparison with the vendor's own count_tokens; - a periodic check (the check runs only on a press). |
||
|
|
fe41216b01 |
claude-desktop: Claude Code's WebSearch runs on the model picked for haiku (#6348)
In Claude Desktop's gateway mode, Claude Code's WebSearch call always went to the session's model (Opus here, 11-19s a search). Claude Code 2.1.321 sends it to its small (haiku-tier) model only when the remote flag tengu_plum_vx3 is on, and Desktop sets DISABLE_GROWTHBOOK=1 in gateway mode, so the flag falls back to off. WebFetch's page summaries already run on the haiku pick (#5534); WebSearch now does too. - desktopSearchCall knows the call by its shape only: tools is exactly one web_search_* server tool named web_search, and tool_choice is {"type":"tool","name":"web_search"}. The prompt is never read. - desktopMoveTo, for a request Claude Code sent in Desktop, puts it on DesktopTiers()["haiku"] when that pick is set, served and not already the model asked, recorded as desktop-search. It doesn't change the session's recorded model (desktopPicked). - A subagent's search taken by the haiku pick is Claude Code's helper, not the subagent's turn: Desktop's subagent model, effort and turn tag leave it (desktopSearchHelper; subagentTurnOf takes the agent, so terminal Claude Code is unchanged). - No haiku pick, or one magpie doesn't serve: nothing changes. - The Routing page says why (desktop-search, en/zh/zh-TW/ja/de), and gateway-routing.md has the rule. Ported from mdwsk88's f68197aa6 (mdwsk88/magpie desktop-websearch-haiku-tier), reviewed line by line. Changed in the port: the gateway-routing.md conflict was merged onto main's text (main's codex-suggestions kept), and the cheap pre-check is bodyHas on `"tool_choice"` and `web_search_` instead of bytes.Contains, since desktop.go no longer imports bytes on main (the patch didn't compile there) and every Desktop request from Claude Code takes this check. web_search_* is kept as a prefix, so a newer search tool version (web_search_20260209) is matched as the same call. Run on mote (go1.26.8). Whole packages last at base |
||
|
|
efcf8d9c0c |
routing: a key's row is named by its provider, the key after it (iamleehom on X)
iamleehom on X: "为什么路由中不显示供应商名称了?" Two OpenAI-compatible providers, each with unnamed keys, showed only "sk-4…ab10" and "sk-a…eb0c" on the Routing stage, with nothing saying which provider each belongs to. Cause: 83545a5d8's twin rule added the provider's name only when two providers' keys had the same name. A masked key always differs from every other one, so the rule never fired for unnamed keys, and a named key unique across providers lost its provider too. Change (plugins/routing/client.js, routing.css): - A key's stage row is headed by a new span.prov with its provider's name. The key's name follows in span.who, muted, and gives up room first (flex-shrink stays on .who). .who keeps the key's name, so every test and lookup that finds a row by it is unchanged. - The twin rule's sub-line is no longer needed for key rows; the plan name stays there. - The answered card says "Provider · key" (where()). - Rows inside a provider's fold are unchanged: the fold heading already names the provider once. Not changed, filed: the request list rows and the decision lines still name an unnamed key by its masked key alone (#6982). Tests: - routing-key-provider.test.cjs (new): the reporter's case, two providers with unnamed keys. Rows read [Relay East, sk-4…ab10] and [Relay West, sk-a…eb0c], the provider's name is not cut at 1100px, the card reads "Relay East · sk-4…ab10" from a live long-poll, and a fold's rows keep only the key under a heading naming the provider. Every language, both engines, 1100px and 440px. - routing-twin-keys.test.cjs: re-derived to [prov, who, sub]. Run: - Broken by hand: routing-key-provider at base 3f4372cc9's client.js on Windows, chromium: every non-fold subtest red (null .prov; the card read "sk-4…ab10"). On mica at the first design: 42 red, 20 (folds) green. - Screenshots (zh 1100px chromium, en 440px webkit, de 440px chromium) checked by eye: "Relay East sk-4…ab10" on each row, nothing overlaps. - Windows (xiaomi-gpu, win-run, Node 22, Playwright 1.62.0, Chromium + WebKit), at 90aa5bc23 (this change on |
||
|
|
3be322fe4c |
library: a skill brought in from an agent goes back to it when removed (BeiWeiji on X)
BeiWeiji on X (v0.1.4322, zh): a skill imported from "Agent 中已有"
had no way back, only off or Remove, and removed it was gone from the
agents and from "Agent 中已有" too: Remove sent the folder that had been
moved into the library to magpie's backups and took the agents' links
and marked copies away.
ImportSkill now records where the skill was (Skill.Home, this
computer's own; Put keeps it for the same source, a sync never carries
it): the folder moved in (Home.Dir; handOver points it at the shared
~/.agents/skills place) and each agent's entry, a link with its own
text or a byte copy. RemoveSkill/RemoveSkills put it back (putBack):
the library's folder moves back to Home.Dir with what was changed in
the library, or the library's link goes; each agent's link is made
again as it was and each copy copied back. It is in "In your agents"
again and nothing goes to the backups. An entry the user replaced since
is left alone; when Home.Dir is taken the skill is removed as before,
its folder to the backups. This covers every agent with a skills folder
(the record is per agent entry, links and copies alike).
The page: SkillView.back lists those agents, and such a row has Put
back in the trash's place ("放回 {agents}"), whose sheet says where it
goes and sends skills/remove. Other skills keep the trash.
Old imports: a skill brought in before this has no Home record.
Removed, its folder goes to magpie's backups as before, where it can
be moved back by hand (the reporter's already-removed skill is there).
Run (at this change on
|
||
|
|
f1a4de736e |
routing: a group's card says each member as one piece, parted by the list's comma (tmr11235 on X)
tmr11235 on X (v0.1.4334): a found group's card read "Kimi Code · K3.1
Pro · OpenCode Go · Kimi K3.1 Pro (关闭) · Devin · Kimi K3.1 Pro". The
same " · " parted a member's provider from its model and one member
from the next, so nobody could tell where a member ended.
Now each member is one span: its provider in the line's muted colour,
then its model in --fg-2 (both colours the page has), then what is said
after it (account, fast, free, off). Members are parted by the list's
own comma, t(", ") (、 in zh, zh-TW and ja), or " → " in order, never
" · ". Narrow (body.web), a member moves to the next line whole; before,
"(off)" could sit on a line of its own.
Siblings: memberLabel, the one text form, is built from the same parts
(memberParts). The group-picking card (the row drawn while selecting
groups to remove) uses the same memberLine. A nested group's tooltip in
the editor joined with " · " too and now uses memberJoin. The rule
tooltip already joins with ", ". The CLI and TUI list member ids
(provider/model), where "/" already parts provider from model; left as
they are. No new string, no new colour.
group-member-free.test.cjs read the members by splitting on " · ";
it now reads each .mbr.
Red on the old client.js: group-member-line.test.cjs (AssertionErrors:
the members are one text node parted by " · "). Red without the
body.web .mbr rule: WebKit at 420px, "(off)" alone on a line.
Run at f8787be1f, these two commits on origin/main
|
||
|
|
dbbb2f26b1 |
groups: free: takes the models a catalog marks free (#5903)
A routing group's pattern may now start with free: (provider.FreePrefix): free:workbuddy/* is, of the models workbuddy/* matches, those whose catalog entry says free (Entry.Free, the vendor's or plugin's own flag as the catalog was last read). The rest after free: is a glob, a re: pattern or an id, matched as on its own, so free:re:workbuddy/hy.* works too. It is expanded where every pattern is (matchesIn, PatternHits) each time the groups are read, from the catalog magpie already keeps: no request to a vendor, and a model the next list marks free joins without a save. Only the flag decides. A $0 price (PricedFree), a rate of 0, an account named Free or "free" in an id never counts; the test holds a deepseek-v4-free id with no flag, a rate-0 model and an or/y priced at $0 out. Existing patterns read as before: openrouter/*:free still means ids ending in :free (that is why the rule is a prefix, not a :free suffix), and a provider's AutoInclude takes no free: (isIDPattern). GUI: the Routing editor's pattern box counts and lists a free: rule live as it does any pattern (patternTest in plugins/routing/client.js, from groups.models' free), refuses "free:" alone, and one hint line says the flag is the last catalog's, not a promise of no charge, in en, zh, zh-TW, ja and de. CLI help, docs/subsystems/providers-accounts.md and the site's routing-groups page (en, zh, ja) say the same. routing-levels.test.cjs: the Advanced hint line made the editor taller, so the second group's Levels row opened under the editor's sticky foot and the click landed on the foot (webkit en). The test already wheels to that row for its first group; it now does for the second too. Run: - TestGroupFreeRule, TestFreeRuleSyntax and the existing pattern tests pass. Broken by hand: with groupmatch.go and autolist.go from origin/main both are red (no members for free:workbuddy/*, IsPattern); with takes() ignoring the flag, TestGroupFreeRule is red (all six WorkBuddy models matched). - group-free-rule.test.cjs (new): chromium and webkit, en and zh, green; red with origin/main's client.js. - go vet ./... (darwin, mica), GOOS=linux go vet -tags nogui ./..., GOOS=windows go vet ./...: clean. gofmt -l: nothing. - Full suite go test -tags nogui -timeout 45m ./... on Linux (WSL magpie-desktop) at 1e180c630 (this change on |
||
|
|
b0674b9ec4 |
providers: a key's balance shows on its row, as Usage last read it
lyj1115 on X: magpie found the relay's balance (the probe), but the Providers row showed only the API key; the figure was on Usage alone. The row's quiet facts line (host · models) now ends in " · $10472.14", in the line's own colour and size, with "Balance $…" as its tooltip. Several keys' balances are added up as the Usage card's head adds them (shared balances counted once), else the key in use's. A failed read, a signed-in account (its windows are on Usage) and Usage turned off show none. Opening Providers asks for Usage's own read (never ?asked=1, so "read only when asked" holds) when it is over a minute old, as Routing does (#1833); rows are marked after the list is drawn and after a read. rowBalance, markBalances and keysSum/keysSumTip live in plugins/usage/page.js (keysSum moved out of app.js) so app.js stays under its code budget without a raise; app.js calls markBalances?.(). No new words, no CSS. Run (mote, at this tree rebased on origin/main |
||
|
|
8608ce0243 |
gui: the sticky tab strips are drawn only under scrolled rows, rounded and evenly inset (CHENGJIAHEGOXIS on X)
Over a background picture the Library tab bar showed a square frosted box
around the rounded tabs, 16px out at the sides, 8 at the top and 4 at the
foot. The strip behind the tabs (Library, Plugins, Settings, the Add
sheet) is now drawn only once rows scroll under it (.stuck), fading in
with opacity, so at the top only the track shows: radius 7, an even 2px
around its 5px pills. When drawn, it sits 4px out from the tabs with
radius 11 at its foot (Library, Plugins), and 6px out with radius 13 in
Settings and the Add sheet.
Run: shots in Chromium and WebKit, light and dark, with and without a
wallpaper, at 1280 and 640, at rest and scrolled, before and after
(strip opacity 0 at rest, insets 4/4/4 when stuck). Full GUI suite at
18ec1674a on mote: 1041 fails across ~118 files; those files at
|
||
|
|
34606000da |
gui: the tray panel's Usage tab ends in a heatmap of recent weeks (eiyuuzaki2333 on X)
Asked for "a heatmap like GitHub's / Codex's, also in the tray". The window already has one (Usage › Requests, 53 weeks, #1369), so no second copy goes on the Overview, which counts gateway calls only while the heatmap counts session-file calls too. The tray panel had none. The panel's Usage tab now ends in a card of the recent weeks, one cell a day, Monday on top, as many weeks as the card fits (8 to 53: about 25 at the panel's 440, 17 at 320). It goes after the chart and ranking, so nothing above it moves. Its shades are the existing monochrome accent ramp (.l0 to .l4) and follow the tab's own Tokens / Cost / Requests switch, with no new read; a provider or computer picked above narrows it. A tooltip says the day and its tokens, requests and cost. Weeks with no call show no card. No animation. It reads the existing cached /api/usage/heatmap, at most once a minute and again when a pick changes; the tab's own 10 s reads don't wait for it, and no endpoint was added. The card, its reads and tooltip live in plugins/usage/page.js, which shares its grid (heatGridOf, taken out of drawLedHeat as it was) and tooltip (ledHeatTip, now told the metric and provider) with the Requests tab. app.js keeps one guarded call in renderPanelUse: the ledger read can come back before page.js has run, so page.js draws the tab again when it loads. Both script budgets hold it at this base with no raise. The card is .pu-heat, not .pu-card, so the chart's card stays the tab's one .pu-card. The panel's light pills are its card's white, so a quiet day there is a 7% shade of the text over the card. Run (rebased on origin/main |
||
|
|
8707ea7757 |
gateway: Codex's prompt suggestions go on a model set for them (@0xcb198609 on X)
The Codex app's home-page prompt suggestions (thread_source ambient_suggestions, and their safety check, ambient_suggestion_safety; the Routing page's 提示词建议) are a background agentic turn that reads the project and connected apps. The app asks for the model its server config names (codex-app-model-routing's codex_ambient_suggestions_model_slug, gpt-6-luna) with provider model fallback on, so with magpie as Codex's provider they ran on the provider's default model, often auto: @0xcb198609 saw 76.9k tokens in 113s on deepseek-v4-pro. Codex has no config.toml key for that model, only an on/off switch in the app (store key ambient-suggestions-enabled, Settings › Configuration › Homepage suggestions; read from the 26.1106 bundle). magpie now has a setting for it, "Codex prompt suggestions" in Codex's row on the Agents page (Settings, beside Codex composer predictions): - Empty, the default, is Codex's own pick: nothing moves. A value the user set is never overridden. - A model or group of magpie's puts both calls there: in serve as the codex-suggestions move (the Routing page says why), and on the ChatGPT backend's route before the split, carrying the asked model to serve so the trace and ledger keep it. codexOwnOffMagpie leaves a bare gpt-6-luna to magpie while the setting is on (codexSideSet). - A target that is disabled, unserved or not allowed to the gateway key leaves the call as asked, with a log line (compactRefused). - To fit app.js's script budget without raising it, the suggestions and auto-review pickers share codexPick with codexSidePick, and every Codex row's button comes from condButton. The new route is named for the CLI (settings_parity_test.go). agent-prefs and settings-general list the new row. - The row's tooltip and the Routing page's Suggestions story say where Codex turns them off. magpie's old story said "Suggested prompts", which the current app no longer shows; corrected in all five languages from the app's own locale files. Run (mote, at this head rebased on |
||
|
|
50f7a8e01f |
routing: a Smart row behind one renewing sooner says so; Smart says new conversations go there too
YsiCing on X: in Smart, every conversation went to one Codex account (pro,
74% of its week) while Business and team, both at 0%, said "已用 0% · 会话留在另一个账号" ("0% used · the conversation stays on another account").
That is what Smart is meant to do. It sends every request, new
conversations included, to the one account whose quota renews soonest, and
only Stays: Session or Strict spreads new conversations. But the row blamed
a kept conversation, and the Smart description said "one account at a time"
without saying that covers new conversations, plus "at 90%", which is wrong
for a week since
|
||
|
|
c38753a7ee |
search: Settings can ask every search API at once, results merged (heyiwei5 on X)
The search APIs are asked in order: the next only when one fails or
finds nothing. Asking several together, with their pages merged and
repeats dropped, has existed since #2845 but only through
`magpie search mix`. Settings › Models › Web search now has an Advanced
fold, shown with two or more search APIs on, holding "Ask the search
APIs: In order | All at once". All at once marks every API on as mix
(POST /api/settings/search-api {"mix":[...]}, provider.MixSearchAPIs);
In order clears the marks. In order stays the default. A mix of some of
the APIs, set from the CLI, opens the fold with neither choice on and
names the APIs it asks.
Run (mote, at this tree):
- go test ./internal/gui -count=1: ok.
- TestSearchAPIsMixedFromSettings at origin/main's api.go: build fails
(searchAPIJSON has no Mix), so it is red on the old code.
- node --test search-mix, search-count, search-api, i18n-keys:
72/72 pass, chromium and webkit, en/zh/zh-TW/ja/de, 1100 and 560px.
- search-mix.test.cjs at origin/main's assets: 0 of 30 pass (red).
- gofmt -l: clean.
- After rebasing on
|
||
|
|
b34243823e |
routing: accounts' resets stay in their column, and resizing over many accounts is smooth (lexrus on X)
lexrus on X: on Routing's Accounts and keys, at some widths "resets in
3h" ran over the next column and the right column's words were cut, and
with many accounts dragging the window's edge was janky.
Overlap: the window parts' widths (--wk/--wv/--wr) were taken from the
widest window of the whole list, so one provider's long reset pushed
every row past its column. They are now per provider, and CSS caps each
part to its row.
Jank: the list was CSS columns, and the browser balanced every row again
on each layout. packActs (plugins/routing/client.js) places each
provider's box (and a long box's rows) itself under .rt-acts.packed with
--px/--py: down a column and on into the next, ends as level as a binary
search on the cap allows, a heading never last in a column. It runs on
the window's resize, on render, and a frame after a box's height changes.
Side mode (min1150, beside the requests) is unchanged: one scrolled
column, nothing placed. Measured on mote with a 100-row fixture, per
resize step: WebKit layout 26.6ms -> 5.9ms, frame p90 35 -> 18ms;
Chromium layout 8.24ms -> 2.86ms.
Test: routing-account-windows-fit.test.cjs, 4 and 20 Codex accounts, en
and zh, Chromium and WebKit, widths 420-1600: no window part runs past
or is cut, a provider's lines start together, the list isn't CSS
columns, boxes sit inside the list in column order without overlapping,
2+ columns at 700-1099. Broken by hand: the old assets are red on the
overlap; packing turned off is red ("the list isn't CSS columns").
gui-shell.md says how the columns are placed.
Run on mote at this change on origin/main
|