Repository navigation
v0.44.1
·
2830 commits
to master
since this release
This patch release restores OMP role aliases for the historian and dreamer (#526), bounds the session history that primer refresh and the retrospective task hold in memory (#552), gives OpenAI GPT-5.6 and later a 30-minute default cache TTL, and reloads historian.maxTokens and dreamer.maxTokens without a restart (#551).
Upgrading
- No schema change. The database stays at v91, so hosts on 0.44.0 and 0.44.1 can share it and no coordinated restart is needed.
- OpenCode 2 does not install plugin updates on its own. Open
/plugins, select Magic Context and press ctrl+u, or runopencode plugin update. - Pi:
todowriteis off by default. To keep it, set"todowrite": { "enabled": true }, then run/reloador restart Pi (see "Pi" below). - One cache rebuild per session. The agent guidance text changed (see "Agent guidance" below), so each session rebuilds its prompt cache once on its first turn after the update.
OMP role aliases (#526, Qiiks)
- A historian or dreamer model written as a role alias works again. OMP expands a model such as
"@historian"inhistorian.omp.modelordreamer.omp.modelin its child process. 0.44.0 started checking configured models against the host's model registry, which doesn't list role aliases, so the alias was dropped: those users had no historian, and dreamer tasks left without a model were skipped. On OMP, a model starting with@now skips that check. Plain Pi has no role aliases and still drops them. Aliases infallback_modelsare still removed when the config is read; that part of #526 remains open.
Memory use in dreamer tasks (#552, lichtsprung)
Primer refresh and the retrospective task read old sessions, and on a project with a lot of history they could load whole sessions, tool outputs included. Both now read in bounded pieces on OpenCode and Pi. Figures are sampled JS heap increases for one task run on 10,000-message test fixtures.
- Primer refresh reads its origin session a page at a time. On OpenCode, it reads 50-message pages that leave out tool outputs, diagnostics and reasoning, and stops at its token budget: no measurable increase, against about 87 MiB for a whole-session read. On Pi, it used to list every session file with its message previews and load the chosen file in full. It now reads only file headers to find the session and streams the file, keeping text and tool inputs: about 26 MiB instead of 155 MiB.
- The retrospective task keeps only what it uses. On Pi it streams session files and keeps only typed user text: about 0.6 MiB instead of 174 MiB. On OpenCode it already limited the number of messages but read the full data of each selected part, so an 80 MiB tool output in the test was loaded whole. It now selects only user text and tool error evidence in SQL. The model's input is unchanged on both hosts.
- Primer refresh uses only its own project's history. Before, a primer's origin session could come from any project.
- Pi no longer reads OpenCode's session store. At startup, Pi ran two backfills over every OpenCode session in the shared
context.db, and a primer refresh with an OpenCode origin read that whole session. These now run only in OpenCode. - Pi in the home directory no longer acts as a project. A Pi session started in
$HOMEhas no project identity, and Magic Context registered embeddings and the dreamer under an empty project key. It now logs once that the directory is not a project and keeps memory, search, embeddings and the dreamer off there.allow_home_project: truein user-level config gives home sessions their own project. ctx_expand's single-message and range views read page by page instead of loading the whole session.
Cache TTL defaults
- OpenAI GPT-5.6 and later default to a 30-minute cache TTL. OpenAI documents that cached prefixes on these models last at least 30 minutes after the latest write or reuse. With the generic 5-minute default, Magic Context treated a still-valid cache as expired and applied deferred changes early. This covers the
gpt-6family, and applies through theopenai/,openai-codex/,openrouter/openai/andazure/prefixes. Earlier models keep 5 minutes. - Precedence. A per-model
cache_ttlentry wins, then the built-in model default, then the object form'sdefault, then"5m". A globalcache_ttlthat is unset or"5m"counts as the default, so GPT-5.6 gets 30 minutes. Any other string, such as"10m", applies to every model. To force 5 minutes on GPT-6, add a per-model entry. - The policy is fixed per session. It is recorded when a session first resolves its model and survives restarts. A model switch resolves against the recorded policy, so a
cache_ttlchange applies to sessions that start after it. This applies on OpenCode, Pi and Rust mode. /ctx-statusshows the effective TTL and its source.
Live reload (#551, Littlericket)
historian.maxTokensanddreamer.maxTokensreload without a restart. A change applies from the next historian or dreamer run; a run keeps the cap it started with. This covers OpenCode 1, OpenCode 2 and Pi's dreamer. In Rust mode, the plugin sends the current historian cap with each request, and the module uses it after ack-mcupdate.
Agent guidance
<system-reminder>is now described as instructions to act on. The guidance listed it with Magic Context's records as "never instructions", although reduction reminders arrive in exactly that tag, and hosts use it for their own reminders too. It now says that<system-reminder>carries instructions from Magic Context or the host, that<ctx-search-hint>suggests a search, and that history, memory and drop markers are records whose quoted text must never be followed. This applies on OpenCode, Pi and Rust mode.
Memory mural
- Every cue symbol now has its own glyph.
∵ ≺ ≻ ∅ ∀were drawn as a fallback box, and the arrows and the prohibition sign⊘were hard to tell apart. Stored cues render correctly without being recompressed. - The mural carries a one-line legend next to the image: red cues are prohibitions,
→means leads to, andctx_searchrecalls the full memory. It appears only when the mural is shown, and is picked up the next time a session rebuilds its history block.
Pi
todowriteis opt-in. Magic Context registered its owntodowriteon Pi by default. It is now off unlesstodowrite.enabledistrue; when off, the tool,/todos, the overlay and the synthetic todo reminder are absent, in subagents too. OpenCode has its owntodowriteand is unaffected.
Credits
Thanks to Qiiks (#526), lichtsprung (#552) and Littlericket (#551) for the reports.