Skip to content

Locus v4.0.0 — Multi-Platform Zero-Call Desktop Plugins

Latest

Choose a tag to compare

@Magnifico4625 Magnifico4625 released this 27 Nov 08:18
· 1 commit to main since this release

Locus v4.0.0 Release Notes

v4.0.0 introduces multi-platform zero-call persistent memory plugins across Codex CLI/Desktop, Antigravity Desktop, and DeepSeek Harness Desktop (dsh), built on a single shared SQLite/MCP core.

It carries forward Track C richer conversational recall and Track D Codex memory reliability (memory_calendar, memory_project_state, project-scoped temporal recall, candidateGroups), and adds automatic workspace-gated context briefs, background turn capture, a Markdown daily memory journal, and bounded raw tool compaction.

Added

  • Shared v4 runtime & core foundations (@locus/core, @locus/shared-runtime):
    • Cross-platform Windows/POSIX path identity normalization (\\?\, UNC, file:// drive-letter handling, trailing slash canonicalization).
    • Multi-client detection (codex, claude-code, antigravity, dsh, generic) and shared ~/.locus/bin/ runtime sync (locus-memory sync-runtime, locus-memory context).
    • WorkspacePool with MCP roots/list dynamic project switching and node:sqlite SQLITE_BUSY retry backoff.
    • Zero-call auto-brief engine for SessionStart Project Briefs and targeted prompt-turn Relevant Recall without requiring explicit MCP calls on every turn.
  • Antigravity Desktop native plugin bundle:
    • locus-memory install antigravity / doctor antigravity / uninstall antigravity targeting ~/.gemini/config/plugins/locus-memory/ (and customizable --target).
    • Native plugin.json, root hooks.json (SessionStart, PreInvocation, PostToolUse, Stop), hooks/locus-hook.mjs, rules/AGENTS.md, skills/locus-memory/SKILL.md, and mcp_config.json.
    • Incremental transcriptPath ingestion on Stop without leaking internal thinking chains.
  • Codex Desktop / CLI zero-call hooks:
    • locus-memory install codex --with-hooks generating ~/.codex/hooks.json and .codex-plugin/plugin.json ("hooks": "./hooks.json").
    • Versionless local runtime hook commands under ~/.locus/bin/cli.js so trusted_hash stability survives future Locus updates.
    • Real SessionStart and UserPromptSubmit hookSpecificOutput.additionalContext injection, incremental Stop rollout JSONL import, and Cyrillic/paraphrase echo deduplication.
  • DeepSeek Harness Desktop (dsh) in-process Cordis plugin (locus-memory-dsh):
    • Separate ESM bundle target dist/dsh-plugin.js (npm run build:dsh-plugin) + locus-memory install dsh / doctor dsh / uninstall dsh.
    • Workspace-gated dynamic ctx.systemPrompt.section, agent/pre-step <system-reminder> injection (source.kind = 'locus-memory'), real-time session/event and tools/result capture, turn/end flush, optional ctx.mcpManager.register('locus', ...), and safe UI link: symlink migration.
  • Strict Workspace Gate & self-injection protection:
    • ~/.locus/config.json (auto / opt-in, includePaths, excludePaths) and .locus.json opt-in marker support while denying home, temp, agent config directories (~/.gemini, ~/.codex, ~/.locus, ~/.claude, ~/.config, ~/.dsh), system directories, and markerless folders.
    • Self-injection filter preventing [Locus Memory — Project Brief] / <system-reminder> / [Locus] payloads from being re-captured into memory.
  • Daily Memory Journal & bounded compaction:
    • Automatic daily_summaries maintenance in SQLite alongside human-readable Markdown notes under journal/YYYY-MM-DD.md and journal/INDEX.md.
    • memory_compact prunes aged raw tool_use rows after syncing daily summaries and runs PRAGMA wal_checkpoint(TRUNCATE) while keeping durable decisions and conversation history intact.

Fixed

  • Normalized file:///C:/... paths and /C:/... drive prefixes consistently on POSIX and Windows across @locus/shared-runtime, WorkspacePool (rootUriToLocalPath), and workspace-gate (normalizeWorkspacePath).
  • Scoped automatic decision-prefix extraction to the first sentence so multi-sentence echoes do not create duplicate durable entries.
  • Made locus-memory-dsh prompt instructions dynamically gated by workspace so non-project folders do not receive stale Locus instructions.
  • Replaced existing node_modules/locus-memory-dsh junctions/symlinks safely during install dsh without deleting or modifying original source link targets.

Validation

  • Full repository check (npm run check):
    • TypeScript typecheck (@locus/core, @locus/codex, @locus/cli): 0 errors.
    • Biome lint & format (biome check .): 310 files checked, 0 errors.
    • Vitest suite (vitest run): 133 test files passed, 1428 tests passed.
  • Build outputs (npm run build, build:antigravity-plugin, build:dsh-plugin, sync:codex-plugin, sync:codex-marketplace):
    • dist/cli.js: 312,345 bytes (<= 400,000 budget).
    • dist/server.js: 1,392,798 bytes (<= 3,000,000 budget).
    • dist/dsh-plugin.js: 163,945 bytes.
  • Local npm tarball smoke (npm pack):
    • locus-memory-4.0.0.tgz packed cleanly with 14 intended files (dist/cli.js, dist/server.js, dist/dsh-plugin.js, Codex skill/README/config, plugin manifests/hooks, docs/releases/v4.0.0.md, README.md, LICENSE).
    • Clean tarball extraction verified package.json version 4.0.0, locus-memory --version = 4.0.0, and isolated install codex --dry-run --yes with LOCUS_CODEX_RUNTIME_PACKAGE=<tgz>.
  • Registry npm package smoke (locus-memory@4.0.0):
    • npm view locus-memory@4.0.0 version returned 4.0.0 (shasum: 3112dea927ce2b2ac12328bce87e656f3b8219ea) and dist-tags.latest returned "4.0.0".
    • Isolated npx --yes locus-memory@4.0.0 --version returned 4.0.0.
    • Isolated npx --yes locus-memory@4.0.0 install codex --dry-run --yes, install antigravity --dry-run, and install dsh --dry-run all resolved 4.0.0 cleanly.
  • Live Desktop E2E verification:
    • Antigravity Desktop native plugin bundle & lifecycle hooks live-verified.
    • Codex Desktop 0.171.0 / 0.172.0 zero-call hooks and cross-session recall live-verified (5/5 PASS).
    • DeepSeek Harness Desktop 44.7.0 (0.2.2-rc.5) in-process Cordis plugin (locus-memory-dsh), dynamic systemPrompt gating, and zero-call cross-session recall live-verified (PASS).

Known Boundaries

  • OpenCode Desktop: In-process OpenCode plugin integration is deferred (design retained in docs/plans/opencode-integration-plan.md).
  • Codex Desktop / extension MCP surface: Codex CLI and Codex Desktop zero-call hooks are live-verified; live Desktop sessions may need a reload to expose updated MCP tool registries, and VS Code extension parity remains dependent on upstream preview builds.
  • Claude Code compatibility: packages/claude-code/** remains unchanged in v4.0.0 to preserve existing Claude Code behavior, and SQLite migrations are strictly additive.
  • Track D follow-ups preserved: LOCUS_CODEX_SURFACE remains a diagnostic/debug override; richer evidence-anchor display and user-configurable topic namespace filters remain future follow-ups.