{"slug": "octomind-a-coding-agent-that-recalls-archived-messages-after-compaction", "title": "Octomind: A coding agent that recalls archived messages after compaction", "summary": "Octomind, a CLI-first AI coding agent runtime from developer Muvon, solved 24 of 25 held-out tasks at lower cost than its closest competitor, according to the project's octobench benchmarks. The MCP-native tool runs interactively, piped through stdin, as a background daemon, over WebSocket, or as an ACP sub-agent, and enforces deterministic guardrails in TOML and scripts rather than approval popups. Octomind also retains task knowledge across long sessions through adaptive compression and supports per-role model selection with per-request and per-session spend thresholds, stopping non-interactive runs with exit code 75.", "body_md": "Pipe it, schedule it, embed it. One binary, any model, MCP-native —\n\nbuilt for autonomous work, not just chat.\n\n[Website](https://octomind.run) · [Docs](https://octomind.run/docs/) · [Tap Registry](https://github.com/muvon/octomind-tap) · [Benchmarks](#benchmarks) · [Issues](https://github.com/muvon/octomind/issues)\n\nOctomind is a CLI-first AI coding agent runtime. It gives an LLM real access to your repo — reading and writing files, running shells, searching code, delegating to sub-agents — through [MCP](https://modelcontextprotocol.io) tools. The same session engine works **interactively**, **piped through stdin**, as a **background daemon**, over **WebSocket**, or as an **ACP sub-agent** inside another agent's stack.\n\n```\n# Interactive\noctomind run developer:general\n\n# Piped — CI, scripts, automation\necho \"Explain the auth module\" | octomind run developer:general --format plain\n\n# Daemon — keep it alive, talk to it from another terminal\necho \"watch the build\" | octomind run --name watcher --daemon --format jsonl\noctomind send --name watcher \"run the test suite\"\n```\n\nMost coding agents assume a human is watching the screen. Octomind is built for the work that keeps going after you leave.\n\n- **Policy as code, not approval popups.** Deterministic[guardrails](https://github.com/Muvon/octomind/blob/master/doc/usage/18-guardrails.md) — pre-call guards, post-result hooks, post-turn validators — live in TOML and scripts, so they work in CI, daemons, and scheduled runs.\n- **Proven on real PRs.** It solved 24 of 25 held-out tasks at lower cost than the closest competitor. See the[benchmarks](#benchmarks) .\n- **Ready-made specialists.**`octomind run developer:general` pulls a packaged agent (prompt, model, MCP servers, tool permissions) from a[tap](https://github.com/Muvon/octomind/blob/master/doc/integration/04-tap-system.md) . Publish your own with one repo.\n- **Sessions that stay sharp.** Adaptive[compression](https://github.com/Muvon/octomind/blob/master/doc/usage/08-compression.md) keeps long tasks moving while retaining task knowledge and the live exchange.\n- **Any model, any budget.** Use Octomind Cloud or your own key (OpenRouter, Anthropic, OpenAI, DeepSeek, Ollama, and more), pick a model per role, and set spend thresholds per request and per session. A request over its threshold stops; at the session threshold a terminal session asks y/N before continuing, while a non-interactive`octomind run` stops with exit code 75.\n- **One config.** Models, tools, roles, guardrails, budgets: all TOML, no framework code.\n\n**1. Install** (macOS, Linux):\n\n```\ncurl -fsSL https://raw.githubusercontent.com/muvon/octomind/master/install.sh | bash\n```\n\nOn Windows, in PowerShell:\n\n```\nirm https://raw.githubusercontent.com/muvon/octomind/master/install.ps1 | iex\n```\n\nOn macOS, you can also install with Homebrew:\n\n```\nbrew install muvon/tap/octomind\n```\n\n**2. Get model access.** The fastest path is Octomind Cloud, which includes models and needs no configuration:\n\n```\noctomind login\n```\n\nPrefer your own provider key? Skip login and export one (also `OPENAI_API_KEY`, `ANTHROPIC_API_KEY`, `DEEPSEEK_API_KEY`), then follow [Model access](#model-access) to point the config at it:\n\n```\nexport OPENROUTER_API_KEY=\"your_key\"\n```\n\n**3. Run a specialist** in your project:\n\n```\ncd ~/your/project\noctomind run developer:general\n```\n\nYou're now in a session with an agent that can read your code, run commands, and edit files. The interface is a plain line prompt with markdown rendering — no TUI to learn, so it works over SSH, in `tmux`, and in CI logs. The first time you run a specialist, it may install its tools and ask for credentials.\n\n`developer:general` comes from the default tap [`muvon/tap`](https://github.com/muvon/octomind-tap), not your local config. Plain `octomind run` starts the config's default role, `assistant:concierge`.\n\nTry the [recorded bug-fix demo](https://github.com/Muvon/octomind/blob/master/examples/fix-a-bug): two failing tests, an agent fix, and an independent test rerun.\n\nMeasured on [octobench](https://github.com/Muvon/octobench) against **25 tasks harvested from merged pull requests** across Python, PHP, Rust, C++, and JavaScript. Each agent works in the pre-fix repo; held-out tests from the merged fix decide pass or fail. These are the published July 30, 2026 results, not a measurement of this checkout.\n\n|  | solved | judge Σ / 2500 | cost | wall time | \n|---|---|---|---|---|\n| **octomind + glm-5.2** | **24/25** | **2264** | $63.43 | 3.6h | \n| claude code + claude-opus-5 | 23/25 | 2262 | $81.79 | 6.7h | \n| codex + gpt-5.6-sol | 21/25 | 2127 | $14.86 | 1.0h | \n| opencode + glm-5.2 | 19/25 | 2093 | $129.54 | 3.3h | \n\n- **The harness matters.** opencode used the same model and endpoint; octomind solved 24 vs 19 at roughly half the cost. All four agents ran stock invocations with no tuning, so this measures the whole harness, not individual features.\n- **Worst-case pricing, still ahead.** glm-5.2 ran without prompt caching while Opus billed ~97% of context re-reads at cache rates — and octomind still led on solves, cost, and wall time.\n- **Reproducible.** Per-case table, artifacts, and reproduction guide:[BENCHMARK.md](https://github.com/Muvon/octobench/blob/8aa39684ff6103782aacb1bd79ea98e96e50d6cf/BENCHMARK.md) . Background:[blog post](https://octomind.run/blog/coding-agent-benchmark-real-prs) .\n\nDrop a `.agents/guardrails.toml` in your repo. The runtime enforces it deterministically, with no code to compile and no plugin to install.\n\n```\n# Pre-call deny — block a class of calls before they execute\n[[guard]]\nmatch   = \"shell(command=^rm\\\\s+-rf?)\"\nmessage = \"rm -rf blocked.\"\n\n# Conditional rule — only fires after the agent ran git status this session\n[[guard]]\nmatch   = \"shell(command=git push)\"\nwhen    = [\"+shell(command=git status)\"]\nmessage = \"Review changes before pushing.\"\n```\n\n| Layer | When it runs | What it does | \n|---|---|---|\n| **Guards** | Before a tool call | Deny by capability, argument regex, and session history. A match returns a denial instead of executing the call. | \n| **Hooks** | After a tool result | A non-zero exit injects stdout into the agent's inbox — lint and format failures become automatic corrections without restarting the turn. | \n| **Validators** | After a turn | Scripts the agent reads on its next turn. This replaces \"approve this change?\" prompts in autonomous loops. | \n\nHook and validator script examples: [Guardrails guide](https://github.com/Muvon/octomind/blob/master/doc/usage/18-guardrails.md).\n\nThe same session engine, exposed however your workflow needs it.\n\n| Surface | Use it for | Docs | \n|---|---|---|\n| Interactive CLI | Daily work, any domain | [Sessions](https://github.com/Muvon/octomind/blob/master/doc/usage/05-sessions.md) | \n| Piped ( `--format plain` /`jsonl` ) | CI/CD, shell scripts, automation | [CLI reference](https://github.com/Muvon/octomind/blob/master/doc/reference/01-cli-reference.md) | \n| Daemon + `send` | Background agents, continuous monitoring | [Daemon & hooks](https://github.com/Muvon/octomind/blob/master/doc/integration/03-daemon-and-hooks.md) | \n| WebSocket ( `octomind server` ) | IDE plugins, dashboards, integrations | [WebSocket server](https://github.com/Muvon/octomind/blob/master/doc/integration/01-websocket-server.md) | \n| ACP ( `octomind acp` ) | Sub-agent inside another agent or editor | [ACP protocol](https://github.com/Muvon/octomind/blob/master/doc/integration/02-acp-protocol.md) | \n\nNeed machine-readable results? Pass `--schema schema.json` to constrain the final response to a JSON Schema (requires a model with structured-output support). See [Structured output](https://github.com/Muvon/octomind/blob/master/doc/usage/11-structured-output.md).\n\n| Feature | What you get | Learn more | \n|---|---|---|\n| **Specialists & taps** | Packaged agents with model, prompt, MCP servers, and permissions; installs their tool dependencies on first use | [Tap system](https://github.com/Muvon/octomind/blob/master/doc/integration/04-tap-system.md) | \n| **Roles** | Per-role model, temperature, system prompt, tools | [Roles](https://github.com/Muvon/octomind/blob/master/doc/usage/06-roles.md) | \n| **Workflows** | Multi-step pipelines, each step with its own model and toolset | [Workflows](https://github.com/Muvon/octomind/blob/master/doc/usage/09-workflows.md) | \n| **MCP client** | stdio and Streamable HTTP servers, with OAuth; enable/disable servers mid-session | [MCP tools](https://github.com/Muvon/octomind/blob/master/doc/usage/07-mcp-tools.md) | \n| **Intent-driven context** | Skills and capabilities activate on demand, keeping context small | [Skills](https://github.com/Muvon/octomind/blob/master/doc/usage/15-skills.md) | \n| **Local project tools** | Executable scripts in `.agents/tools/` auto-register as tools | [Local tools](https://github.com/Muvon/octomind/blob/master/doc/usage/17-local-tools.md) | \n| **Supervisor & learning** | External planning and gating; file-backed learning records | [Supervisor](https://github.com/Muvon/octomind/blob/master/doc/usage/14-supervisor.md) ,[Learning](https://github.com/Muvon/octomind/blob/master/doc/usage/13-learning.md) | \n| **Sandbox** | `--sandbox` restricts filesystem writes to the working directory | [Config reference](https://github.com/Muvon/octomind/blob/master/doc/reference/03-config-reference.md) | \n| **Token efficiency** | Cache-aware accounting and compaction | [Token efficiency](https://github.com/Muvon/octomind/blob/master/doc/usage/16-token-efficiency.md) | \n\n```\noctomind run developer:general    # general dev, language skills auto-activate\noctomind run doctor:blood         # blood-test interpretation specialist\noctomind run lawyer:sg            # legal specialist\n```\n\nRunning a specialist fetches its manifest from the tap registry, installs any required binaries, resolves credentials, starts the right MCP servers, and then opens the session.\n\nBuild and register your own:\n\n```\noctomind tap init yourteam/my-tap   # scaffold, validate, git-init, and register locally\noctomind tap yourteam/my-tap        # on another machine, after publishing to GitHub\n```\n\nThe `octomind-` prefix is added automatically: `yourteam/my-tap` maps to the repository\n`yourteam/octomind-my-tap`.\n\n| Method | Command | \n|---|---|\n| **Install script** (recommended) | `curl -fsSL https://raw.githubusercontent.com/muvon/octomind/master/install.sh \\| bash` | \n| **Install script** (Windows PowerShell) | `irm https://raw.githubusercontent.com/muvon/octomind/master/install.ps1 \\| iex` | \n| **Homebrew** (macOS) | `brew install muvon/tap/octomind` | \n| **Scoop** (Windows) | `scoop bucket add muvon https://github.com/Muvon/scoop-bucket` then`scoop install muvon/octomind` | \n| **Cargo** (Rust 1.95+) | `cargo install octomind` | \n| **Docker** | `docker run --rm ghcr.io/muvon/octomind --help` | \n| **From source** | `git clone https://github.com/muvon/octomind.git && cd octomind && cargo build --release` | \n\nThe install script detects your OS and architecture (Linux and macOS on x86_64/aarch64) and installs to `~/.local/bin/`. Pass `--install-dir <DIR>` or set `OCTOMIND_INSTALL_DIR` to override. On Windows (x86_64/aarch64), `install.ps1` installs to `%LOCALAPPDATA%\\octomind\\bin` and adds it to your user `PATH`; it honors `OCTOMIND_INSTALL_DIR` and `OCTOMIND_VERSION` too. `install.sh` still works from Git Bash or MSYS2.\n\n**Command not found?** Add the install directory to your `PATH`:\n\n```\nexport PATH=\"$HOME/.local/bin:$PATH\"\n```\n\nBuilding from source requires `protoc`; see [Building from source](https://github.com/Muvon/octomind/blob/master/doc/dev/01-building-from-source.md) for per-OS prerequisites.\n\nVerify:\n\n```\noctomind --version\noctomind config      # generate the default config\noctomind run         # start your first session\n```\n\nShell completions: `octomind completion <bash|zsh|fish|elvish|powershell>`.\n\n**Octomind Cloud** — `octomind login` (device-code sign-in, like `gh auth login`) stores a gateway key locally. The default config already uses `octohub:auto`. [Learn more](https://octomind.run/cloud).\n\n**Bring your own key** — set the provider's environment variable (`OPENROUTER_API_KEY`, `OPENAI_API_KEY`, `ANTHROPIC_API_KEY`, `DEEPSEEK_API_KEY`, …) and point the model tables at it. The supervisor and compression profiles also default to `octohub:auto`, so update all three:\n\n```\n[model]\nname = \"openrouter:google/gemini-2.5-flash\"\n\n[supervisor.model]\nname = \"openrouter:google/gemini-2.5-flash\"\n\n[compression.model]\nname = \"openrouter:google/gemini-2.5-flash\"\n```\n\nProvider details and per-role overrides: [Providers & models](https://github.com/Muvon/octomind/blob/master/doc/usage/04-providers.md).\n\nConfig lives at `~/.local/share/octomind/config/config.toml` on macOS and Linux, and under `%LOCALAPPDATA%/octomind/config/` on Windows. Set `OCTOMIND_DATA_DIR` to override the data root.\n\n```\noctomind config --show       # view current config\noctomind config --validate   # validate config\n```\n\nOverride any value for a single run with `-c`:\n\n```\noctomind run -c supervisor.enabled=false\n```\n\nFull reference: [Configuration reference](https://github.com/Muvon/octomind/blob/master/doc/reference/03-config-reference.md) · [Environment variables](https://github.com/Muvon/octomind/blob/master/doc/reference/04-environment-variables.md).\n\n| Command | Description | \n|---|---|\n| `/help` | Show all commands | \n| `/info` | Token usage and costs | \n| `/model anthropic:claude-haiku-4-5` | Switch model mid-session | \n| `/role developer:general` | Switch to a configured role or tap tag | \n| `/new Review auth` | Start a fresh session (title optional) | \n| `/done` | Force context compression and start background learning extraction when enabled | \n| `/exit` | Exit the session | \n\nFull list: [Session commands](https://github.com/Muvon/octomind/blob/master/doc/reference/02-session-commands.md).\n\nOctomind reports anonymous usage: which commands, tools, and models are used, plus timings, token counts, and error kinds. It never sends your code, prompts, file paths, tool arguments, or environment values. Opt out in any of three ways:\n\n```\nexport DO_NOT_TRACK=1          # the cross-tool standard, honored first\nexport OCTOMIND_TELEMETRY=0    # for subsequent commands in this shell\n# or set `telemetry = false` in config.toml\n```\n\nExact field list: [Telemetry](https://github.com/Muvon/octomind/blob/master/doc/reference/04-environment-variables.md#telemetry).\n\n| Start here | Go deeper | Integrate | Reference | \n|---|---|---|---|\n| [Installation](https://github.com/Muvon/octomind/blob/master/doc/usage/01-installation.md) | [Roles](https://github.com/Muvon/octomind/blob/master/doc/usage/06-roles.md) | [WebSocket server](https://github.com/Muvon/octomind/blob/master/doc/integration/01-websocket-server.md) | [CLI](https://github.com/Muvon/octomind/blob/master/doc/reference/01-cli-reference.md) | \n| [Quickstart](https://github.com/Muvon/octomind/blob/master/doc/usage/02-quickstart.md) | [Workflows](https://github.com/Muvon/octomind/blob/master/doc/usage/09-workflows.md) | [ACP protocol](https://github.com/Muvon/octomind/blob/master/doc/integration/02-acp-protocol.md) | [Config](https://github.com/Muvon/octomind/blob/master/doc/reference/03-config-reference.md) | \n| [Configuration](https://github.com/Muvon/octomind/blob/master/doc/usage/03-configuration.md) | [Compression](https://github.com/Muvon/octomind/blob/master/doc/usage/08-compression.md) | [Daemon & hooks](https://github.com/Muvon/octomind/blob/master/doc/integration/03-daemon-and-hooks.md) | [Session commands](https://github.com/Muvon/octomind/blob/master/doc/reference/02-session-commands.md) | \n| [Providers & models](https://github.com/Muvon/octomind/blob/master/doc/usage/04-providers.md) | [Guardrails](https://github.com/Muvon/octomind/blob/master/doc/usage/18-guardrails.md) | [Editor integration](https://github.com/Muvon/octomind/blob/master/doc/usage/12-editor-integration.md) | [Environment variables](https://github.com/Muvon/octomind/blob/master/doc/reference/04-environment-variables.md) | \n\nFull index: [doc/README.md](https://github.com/Muvon/octomind/blob/master/doc/README.md) · Hosted: [octomind.run/docs](https://octomind.run/docs/).\n\nThe most impactful contribution isn't code — **it's specialist agents.** A cardiologist publishing `doctor:medications`. A tax attorney publishing `lawyer:us`. A security researcher publishing `security:owasp`. One TOML file, and everyone facing that problem gets a specialist-grade AI.\n\nCode contributions are welcome too. Set up the hooks and run the gate before you push:\n\n```\npip install pre-commit && pre-commit install\nmake dev    # fmt + clippy + test\n```\n\nCommits follow [Conventional Commits](https://www.conventionalcommits.org). Full guide, architecture overview, and code conventions: [CONTRIBUTING.md](https://github.com/Muvon/octomind/blob/master/CONTRIBUTING.md) · internals: [Architecture](https://github.com/Muvon/octomind/blob/master/doc/dev/02-architecture.md).\n\nCommunity participation follows our [Code of Conduct](https://github.com/Muvon/octomind/blob/master/CODE_OF_CONDUCT.md). Report vulnerabilities privately using the [security policy](https://github.com/Muvon/octomind/blob/master/SECURITY.md).\n\nApache License 2.0 — see [LICENSE](https://github.com/Muvon/octomind/blob/master/LICENSE).", "url": "https://wpnews.pro/news/octomind-a-coding-agent-that-recalls-archived-messages-after-compaction", "canonical_source": "https://github.com/muvon/octomind", "published_at": "2026-10-31 04:54:13+00:00", "updated_at": "2026-10-31 05:18:27.813299+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "developer-tools", "agent-protocols", "large-language-models"], "entities": ["Octomind", "Muvon", "Model Context Protocol", "OpenRouter", "Anthropic", "OpenAI", "DeepSeek", "Ollama"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/octomind-a-coding-agent-that-recalls-archived-messages-after-compaction", "markdown": "https://wpnews.pro/news/octomind-a-coding-agent-that-recalls-archived-messages-after-compaction.md", "text": "https://wpnews.pro/news/octomind-a-coding-agent-that-recalls-archived-messages-after-compaction.txt", "jsonld": "https://wpnews.pro/news/octomind-a-coding-agent-that-recalls-archived-messages-after-compaction.jsonld"}}