agent-runner-mcp
This server is an MCP interface for running and managing sandboxed command executions with evidence-preserving lifecycles.
task_run: Execute a command in a platform-specific sandbox (Windows ACL, Linux bwrap, macOS sandbox-exec) and get a job directory.
task_wait: Block until a task finishes by writing its EXIT: terminal state, with optional timeout.
task_output: Incrementally read a task's out.log from a byte offset.
task_autopsy: Generate an autopsy report following the autopsy-spec (manner/evidence/verdict, death codes D-01~D-09).
task_kill: Terminate a running task via its lock pid (SIGKILL), useful for crash/adoption experiments.
task_adopt: Run a three-evidence adoption check (lock parsing, process liveness, exit protocol) for a task directory.
Integrates with any MCP client (Claude Code, Codex, etc.) to provide sandboxed runner protocol capabilities with zero-dependency MCP layer.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@agent-runner-mcp run a command, read the exit protocol, and get an autopsy report"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
agent-runner-mcp
An MCP server that exposes the three-platform sandboxed runner protocol to any MCP client (Claude Code, Codex, and others): run tasks in an evidence-protected sandbox, read the EXIT protocol, and get an autopsy report. Zero dependencies — the MCP layer is hand-rolled. Every claim carries an experiment number.
中文版见 README.zh-CN.md。
Why this exists
Agent frameworks each go their own way, but "run tasks reliably in a sandbox with evidence left behind" is a common hard need. This server wraps dsh-witness's runner protocol (lock=pid:startSec, EXIT:, the autopsy taxonomy) into MCP tools — Claude Code measured ✓ Connected; Codex and other MCP clients can connect over the same protocol.
Related MCP server: Terminal MCP Server
Tools
Tool | Semantics |
| Sandboxed command execution (Windows ACL / Linux bwrap / macOS sandbox-exec chosen per platform), returns the task directory |
| Wait for the terminal state (EXIT: written) |
| Incrementally read out.log by byte offset |
| Generate the autopsy report (autopsy-spec format: manner/evidence/verdict/D-01~D-09) |
| Kill by lock pid (crash experiments) |
| Three-evidence adoption adjudication (lock parsing + process liveness + exit protocol) |
Quick start
# Install (git source)
dsh plugin --profile <name> add "github:Wang-Lin-Chang/agent-runner-mcp#v0.1.1"
# Register with Claude Code
claude mcp add agent-runner -- node dist/server.js
# Or run the tests directly (15-assertion protocol measurement)
npm testAcceptance evidence
EXP-1: MCP protocol layer measured 15/15 (handshake / six tools / EXIT:0→D-01 / crash→D-08 / EXIT:1→D-02)
EXP-2: Claude Code 2.1.92 real client
✓ Connected(initialize + tools/list handshake)EXP-3: Windows ACL persistence verdict (observed artifacts separated from the evidence zone)
EXP-4: Death-semantics matrix aligned with the autopsy-spec taxonomy
Honest boundaries
Claude Code in-session tool calls need a login state — this machine is not logged in: the protocol handshake is measured, session calls are unmeasured, not claimed.
This server is the runner protocol layer: full registry-level adoption/event-sourcing/caching lives in dsh-witness.
Under the Windows CI admin environment the ACL sandbox does not apply → the runner's fail-closed (EXIT:-998) is the protocol-correct response; sandbox capabilities are measured in non-admin environments.
Offline applicability: architecturally no network dependency (local processes + file protocol); multi-day offline runs are unmeasured.
License
Apache-2.0
Available Tools
6 toolstask_adoptC
Three-evidence adoption check: lock pid:startSec parsing + process liveness + exit protocol read.
Inputs: jobDir (required).
task_autopsyA
Generate an autopsy report (autopsy-spec format: manner/evidence/verdict/death-code D-01~D-09) for a task directory.
Inputs: jobDir (required).
task_killA
Kill a running task by its lock pid (SIGKILL) — for crash/adoption experiments.
Inputs: jobDir (required).
task_outputA
Read task output from out.log (with byte offset for incremental reads).
Inputs: jobDir (required), offset.
task_runA
Run a command inside the evidence-protected sandbox runner (platform ACL/bwrap/sandbox-exec). Returns the job directory; the runner writes lock=pid:startSec and EXIT: on completion.
Inputs: command (required), label.
task_waitB
Wait for a task to reach a terminal state (EXIT: written).
Inputs: jobDir (required), timeoutMs.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Each tool has a clearly distinct purpose: run starts a task, wait blocks for completion, output reads logs, autopsy analyzes results, kill terminates, and adopt verifies state. No two tools overlap in function; even wait and adopt differ in blocking vs. check semantics.
All tools follow the exact same pattern: task_ followed by a single verb (run, wait, output, autopsy, kill, adopt). This is perfectly consistent and predictable.
With 6 tools, the server is well-scoped for task lifecycle management. Each tool earns its place, covering the core operations without redundancy.
The tool set covers the full task lifecycle: create/run, wait for completion, read output, kill, analyze, and adopt. No obvious gaps for the stated purpose of running commands in a sandbox and managing their results.
Maintenance
Related MCP Connectors
An MCP server for deep research or task groups
MCP server for Superserve sandboxes: create, exec, and manage Firecracker microVMs
Hosted MCP server for task-first delegation to remote workstations and workers.
MCP Server for an Agent Task Marketplace
Related MCP Servers
AlicenseAqualityDmaintenanceMCP server to give every agent an ephemeral Linux sandboxes for executing shell commands.152MIT- AlicenseNot gradedqualityDmaintenanceA production-ready MCP server for secure, session-based command execution, file manipulation, and system inspection via local terminal sessions.MIT
- FlicenseNot gradedqualityDmaintenanceAn MCP server exposing narrowly scoped storage workflows with Overseer approval integration and redacted execution evidence, currently in fixture-only development for testing via stdio.-
- AlicenseAqualityCmaintenanceA sandboxed MCP server that executes shell commands inside ephemeral, locked-down Docker containers with no network by default, dropped capabilities, and an audit log, enabling secure agent-driven command execution.3MIT