Skip to content

Releases: cortexkit/magic-context

v0.30.7

Choose a tag to compare

@github-actions github-actions released this 04 Jul 15:20

v0.30.7

Patch release fixing a false recomp failure on Pi-only installs and laying the plugin-side groundwork for a much faster dashboard Projects page.

Fixes

Pi: /ctx-recomp reported failure after succeeding on installs without OpenCode

On machines where Pi runs without OpenCode installed (for example Pi inside a Linux container), /ctx-recomp and /ctx-session-upgrade completed their rebuild and then reported Recomp failed unexpectedly: unable to open database file. The rebuild had actually published; the error came from a post-publish step that tried to open OpenCode's database, which does not exist on Pi-only installs. That step is now skipped on Pi, and a missing OpenCode database can no longer be created as an empty stray file. If you saw this failure, your recomp results were saved — no re-run needed.

Pi: boot log printed executeThreshold=[object Object]% for per-model thresholds

When execute_threshold_percentage is configured as a per-model map, the startup log now prints the resolved values (for example 65% (provider/model=50%)) instead of [object Object]%.

Improvements

Session-to-project index for the dashboard

Reported dashboard Projects page load times of two minutes or more came from the dashboard re-deriving each session's project by running git across every session directory on every load, including directories that no longer exist or live on slow network paths. The plugin now records a durable session-to-project index (a one-time background backfill on first start after upgrading, then kept current automatically), and the upcoming dashboard release reads that index directly instead of running git at all. Sessions whose directories have been deleted are left unindexed rather than guessed. Update both the plugin and the dashboard to get the fast path end to end.

Dashboard dashboard-v0.9.2

Choose a tag to compare

@github-actions github-actions released this 04 Jul 15:22

Dashboard v0.9.2

Performance release: the Projects page no longer runs git at all.

Fixed

Projects page could take minutes to load

The dashboard used to determine each session's project by running git rev-list across every distinct session directory on every page load. On machines with many worktrees, deleted directories, or directories on slow network paths, this made the Projects page take minutes to appear (reported at over two minutes).

The dashboard now reads the session-to-project index that the Magic Context plugin records (plugin v0.30.7 adds a one-time backfill for existing sessions), turning the page into a couple of indexed database reads. Git is never spawned by the dashboard anymore, and a regression test keeps it that way.

One behavior note: sessions that predate the index appear in session lists but are not grouped into project cards until the plugin (v0.30.7+) has started once and completed its background backfill. Update both the plugin and the dashboard for the full effect.

v0.30.6

Choose a tag to compare

@github-actions github-actions released this 03 Jul 12:19

v0.30.6

Patch release with three Pi fixes and quieter background indexing.

Fixes

Pi: sessions could wedge on a synthetic todo pair anchored to an aborted turn

If Magic Context's synthetic todo state was anchored to an assistant turn that had been aborted (for example by pressing Esc mid-response), Pi's provider serializers dropped the tool call half of the pair while still sending its output half. OpenAI-family providers reject that shape, so every subsequent prompt failed with No tool call found for function call output with call_id mc_synthetic_todo_... and the session was stuck. The anchor now always targets a completed assistant turn, and existing sessions recover on their next prompt.

Pi: historian and dreamer runs failed when another extension printed to stdout (#211)

Since v0.30.4, Pi subagents load your full extension set. An extension that writes plain text to stdout (such as a worker announcing [Worker] Ready) interleaved with the JSON event stream Magic Context reads from its subagents, and the whole run was treated as a parse failure. On busy setups this could block compaction entirely, leaving sessions slow and uncompacted. Non-JSON output lines are now skipped.

/ctx-dream: manual runs no longer give up when a scheduled task is finishing

Running /ctx-dream <task> while a scheduled dreamer task held the same work domain reported Busy (already running) even though the requested task was not running. Manual runs now wait up to a minute for the domain to free, and when it stays busy the message explains that another dream task holds it.

Quieter background git indexing

Directories that are not git repositories (or repositories with no commits yet) were retried and logged in full every 15 minutes, flooding the log section of doctor --issue reports. They are now re-checked once a day with a single quiet log line, and start indexing normally as soon as they become real repositories.

v0.30.5

Choose a tag to compare

@github-actions github-actions released this 02 Jul 16:18

v0.30.5

Patch release fixing a Windows-only bug that prevented the Pi historian from ever running, and restoring the dreamer.inject_docs setting.

Pi on Windows: historian and dreamer spawns no longer fail with ENAMETOOLONG

On Windows, every Pi historian, dreamer, and sidekick run failed at spawn with spawn ENAMETOOLONG (#209). The plugin passed the subagent's system prompt — about 60 KB for the historian — as a single command-line argument, and Windows caps the entire process command line at 32,767 characters. The child process never started, so history was never compacted, and long sessions eventually grew past the model's context limit. macOS and Linux were unaffected because their per-argument limits are far higher.

Subagent system prompts are now written to a temporary file and passed to Pi by path, on every platform, so the whole class of command-line size failures is gone rather than patched around. On Windows the user message is also always delivered through stdin, keeping the child's command line small no matter how large the prompts get. Temp files are cleaned up when the run settles, including on spawn failure.

If you are affected: after updating, the historian will start compacting your backlog on its next trigger. Sessions that already overflowed recover once compaction catches up.

Pi: subagents no longer inherit project AGENTS.md / CLAUDE.md

While fixing the spawn path we found that Pi appends project context files (AGENTS.md, CLAUDE.md) to a custom system prompt unless told not to. Magic Context's hidden subagents are focused one-shot workers with purpose-built prompts; your project's agent instructions were being silently appended to all of them. Subagent spawns now pass --no-context-files, so the historian, dreamer, and sidekick receive exactly the prompt they were designed with. You may notice slightly different historian output on Pi as a result — that is the prompt getting cleaner, not a regression.

dreamer.inject_docs: false works again

Setting dreamer.inject_docs to false no longer silently does nothing (#210). When the <project-docs> block moved from the system prompt into the cached history baseline a few releases ago, the setting was left gating the old, retired path — so ARCHITECTURE.md and STRUCTURE.md kept being injected regardless of the config. The flag now gates the real injection site on both OpenCode and Pi. It is independent of whether the dreamer itself is enabled: if you maintain those files by hand but don't want them in context, inject_docs: false now honors that. Changing the setting mid-session takes effect on the next natural context rebuild rather than forcing an immediate one.

v0.30.4

Choose a tag to compare

@github-actions github-actions released this 01 Jul 23:32

v0.30.4

Patch release fixing two issues, one of them breaking historian and dreamer runs for many Pi users.

Pi: historian and dreamer can now use models from provider extensions

Pi subagents (historian, dreamer, sidekick, recomp) were spawned with extension discovery disabled. If your configured model came from a provider extension — Antigravity, Anthropic OAuth, or any other auth extension — every subagent run failed instantly with Model "..." not found, so the historian and dreamer never ran at all. Models defined in models.json were unaffected, which is why this only hit extension-based setups.

Subagent processes now load your extensions, so extension-provided models resolve the same way they do in your interactive session. What changed underneath:

  • Recursion protection moved from disabling all extensions to a targeted guard: the full Magic Context extension detects it is inside a Magic Context subagent and stays inert there.
  • Every subagent now runs under an explicit per-agent tool allow-list. Unknown agents get no tools at all. Extension tools you have installed cannot leak into a subagent that was not meant to use them.
  • Dreamer code-reading tasks (memory mapping, verification, docs maintenance, primer investigation) now get AFT's read-only navigation tools on Pi when the AFT extension is installed, matching OpenCode.

Pi: retrospective and refresh-primers read sessions through the right API

The Pi dreamer's session readers probed an API that does not exist in pi-coding-agent (SessionManager.listSessions), so the retrospective task failed with Pi session APIs unavailable and refresh-primers silently fell back to closed-book seeds. Both providers now share one resolver using the real API (SessionManager.listAll + parseSessionEntries), with tests against the installed package so a future Pi API change fails in CI instead of degrading quietly.

OpenCode: the sidebar entry in tui.json is yours again

The plugin used to re-add its TUI sidebar entry to tui.json(c) on every OpenCode start. If you removed the sidebar deliberately, it came back on the next launch. The entry is now written only by the setup wizard and doctor — removing it from tui.jsonc disables the sidebar permanently.

v0.30.3

Choose a tag to compare

@github-actions github-actions released this 01 Jul 14:01

v0.30.3

A patch release fixing the Pi retrospective dream task, the /ctx-embed loop on oversized compartments, and adding a log-path override.

Fixes

  • Pi retrospective dream task no longer fails silently (#201). On Pi, the retrospective task called pi-coding-agent session APIs that don't exist (SessionManager.listSessions and a public loadEntriesFromFile), so it threw "Pi session APIs unavailable" every run and reported "Skipped (no work)" — meaning Pi users got no retrospective learning at all. It now uses the correct SessionManager.listAll and reconstructs entries via the public parseSessionEntries. Thanks to @kachook for the fix.

  • /ctx-embed no longer stalls on oversized compartments (#206). When a single canonical line inside a compartment (for example a large file dump rendered into one message) was larger than the embedding model's context window, it was sent whole and the provider rejected it — so that compartment could never embed and /ctx-embed reported no progress. Oversized lines are now split down to the window budget before embedding, and empty inputs are coerced to a single space so one blank string can't fail the whole batch. Thanks to @randomvariable for the fix.

Additions

  • MAGIC_CONTEXT_LOG_PATH overrides the diagnostic log location (#183). Set this environment variable to redirect magic-context.log away from the default temp-dir path — useful in Docker/CI where the temp dir is disposable, or to point the plugin and dashboard at a shared file. Blank is treated as unset. Both the plugin and the dashboard log tail honor it. Thanks to @kecsap for the feature.

Docs & internals

  • Documented the system_prompt_injection and keep_subagents config keys, which were in the schema but missing from the configuration reference.
  • Removed the stale compressor config stanza from the configuration docs (the LLM-compressor subsystem was replaced by the decay renderer; the schema already rejected the key, so IDEs flagged it) (#204).
  • Fixed a test-isolation mock leak so the memory test directory passes when run on its own.

v0.30.2

Choose a tag to compare

@github-actions github-actions released this 29 Jun 10:33

v0.30.2

A patch release fixing high idle CPU from the TUI sidebar.

Fixes

  • High idle CPU from the TUI sidebar (#200). The sidebar polled the plugin every 500ms over a localhost connection. Because the TUI and the plugin run in separate runtimes inside the same process, each poll opened a brand-new loopback connection, so an idle session kept burning CPU continuously (a few percent on fast machines, noticeably more on slower ones, and additive when other sidebar plugins were also installed). The sidebar now holds a single persistent WebSocket to the plugin and receives updates the instant they happen, instead of polling. Idle CPU drops back to baseline. Thanks to @null-axiom for the report and the cross-plugin cross-check that pointed at the shared mechanism.

    As part of this, the plugin's detection of whether a TUI is connected is now based on the live connection itself rather than a recent-poll timeout, so server-initiated dialogs (/ctx-status, /ctx-recomp, the upgrade prompt) route to the TUI reliably instead of depending on timing.

v0.30.1

Choose a tag to compare

@github-actions github-actions released this 28 Jun 13:08

v0.30.1

A patch release fixing local embeddings on OpenCode Desktop.

Fixes

  • Local embeddings work on OpenCode Desktop (#195). /ctx-embed failed on the Desktop app with Unsupported device: "cpu". On Electron, Magic Context supplies its own WebAssembly ONNX runtime (to bypass a native-module load failure), but that made @huggingface/transformers skip 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

Choose a tag to compare

@github-actions github-actions released this 28 Jun 08:53

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 opencode binary 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.
  • doctor clears 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 @latest cache 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

Choose a tag to compare

@github-actions github-actions released this 28 Jun 13:20

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).