Releases: cortexkit/magic-context
v0.30.1
v0.30.1
A patch release fixing local embeddings on OpenCode Desktop.
Fixes
- Local embeddings work on OpenCode Desktop (#195).
/ctx-embedfailed on the Desktop app withUnsupported device: "cpu". On Electron, Magic Context supplies its own WebAssembly ONNX runtime (to bypass a native-module load failure), but that made@huggingface/transformersskip its device registration, so every device selection threw. The embedding pipeline now selects the runtime explicitly on that path, and resolves the local WASM assets correctly instead of falling back to a remote URL. Local embeddings load and run on Desktop again. Thanks to @Treeed for the precise, source-grounded report.
v0.30.0
v0.30.0
Setup and doctor now recognize OpenCode Desktop installs that have no CLI, the TUI sidebar badge matches your theme again, and the doctor plugin-cache check is more reliable. Also a dependency refresh (newer OpenCode and Pi SDKs) and security updates.
Fixes
- Setup and doctor recognize OpenCode Desktop without a CLI (#196). Installing OpenCode only through the Desktop app leaves no
opencodebinary on PATH (its server runs inside Electron), so setup reported "OpenCode not found" and refused to continue, and model discovery came up empty. Setup and doctor now detect a Desktop-only install and continue with manual model entry instead of claiming OpenCode is absent. A stock CLI installed outside PATH (for example under a version manager) is also found and used for model discovery. Thanks to @Treeed for the report. - TUI sidebar badge color follows your theme again (#198). On dark themes the Magic Context badge rendered white text while sibling badges (such as AFT) rendered the theme's own background color, so the two looked inconsistent. The badge now uses the theme background like the others, with a safety fallback for transparent-background themes so the label can never disappear. Thanks to @null-axiom for the report.
doctorclears a stale plugin cache reliably (#199). The cache check compared the cached plugin against the CLI's own version rather than the plugin's latest published version, so a stale@latestcache could survive when run through an older cached CLI. It now compares against the plugin's npm-latest, clears the versionless cache root as well, and preserves the cache (rather than clearing it) when the version check is offline. Thanks to @coleleavitt for the fix.
Maintenance
- Refreshed dependencies and resolved several security advisories, including newer OpenCode (
@opencode-ai/plugin,@opencode-ai/sdk) and Pi (@earendil-works/pi-coding-agent,@earendil-works/pi-tui) SDKs.
Dashboard dashboard-v0.9.1
Dashboard v0.9.1
A patch release fixing model discovery for pnpm-installed OpenCode on Windows.
Fixes
- Finds a pnpm-installed OpenCode CLI on Windows (#149). pnpm places global binaries at
%LOCALAPPDATA%\pnpm\bin\opencode.cmd, which is not on the GUI process's PATH and was not in the set of locations the dashboard checks, so model dropdowns came up empty for pnpm users. That path (and the pnpm store location) is now included, so the dashboard discovers and queries a pnpm-installed OpenCode. Verified on Windows. Thanks to @nielpattin for the report and diagnosis.
Maintenance
- The updater manifest now pins download URLs to each release tag, so Desktop auto-update keeps working regardless of which package release is GitHub's "latest" (the earlier broken manifest was already corrected in place).
Dashboard dashboard-v0.9.0
Dashboard v0.9.0
Adds a browser mode so the dashboard works on Linux and WSL2 setups where the desktop window comes up blank, and recognizes OpenCode Desktop installs that have no CLI.
Features
- Browser mode (
--serve). On some Linux distributions and under WSL2 the desktop window opens blank (often withCould not create default EGL display) because the bundled WebView cannot start against the host's graphics stack. The same binary can now run as a local web server instead:magic-context-dashboard --serveprints a URL (with a one-time access token) that you open in your normal browser, bypassing the embedded WebView entirely. It binds127.0.0.1:9077by default;--serve <port>changes the port, and--host 0.0.0.0 --allow-remoteexposes it to other machines (off by default, behind an explicit flag, since the dashboard can read transcripts and edit config). See the dashboard docs.
Fixes
- Recognizes OpenCode Desktop installs without a CLI (#196). Installing OpenCode only through the Desktop app leaves no
opencodebinary to query, so model dropdowns came up empty with no explanation. The dashboard now detects a Desktop-only install and lets you type a model id manually, with a hint explaining why auto-population is unavailable. A stock CLI installed outside PATH is also found and used.
Maintenance
- Pre-release hardening:
--serveAPI responses are markedno-store, and Desktop detection has more robust path fallbacks when environment variables are unset.
v0.29.1
v0.29.1
A small patch release: fixes a multi-project Desktop warning, a tool-call edge case for GPT-family models, and simplifies an internal nudge path.
Fixes
- No more
MaxListenersExceededWarningon OpenCode Desktop with several projects open. Each plugin instance was registering its own process-exit listener; past Node's 10-listener default this logged a warning. All instances now share a single exit listener. ctx_notedefaults to read correctly for GPT-family models. Models that fill every optional parameter (sendingcontent: ""for a read) madectx_noteinfer a write and reject the empty content. It now infers write only on non-empty content.- Pi resolves OpenAI and Google models from a shared OpenCode/Pi config. OpenCode and Pi name a few providers differently (
openaivsopenai-codex,googlevsgoogle-antigravity); a model configured in one harness' form is now translated automatically so the same shared config works on both. Anthropic and other providers were already identical. - Dreamer "last run" time is accurate again (#194). After upgrading to Dreamer V2, the sidebar and
/ctx-statusshowed a frozen timestamp from the old V1 dream cycle even though V2 tasks were running nightly. They now read the most recent task run, so the displayed time tracks real execution. Thanks to @wjiuxing for the precise report.
Internal
- Channel 2 ceiling nudges now deliver through the in-process client OpenCode hands the plugin instead of a separate live-server client + reachability probe (the upstream duplicate-runner bug the workaround guarded against is fixed in OpenCode ≥ 1.17.7). As a side effect they also work on plain TUI now.
- Removed dead code and a circular import (
storage-db↔migrations) surfaced while dogfooding our code-health tooling.
Dashboard dashboard-v0.8.3
Dashboard v0.8.3
Fixes
- OpenCode model dropdowns no longer hide your configured providers. Model discovery briefly used
opencode --pure models, which skips external plugins and so omitted providers registered by auth plugins (e.g.anthropic,google). The pickers now use the fullopencode modelslist, restoring every provider you have set up. - Wider model pickers. The model selectors (and the "Add fallback model" dropdown in particular) were cramped and wrapped their options. They now fill the column.
- Cleaner Cache Diagnostics. Removed the combined "Show all" view: the page always focuses a single session's cache timeline instead of merging every session into one chart, which made the numbers confusing. A session is always selected; clicking a card focuses it.
Maintenance
- Updated the Tauri stack to the latest 2.x and refreshed dependencies, resolving several security advisories.
Dashboard dashboard-v0.8.2
Dashboard v0.8.2
New
- Primer candidates are now visible. The Primers page shows a read-only Candidates section beneath the promoted primers: standing questions the historian has recorded that have not yet recurred often enough to be promoted. Previously the page looked empty until a primer was promoted, even when candidates were accruing. The empty state now explains the recurrence requirement, so the page is self-describing.
v0.29.0
v0.29.0
Adds smart drops (opt-in): content-aware reclaim that frees more context on long, edit-heavy sessions by dropping tool output a later call has made obsolete, instead of only the oldest output. Also stops the nightly docs maintainer from flattening hand-written ARCHITECTURE.md / STRUCTURE.md, and unifies commit detection so its three call sites can't drift apart.
Features
-
smart_drops: reclaim superseded tool output, not just the oldest (opt-in, default off). The normal auto-drop reclaims the oldest tool outputs first when a session gets long. Smart drops adds reclaim by supersession: output that a later call has made obsolete, regardless of age:- Superseded edits are the big one. When you edit the same file more than once, the older edits' full diffs are dead weight, but dropping them entirely loses the record that the file was touched. Smart drops keeps the newest edit in full and compresses each older edit to a marker that preserves its
filePathand a short hint of the region, so the agent still sees which file and region it changed. - Spent control-plane output: older
todowritesnapshots (the live task list is kept), olderctx_reducecalls (the most recent few are kept), and zero-value status output (bash_status,bash_kill,ctx_notereads) are dropped once superseded.
It only ever acts during a transform pass that is already rewriting the message array, so it never causes a prompt-cache miss on its own, and every drop uses the same deterministic placeholder as the normal drops so cached turns stay byte-identical. When
smart_dropsis off (the default), the messages sent to the model are byte-for-byte identical to previous versions: the whole feature is inert until you turn it on. Enable it with"smart_drops": true(it's also a toggle in the dashboard's Advanced config). It's experimental and stays off by default while cache stability is validated in the wild; if you run long, edit-heavy sessions and want to reclaim more context, it's worth turning on. One note: once enabled, every binary that shares your Magic Context database (multiple OpenCode instances, or OpenCode + Pi) should be on this release or newer. - Superseded edits are the big one. When you edit the same file more than once, the older edits' full diffs are dead weight, but dropping them entirely loses the record that the file was touched. Smart drops keeps the newest edit in full and compresses each older edit to a marker that preserves its
Fixes
-
The nightly docs maintainer no longer flattens hand-written architecture docs. The
maintain-docsdreamer task was rewriting dense, hand-authoredARCHITECTURE.md/STRUCTURE.mdinto its generic boilerplate template, dropping hard-won detail (invariants, edge cases, subsystem specifics) even though only a few sections had actually drifted. It now treats an existing doc as the source of truth for shape: it makes the smallest edits that re-sync the changed sections with the code and preserves the existing structure, depth, and voice, rather than regenerating the whole file. The creation-from-scratch templates are unchanged. -
Commit detection unified across its three call sites. The historian's commit-cluster trigger, the note-nudge "a commit just happened" boundary, and the Pi note detector each carried their own hash + keyword patterns that had quietly drifted apart (different hash lengths, different keyword sets). They now share one definition, so a commit is recognized consistently everywhere.
-
With
memory.enabled: false, thectx_memorytool and its guidance are no longer presented. Previously, even with memory off, the agent was still given thectx_memorytool and told to "save to memory proactively", but with memory off the<project-memory>block is never injected, so anything it wrote could never resurface, making those writes silent busywork. The tool and all its guidance are now omitted when memory is off.ctx_searchstays available (it still searches your conversation history and indexed git commits, just not memories). -
Fixed a crash in the WASM sandbox that runs compiled smart-note checks. When two projects' nightly smart-note sweeps overlapped (common at multi-project startup), the shared sandbox could throw
QuickJSUseAfterFree: Lifetime not aliveand fail the check. Sandbox runs are now serialized, so a check that pauses for a file read or network request can no longer corrupt a concurrent one. -
Pi: the
ctx_memorytool now stays consistent when you switch projects. In a single Pi session that moves between projects (one with memory enabled, one without), the tool could end up registered for the wrong project's setting. It is now always registered and gates per-project at call time, matching what the prompt advertises for the current project.
Docs
- Added Chinese (Simplified & Traditional), Korean, and German README translations.
Dashboard dashboard-v0.8.1
Dashboard v0.8.1
A focused fix release: the embedding Test Connection button now works for the two setups it was wrongly rejecting, plus a couple of smaller config and discovery fixes.
Fixes
-
Test Connection (user config) now works with
{file:...}/{env:...}keys. If your user-levelembedding.api_keyused a{file:~/...key}or{env:VAR}reference (the recommended way to keep secrets out of the config file), Test Connection refused it with a confusing message about an environment variable not being set, even for file references. It now resolves these tokens exactly like the plugin does at runtime, so the test uses your real key. Unresolved references (a missing file, or an env var the desktop app didn't inherit) are reported with accurate, kind-specific guidance, and a{file:...}that points into a credential directory (~/.ssh,~/.aws,~/.gnupg,~/.config/gh) is refused on purpose, including via..traversal or symlinks. -
Test Connection now accepts
http://and local endpoints. A self-hosted embedding server athttp://127.0.0.1:1234/v1(LM Studio, Ollama, llama.cpp, and similar) was rejected with "Endpoint must start with http:// or https://" even though it clearly did, because the check was HTTPS-only. Bothhttp://andhttps://are now accepted, and loopback / private-LAN addresses are allowed so local servers can be tested. Cloud instance-metadata addresses stay blocked. -
Test Connection is limited to user config. The embedding section (provider, endpoint, API key, and the Test button) is now hidden when editing a project config. Project configs are shared repository files, and the plugin already ignores an embedding endpoint set there, so testing one was both pointless and a way for a shared repo to direct a key at an arbitrary endpoint. Embedding setup stays in your user config; project configs keep their own settings (like the per-project memory toggles).
-
Model discovery no longer spins up unrelated daemons. The config page's model dropdowns run
opencode --pure models, so opening the page no longer boots other OpenCode plugins (and the background processes some of them spawn).
Config editor
- New
languagefield ("Output Language") in the config editor, matching plugin v0.28.0+: set a 2-letter ISO 639-1 code (e.g.tr,es,de,ja) to keep Magic Context's generated prose in your language; leave it blank for today's behavior. - New
smart_dropstoggle in Advanced config, matching plugin v0.29.0.
Compatibility
Pair this dashboard with plugin v0.29.0 for the smart_drops toggle and the matching config schema. The language field works with plugin v0.28.0 and newer.
v0.28.0
v0.28.0
Adds a language option so non-English sessions stay in your language instead of drifting back to English, and fixes the ctx_reduce reminder so it reflects how much is actually reclaimable rather than just how close you are to compaction.
Features
language: keep generated text in your language (#192). All of Magic Context's generated prose (historian summaries, dreamer memories, primers, the sidekick) and its guidance was English-only, so long non-English sessions slowly drifted back toward English. Set a top-levellanguageto a 2-letter ISO 639-1 code (for example"language": "tr"or"language": "es") and Magic Context writes its prose in that language while keeping everything structural in English exactly as before: XML tags, JSON keys, the memory category names, tool names, code, file paths, and transcript markers. Memory migration is deliberately language-preserving: turning the option on does not translate memories you already have, it only changes the language of newly written text. The option is user-level only (a project config cannot set it), defaults to off, and when unset the output is byte-for-byte identical to previous versions.
Fixes
-
The
ctx_reducereminder no longer jumps to "urgent" just because you are near compaction. The reminder's severity multiplied the reclaimable share by a pressure term, and because of how that term was defined it effectively counted pressure twice and was unbounded past the execute threshold. The result: once a tool-heavy session approached compaction, the reminder escalated straight to its most urgent wording regardless of how much was actually reclaimable. Pressure is now a gate (the reminder only fires once you are genuinely close to compaction), and the level reflects the real reclaimable share: roughly a fifth of your live input being unreduced tool output is a gentle mention, around two fifths is firmer, and only a clear majority is urgent. -
The reminder no longer suggests dropping the agent's task list or trivially small outputs. The hint of what could be reclaimed picked the oldest tool outputs with no regard for kind or size, so it could point the agent at its own
todowritetask list (never a useful thing to drop) or at tiny control-plane calls (a 30-token status line) that reclaim nothing. It now skipstodowriteand anything below a small token floor, surfacing only outputs whose removal actually frees meaningful space.