Releases: cortexkit/magic-context
v0.17.2
What's Fixed
Eliminated ~1.4 seconds of redundant work per LLM flight from the tool.definition hook handler. The hook fires once per tool per flight (~58 fires/flight on rich MC setups), and each fire was running JSON.stringify on the full schema, the Claude tokenizer on description+params, and an INSERT OR REPLACE against the plugin database — all producing identical output across flights because tool descriptions and parameters virtually never change.
The fix adds a per-(provider, model, agent, toolID) content fingerprint that bails out before any work when the new fire matches the previous one, plus a cached prepared INSERT statement to avoid repeated SQL compile cost on cold paths. Steady-state plugin overhead drops from ~1400ms/flight to ~19µs/flight. Cold paths (first flight after restart, MCP server reload) are unchanged — they still do the full measurement once.
Upgrade
npx @cortexkit/magic-context@latest doctor --forcev0.17.1
v0.17.1 — Kimi/Moonshot fixes, indexing performance, auto-update reliability
What's Fixed
Kimi/Moonshot 400 errors
Two related fixes for openai-compatible providers (Kimi, Moonshot, etc.) that previously rejected requests with errors like the message at position N with role 'assistant' must not be empty or reasoning_content is missing.
- Empty assistant message rejection. Whole-message sentinels for non-Anthropic providers now use
[dropped]instead of"". Anthropic still gets empty content because its SDKnormalizeMessagesfilters those out cleanly. Other openai-compatible backends serialize empty content into the wire request and reject it. - Empty
reasoning_contentrejection on tool-call assistants. The Anthropic groupIntoBlocks workaround (stripReasoningFromMergedAssistants) is now strictly Anthropic-only. For Kimi/Moonshot, every assistant tool-call message now keeps its originalreasoning_contentinstead of being stripped to satisfy a rule that doesn't apply.
These fixes preserve cache stability — both gates use the same per-pass deterministic provider check, with no oscillation across passes.
Auto-update checker — actually fires now
The previous auto-update checker gated all work on a session.created event. In real usage that gate almost never triggered:
- TUI restart with a resumed session never fires
session.createdfor that session. - Multi-project plugin reloads each got their own plugin lifetime with a fresh
hasChecked=false, so only the project that happened to create a brand-new session first ever ran the check. - Sidebar/status polling and idle TUI use never trigger
session.created.
Message-history indexing — major perf and lock fix
Reconciliation was previously building a Set of every indexed message ID for the session inside a write transaction (~30 k+ rows on long-lived sessions). That held the SQLite writer lock long enough to produce intermittent SQLITE_BUSY stack traces during steady-state operation — about 78 lock errors over 4 hours of active use on the development DB.
The fix removes that bulk SELECT entirely. The lastIndexedOrdinal watermark already encodes "every ordinal ≤ N has been processed," so any message above the watermark is by definition unindexed. The reconciliation transaction now contains only the actual inserts. A UNIQUE(session_id, message_id) constraint catches the rare partial-reconciliation duplicate; other errors still propagate.
Async indexing also tolerates residual BUSY now: a one-line warning is logged and reconciliation catches up on the next pass automatically, instead of producing stack traces.
Internal
@opencode-ai/plugin and @opencode-ai/sdk bumped to ^1.14.39
Both were pinned at ^1.2.26, twelve minor versions behind the current 1.14.39. The API change between them is purely additive (new optional hooks, experimental_workspace, provider?: ProviderHook, more typed event payloads) — no removals affect existing code. Bumped to keep the door open for newer hooks in future releases.
Upgrade
- Run
npx @cortexkit/magic-context@latest doctor --forceto refresh the OpenCode plugin cache and pull v0.17.1. - No config changes required.
- No migrations triggered by this release.
Notes for power users
The 5-second auto-update window is configurable via the initDelayMs option, and the cross-process dedup interval via checkIntervalMs (default 1 hour). Both are passed through createAutoUpdateCheckerHook in packages/plugin/src/hooks/auto-update-checker/. For end users no action is needed — the defaults are fine.
v0.17.0
v0.17.0 — Performance and Stability focus
What's New
Tag identity — root-cause fix for tool-call collisions
The plugin now uses composite tag identity (callId, toolOwnerMessageId) instead of bare callId. This closes a class of bugs where OpenCode reuses the same tool callId (e.g. read:32) across different assistant turns, which previously caused tags from older turns to drop the wrong tool calls and surface as model-side failures like Kimi's No tool call found for function call output.
What you'll see on first launch after upgrading: a one-time backfill runs to populate owner data for existing tool tags. On a session with ~187k tool tags this takes 25–30 seconds and is fully resumable (lease-based; survives kill mid-flight). Smaller sessions complete in under 2 seconds.
Performance — major hot-path speedups
Three layers of work compound into a 20–25× transform speedup on large sessions:
- Message indexing moved off the hot path. Search no longer blocks transforms on FTS reconciliation; indexing happens via async events and on-demand reconciliation, while
searchMessages()is now a pure FTS query. - Targeted tag queries. New partial indexes plus narrow query helpers replace full-session tag scans where only the active or recent slice was needed.
- Tagger reload caching.
initFromDbnow skips full reloads when SQLitedata_version + total_changeshaven't moved on the connection — typical defer passes cost ~0.005 ms instead of ~15 ms when no DB writes have happened.
Measured on a 1530-message session: transform latency dropped from roughly 900 ms to 40–47 ms.
TUI sidebar — Tool Defs and Memory recovery after restart
The sidebar's Tool Defs and Memory token buckets used to show 0 immediately after restart until the first new chat message landed. Both now recover from OpenCode's session DB on the first sidebar query, so the breakdown displays correct totals as soon as you open a session.
What's Fixed
- Kimi-class tool-result-without-pairing failures. Composite identity prevents the cross-turn callId collisions that caused these.
- Sidebar zero buckets after restart. Memory and Tool Defs now recover from persisted state instead of relying solely on in-memory caches.
- Auto-search nested system-reminder leakage. Embedding queries no longer pick up leaked
</system-reminder>markup from prior turns. - Models-dev cache log spam. Refresh now happens hourly, and oscillation between two stable provider-reported model counts (caused by upstream provider plugins like github-copilot toggling
model_picker_enabled) is logged once instead of every refresh. - Migration sibling-instance race. Concurrent OpenCode instances starting at exactly the same time no longer fail-close one of them due to a
schema_migrationsPRIMARY KEY conflict. - Dashboard OpenCode message preview empty. Session viewer now aggregates text from the
parttable instead of looking only atmessage. - Dashboard Pi session title overflow. Long titles wrap correctly; migration banners are stripped from preview text.
- Persisted-nearest-prior owner derivation. The result-only-window fallback for compacted-invocation lookups now actually fires (was previously dead code due to a missing
ATTACH ocrequirement that production never satisfied).
Internal Cleanup
- Pi historian per-event tracing is now gated behind
MC_PI_HISTORIAN_TRACE=1. Production logs keep high-signal lifecycle events; verbose NDJSON tracing is opt-in for future debugging. - Removed the obsolete Kimi/Moonshot interleaved-reasoning preservation gate. OpenCode upstream now always emits
reasoning_contentfor interleaved providers (opencode-ai/opencode#24146); the local workaround was no longer needed and was masking the real Layer C composite-identity work.
Upgrade
- Run
npx @cortexkit/magic-context@latest doctor --forceto refresh the OpenCode plugin cache and pull v0.17.0. - First launch on a large existing session triggers a one-time backfill (≤30 s typical, fully resumable if interrupted).
- Pi users: peer dependency floor stays at
@mariozechner/pi-coding-agent ^0.71.0. - No config changes required.
Notes for power users
The Pi historian raw-event trace is preserved behind MC_PI_HISTORIAN_TRACE=1 for cases where a future Pi subagent hangs need investigation without rebuilding. Production runs leave it off.
Full Changelog: v0.16.3...v0.17.0
Dashboard dashboard-v0.4.2
What's Fixed
- Session viewer — OpenCode messages now show their content. Message previews and full text were empty for OpenCode sessions because the dashboard was reading text only from the
messagetable. The session viewer now aggregatestype=textparts from theparttable, so user and assistant messages display correctly across the timeline and detail views. - Session list — long Pi titles wrap correctly. Pi session titles taken from the first user message could overflow the row layout. They now wrap to multiple lines, and lingering migration-banner prefixes are stripped from preview text so titles read cleanly.
Internal
- Config editor help text updated to use the unified
npx @cortexkit/magic-context@latestinvocation instead of older Bun-specific commands.
Upgrade
- The dashboard auto-updater handles this release for users already on
dashboard-v0.4.0or later. - Users still on
dashboard-v0.3.4need to download once manually because of the GitHub Pages updater URL change shipped indashboard-v0.4.1. Auto-updates resume after the manual download.
Full Changelog: dashboard-v0.4.1...dashboard-v0.4.2
v0.16.3
Critical Electron compatibility fix
OpenCode 1.14.x stable shipped on Electron 41 (NODE_MODULE_VERSION 145), which rejects the better-sqlite3 Node ABI 137 prebuild that ships with Magic Context. Without this fix, Magic Context disables itself on OpenCode Desktop entirely. If you're on Desktop and saw the plugin silently stop working, this release fixes it.
This release also moves the unified CLI fully onto npx, drops a 1.5s-per-transform HTTP round trip on large sessions, and tightens a few install-flow rough edges.
Upgrade
npx @cortexkit/magic-context@latest doctor --force--force clears OpenCode's cached plugin install so it picks up the new bundle on the next launch. Dashboard users should also run this to refresh the cached plugin used by the Magic Context tray.
What's Fixed
-
Electron Desktop:
better-sqlite3ABI mismatch resolved. Magic Context now detects Electron at plugin init, fetches a matching ABI 145 prebuild from the officialWiseLibs/better-sqlite3GitHub release on first run, and caches it under~/.cache/cortexkit/native-bindings/. Subsequent restarts use the cache. The bundlednode_modules/.../better_sqlite3.nodeis never modified — Pi (Node) and OpenCode TUI (Bun) keep using the binary they need. Implementation usesbetter-sqlite3's documentednativeBindingconstructor option, norequire.cacheornode_modulesmanipulation. Verified live on OpenCode 1.14.37 / Electron 41.2.1 with both fresh-download and warm-cache paths. -
Transform latency on large sessions cut by ~1.5s per pass. Magic Context's transform was calling
client.session.get(...)on every pass to resolve the session's project directory — an HTTP round trip through OpenCode's local API that took 1.5s+ for long sessions under Electron. Sincesession.directoryis set at session create time and never changes, the result is now cached in-process for the session's lifetime; subsequent transforms use a sub-microsecond Map lookup. Most visible on Desktop with sessions in the tens of thousands of tagged messages.
What's Changed
-
CLI invocation:
npx-only. The unified CLI now consistently recommendsnpx @cortexkit/magic-context@latest <command>everywhere — install scripts, README,CONFIGURATION.md, doctor self-help text, plugin warnings, TUI sidebar, dashboard, and the bug-report template. Two recurring issues drove this:bunx --bunfroze undercurl | bashbecause Bun's TTY handling doesn't deliver keypress events through a fresh/dev/tty, so the historian-model picker hung on first install.- The plugin auto-update checker was running
bun installeven though OpenCode itself uses npm to manage plugins, generating a parallelbun.lockthat drifted from OpenCode'spackage-lock.json. The checker now runsnpm install --no-audit --no-fund --no-progressand cleans both modern and legacypackage-lock.jsonshapes.
Bun is still fully supported as a runtime —
bunxworks fine, the docs just don't actively recommend it anymore. Node 20.12+ is required (Clack prompts depend onnode:util.styleText).
Notes
- No config changes required; existing
magic-context.jsoncfiles continue to work. - No data-migration changes; the SQLite schema is unchanged.
- The first plugin load on Electron Desktop will spend ~1-2 seconds downloading the matching
better_sqlite3.node(~950 KB) from GitHub. Subsequent launches are instant — they use the cached binary.
v0.16.2
System prompt control + cross-host dreamer fixes
This release adds per-agent control over Magic Context's system-prompt injection, fixes a long-standing bug where the dreamer queue could leak across projects, and stops historian/dreamer/sidekick subagent prompts from rendering as huge visible messages in the TUI.
What's New
-
Per-agent opt-out for system-prompt injection (#53, #42). New top-level
system_prompt_injectionconfig lets you exclude specific agents from receiving the## Magic Contextguidance block.skip_signaturesis just a list of substrings — if any one of them appears anywhere in an agent's system prompt, that agent is opted out for that turn.Two ways to use it:
"system_prompt_injection": { "enabled": true, // set to false to disable injection globally "skip_signatures": [ // Option 1 — match a unique phrase that's already in the agent's prompt // (e.g. opt out the Council orchestrator from omo-slim): "You are the Council agent — a multi-LLM", // Option 2 — drop a marker into your own custom agent's prompt and // match it here. The exact marker text is up to you; this is just // an example convention: "<!-- magic-context: skip -->" ] }
This is useful when you've denied tools for a specific agent (so the LLM isn't told to use tools it can't access) or when you want a clean prompt surface for orchestrators like
council. Empty signature strings are filtered out defensively so a misconfiguration can't silently disable injection globally.
What's Fixed
-
Magic Context guidance no longer injected into OpenCode's internal small-model agents (#52). The
title,summary, andcompactionagents have a fixed single-shot job, no tools, and don't benefit from any of the magic-context block — they were just paying the token cost. Detection is signature-based on each agent's distinctive prompt opener, and the system-prompt hash is no longer updated for these calls so they don't trigger spurious cache busts on subsequent main-agent turns. -
Subagent prompts no longer render as 90k-character visible user messages in TUI (#50 part 2). Historian, dreamer, sidekick, compressor, and user-memory-review all build large internal prompts containing existing-state XML, raw transcripts, and instructions. These were being sent as ordinary text parts and showing up as massive unreadable user messages in OpenCode's subagent pane. The text now uses OpenCode's
synthetic: trueflag so the LLM still receives the full prompt body but the TUI skips rendering — same mechanism OpenCode uses internally for plan-mode prompts and auto-compaction summaries. -
Dreamer no longer runs scheduled cycles for projects you never opened. The shared
dream_queuetable is process-global (OpenCode and Pi both write to it), but each running host only knows about its own registered project's filesystem path and harness-specific runner. Without a project filter, a Pi process running for project A would dequeue queue entries for unrelated projects B, C, D... and try to dream them with Pi's runner — failing every cycle withposix_spawn 'pi': ENOENTbecause the spawn cwd fell back to the literalgit:<sha>identity string. Both ends are now project-scoped:processDreamQueueandcheckScheduleAndEnqueueaccept the calling host's project identity and only operate on entries that belong to it./ctx-dream(manual) is also project-scoped. If you previously saw consistently failed dream runs in the dashboard for projects you never opened in that harness, this is the fix. -
doctorno longer destroys tuple-form plugin entries on save. OpenCode allows plugin entries in two forms: a bare string"@pkg/name"or a tuple["@pkg/name", { ...options }]for plugin-specific config. The unified-CLI'sdoctor-opencode.tswas filteringconfig.pluginto strings only before writing back, silently dropping the tuple options every time it saved the config;setup-opencode.tswas throwing TypeError on tuple entries entirely. Both now use the sharedmatchesPluginEntryhelper from the OpenCode adapter so tuples preserve their options end-to-end. -
Regressions in unified-CLI ports of earlier fixes, all caught when comparing the new
packages/cli/paths against the corresponding plugin-side helpers:- The Windows cache path fix from v0.15.1 (
%LOCALAPPDATA%-vs-~/.cache) was reintroduced in the unified CLI'spaths.ts. Restored here sodoctor --forceagain clears the correct OpenCode plugin cache on Windows. - The dev-path plugin entry detection from v0.16.1 was reintroduced in
doctor-opencode.ts's inline matcher and missed baremagic-contextpaths after the repo rename. Bothdoctorandsetupnow use the shared adapter matcher and leave dev-path entries (file://, absolute, relative) alone end-to-end.
- The Windows cache path fix from v0.15.1 (
-
doctor-pi.tsconflict check no longer hardcodes a "no conflicts detected" pass. The check was unconditionally emitting a green pass with no detection logic. It now actually scans the Piextensionsarray for duplicate magic-context entries and dev-path-plus-npm-entry mismatches, the same shape OpenCode's check has always had. -
GitHub release job now blocks on npm publish success.
release.yml'sgithub-releasejob depended only on the test gates, so a transient npm-publish failure could leave a published GitHub release page with no corresponding npm packages. Nowneeds:includes all three publish jobs (publish-npm,publish-npm-pi,publish-npm-cli) so the release page only goes live after npm has accepted the upload. -
Dashboard release script no longer wipes the entire
gh-pagesbranch on every release. The deploy-updater step hadforce_orphan: true+keep_files: false+publish_dir: .plus aninclude_filesinput that doesn't exist onpeaceiris/actions-gh-pages@v4and was silently ignored. Every dashboard release was force-pushing the whole repo as a single orphan commit. Replaced with a staging directory +keep_files: trueso onlylatest.jsonupdates incrementally. Also replaced the hardcoded 30-secondsleepwith a 20×15s retry loop that fails fast on missing artifacts.
Upgrade
bunx --bun @cortexkit/magic-context@latest doctor --forceForce is recommended once after upgrading from 0.16.1 because the previous release pinned cache state into your OpenCode plugin cache that this release supersedes. Without --force, OpenCode may keep loading the cached 0.16.1 plugin even after npm updates.
v0.16.1
Unified CLI: one command for both harnesses
The setup and doctor commands have been consolidated into a single @cortexkit/magic-context package. Instead of running per-plugin binaries, you now use one CLI that auto-detects which harnesses you have installed (OpenCode, Pi, or both) and dispatches to the right pipeline.
# Auto-detects installed harnesses
bunx --bun @cortexkit/magic-context@latest setup
# Or target a specific harness
bunx --bun @cortexkit/magic-context@latest doctor --harness opencode
bunx --bun @cortexkit/magic-context@latest doctor --harness piThe plugin packages (@cortexkit/opencode-magic-context, @cortexkit/pi-magic-context) are now runtime-only — they no longer ship CLI binaries. About 7,100 lines of duplicated CLI logic across the two plugins were collapsed into a shared adapter pattern.
What's New
-
@cortexkit/magic-context— new unified CLI package withsetup,doctor, anddoctor migratecommands. Auto-detects installed harnesses; pass--harness opencodeor--harness pito target a specific one. The piped install scripts (install.sh,install.ps1) and the in-app conflict warnings now point at this single CLI. -
Doctor checks aligned across both harnesses. OpenCode doctor gained the checks Pi already had: CLI version vs npm latest,
magic-context.jsoncJSONC parse + schema-load validation, shared SQLite DB existence +PRAGMA integrity_check+ per-table row counts. Pi doctor gained the historian-debug-dumps inspection. Both now report aPASS X / WARN Y / FAIL Zsummary line so results scan at a glance. -
Discord — Magic Context now has a Discord server. Drop in for help, feature discussion, or release coordination.
What's Fixed
-
Local dev-path plugin entries are no longer overwritten by
doctor. Previously, an entry like/Users/.../opencode-magic-context/packages/pluginin your OpenCode config would be silently replaced with@cortexkit/opencode-magic-context@latest, swapping the developer's local plugin instance for the published version. Doctor and setup now recognize dev-path entries (file://, absolute paths, relative paths) and leave them alone — even under--force. Affected entries are logged asPlugin registered (dev path: ...)so it's clear they were detected. -
comment-jsonrestored as a plugin runtime dependency. The CLI restructure inadvertently droppedcomment-jsonfrom the OpenCode and Pi plugin packages, even though the TUI config helper, auto-update checker, and Pi config loader still import it at runtime. Local builds masked the regression because workspacenode_modulesstill resolved it; CI and fresh installs hitCannot find module 'comment-json'at typecheck and load. Restored on both plugin packages with version pinned to^4.2.5across the workspace. -
better-sqlite3properly externalized from the CLI bundle so the unified CLI works under Node without trying to bundle a native module. Declared as a runtime dependency on the CLI package and marked external in the build. -
Docker E2E images updated for the unified CLI so the test pipeline exercises the same code path users run. Both Dockerfiles now COPY the CLI dist, install it with build tools available, and symlink the binary into
/usr/local/bin/magic-context.
Upgrade
bunx --bun @cortexkit/magic-context@latest doctor --forceThis installs the new unified CLI and runs doctor against your installed harnesses. The runtime plugin entries in your opencode.json[c] (@cortexkit/opencode-magic-context) and Pi settings (@cortexkit/pi-magic-context) are unchanged — those are the runtime plugin packages, separate from the CLI.
If you previously had bunx --bun @cortexkit/opencode-magic-context@latest setup or magic-context-pi setup aliased anywhere, switch to:
bunx --bun @cortexkit/magic-context@latest setupFull Changelog: v0.16.0...v0.16.1
v0.16.0
Cross-harness Magic Context — Pi support is here
This release introduces support for the Pi coding agent as a second harness. The same SQLite database, project memories, embeddings, dreamer state, and key-file pins are now shared across OpenCode and Pi — write a memory in OpenCode, retrieve it in Pi (and vice versa), all from the same ~/.local/share/cortexkit/magic-context/context.db.
Per-session state (tags, compartments, facts, notes) stays correctly attributed to its originating harness via a new harness column.
Pi support is published as beta. Core flows (tagging, historian, memories, dreamer,
/ctx-aug) are validated end-to-end on both interactivepisessions andpi --print --mode jsonsubagents. Please report issues — every Pi-side rough edge is fixable.
What's New
-
@cortexkit/pi-magic-contextPi extension (beta) — install withpi install npm:@cortexkit/pi-magic-contextor via the setup wizard. Requires Pi>= 0.71.0. Ships with the same five/ctx-*slash commands as the OpenCode plugin (/ctx-status,/ctx-flush,/ctx-recomp,/ctx-dream,/ctx-aug) and the same agent-facing tool surface (ctx_search,ctx_memory,ctx_note). -
Shared cross-harness SQLite database at
~/.local/share/cortexkit/magic-context/context.db. The plugin database moved out of OpenCode's per-plugin storage path so both harnesses can pool memories, embeddings, dreamer runs, and key-file pins by project identity. On first launch after upgrading, the OpenCode plugin auto-copies its existing database (and WAL/SHM sidecars + embedding model cache) to the new path; the legacy location is left untouched as a backup. -
Runtime-detected SQLite backend so the same plugin code runs under Bun (
bun:sqlite) and Node (better-sqlite3). This unblocks the Pi extension (Pi runs on Node) without forking the storage layer or losing the OpenCode/Bun code path. -
Cross-harness scope discipline — memories, embeddings, and dreamer state are scoped by
project_path(resolved git root) so both harnesses see the same project knowledge. Tags, compartments, session facts, and notes are scoped by(harness, session_id)so per-session state stays correctly attributed. -
Dashboard now treats harness as a first-class dimension — sessions, cache events, and per-session stats are keyed by
(harness, session_id). Pi sessions show alongside OpenCode sessions with harness badges and filter chips; the Memories page picks up Pi-originated writes automatically.
What's Fixed
-
Tuple-form plugin entries no longer trigger false conflict warnings (#49). The conflict detector previously assumed every
pluginarray entry was a string and silently failed on tuple form like["@pkg/name", { ...options }]. It now extracts the package name from tuple entries before matching. -
TUI presence detection no longer goes stale (#50). The internal
tuiConnectedflag was set once and never reset, so server-side notifications kept routing through the TUI even after the user closed it. Replaced with a recent-drain timestamp check, plus a fallback so failedshowToastcalls now flow through to the ignored-message path instead of being swallowed. -
/ctx-dreamno longer gets stuck after a crashed dream worker. Manual/ctx-dreaminvocations now force-clear stalestarted_atrows from the dream queue once the lease TTL has passed, so explicit user requests can always proceed. -
Plugin database path uses session directory, not launch directory. Project identity now resolves from the actual session directory (via the session's stored
directoryfield) instead of the plugin's startupcwd. This fixes a class of bugs where launchingopencodefrom outside the project root attached memories/dreamer state to the wrong project.
Upgrade
bunx --bun @cortexkit/magic-context@latest doctor --forceAfter upgrading, your existing OpenCode database is automatically copied to the new shared ~/.local/share/cortexkit/magic-context/ path on first plugin load. The old path is left in place as a backup.
To install the Pi extension:
bunx --bun @cortexkit/magic-context@latest setup --harness piFull Changelog: v0.15.7...v0.16.0
Dashboard dashboard-v0.4.1
Hotfix: auto-update endpoint repaired
The dashboard-v0.4.0 build shipped with a stale auto-updater endpoint pointing at the old repository's GitHub Pages URL (cortexkit.github.io/opencode-magic-context/...). After the repo was renamed to cortexkit/magic-context, GitHub stopped serving anything at the old URL — every dashboard install was silently polling a 404 on every startup, leaving v0.4.0 frozen with no auto-update path.
This release fixes the endpoint to the live URL (cortexkit.github.io/magic-context/...). Once you're on dashboard-v0.4.1, future updates land automatically as usual.
v0.3.4andv0.4.0users need a one-time manual download. The dead URL is baked into those binaries; nothing the server can do reaches them. Downloadv0.4.1from this release page, then auto-update will work for all subsequent versions.
What was actually in v0.4.0 (still ships in v0.4.1)
dashboard-v0.4.0 was deleted before promotion, so this release also delivers everything that was in v0.4.0:
-
Cross-harness Pi support — Pi sessions, cache events, and per-session stats now show alongside OpenCode in every dashboard view, keyed by
(harness, session_id). Harness badges and filter chips throughout. The Memories page picks up Pi-originated writes automatically (memories are project-scoped and shared across both harnesses). -
Cache page polish — toolbar layout fixed, cache-row titles ellipsize properly when long, per-session cache stats correctly resolve to the originating harness.
-
Sessions / Config / Memories cleanup — nine reported polish items: layout corrections, missing harness columns wired through the backend, project-picker filter for memories, and a handful of UI bugs across the cache, sessions, config editor, and memory browser views.
Upgrade
Download from this release page and replace your existing app — the auto-updater can't carry you over from a binary with the dead endpoint.
After v0.4.1 is installed, future dashboard releases auto-update normally.
Full Changelog: dashboard-v0.3.2...dashboard-v0.4.1
v0.15.7
What's Fixed
-
Tagger no longer cascades into repeated cache busts when its internal counter drifts behind the tags table's actual max tag number. Previously, once divergence occurred (from earlier outer-transaction rollback, multi-process race, or non-monotonic counter upsert), every transform pass would propose an already-claimed tag number, hit a UNIQUE collision, abort tagging, and skip the persisted-drop / reasoning-clear / caveman-compression replay — resurrecting tens of thousands of stripped tokens and forcing a full provider-cache miss on every affected turn. The tagger now reads the live DB max on every allocation and walks past collisions automatically, so a brand-new pass on a divergent session self-heals in milliseconds without any user intervention.
-
Counter upsert is now monotonic. Concurrent writers (multiple OpenCode instances, or sessions in different processes) can no longer move a session's counter backward, so a stale low writer cannot undo state from a higher writer that already advanced past it.
-
Existing divergent sessions heal automatically on first startup after upgrading. A one-shot migration brings every session whose
MAX(tag_number) > counterback into sync. Cheap, idempotent, and runs once — fresh DBs and already-healthy sessions are unaffected. -
One tagging failure no longer rolls back the whole transform pass. Per-call atomicity is preserved through SAVEPOINTs while the outer wrapper is removed, so a single isolated collision can no longer leave the pass with empty tag targets and skipped drop/reasoning replay.
Upgrade
bunx --bun @cortexkit/opencode-magic-context@latest doctor --forceAfter upgrading to v0.15.7, divergent sessions self-heal on next plugin load. If you were seeing repeated cache busts after long idle gaps or multi-process activity on the same project, this release closes that path.
Full Changelog: v0.15.6...v0.15.7