-
-
Don't trust the agent. Audit it." The Hero landing page introducing DevCompanion AI's deterministic approach to autonomous code fixes.
-
Live execution: The 9-state XState machine autonomously reproduces, patches, and verifies the bug in real-time.
-
Millisecond-precise replay. The Time-Travel Scrubber and Diff Viewer prove actual disk-level code changes (red to green).
Inspiration
Autonomous coding agents can modify code quickly, but developers still need to know what changed, why it changed, and whether the result was actually verified.
DevCompanion AI was built to make autonomous code repair observable and auditable. It turns a bug report into a controlled bug-to-verified-fix workflow with explicit state transitions, real test execution, replayable history, and a shareable receipt.
What it does
DevCompanion AI is a self-hosted Model Context Protocol (MCP) server for autonomous software repair.
A run can:
- reproduce a reported failure;
- localize the relevant source symbol;
- apply a targeted patch to the sandbox;
- run verification tests;
- perform a critique step;
- record the resulting state history and audit trail;
- generate a shareable receipt containing a SHA-256 integrity hash.
The dashboard streams progress while the run executes. A time-travel scrubber makes the recorded workflow easy to inspect, and the MCP Inspector demonstrates client interoperability.
How we built it
- Runtime: Node.js and TypeScript.
- Agent orchestration: XState deterministic finite-state machine.
- Protocol: Model Context Protocol version 2025-11-25 over Streamable HTTP.
- MCP server: FastMCP and the MCP SDK.
- Validation: Zod.
- Dashboard: Next.js, Tailwind CSS, and Framer Motion.
- Deployment: Vercel for the dashboard and the configured server deployment.
The workflow includes intake, reproduction, localization, patching, verification, critique, verified completion, diagnosis, and escalation paths. Retry behavior is bounded by iteration and budget guards.
Security and trust boundaries
The server restricts filesystem writes to the sandbox, validates paths, applies Origin validation, and limits command execution through fixed allowed commands rather than arbitrary shell execution.
The receipt hashes the recorded state history, audit log, before-and-after content, and timestamp so a reviewer can inspect what the run produced.
Challenges we ran into
The main challenges were implementing MCP tool results correctly, handling Streamable HTTP behavior, validating filesystem boundaries, and connecting a deterministic state machine to a live progress interface.
We also had to make failures explicit: unsuccessful steps enter diagnosis and either retry within configured limits or escalate for human intervention.
Accomplishments we are proud of
- A working autonomous bug-to-verified-fix workflow.
- Real test execution rather than a simulated success response.
- A deterministic XState orchestration layer.
- MCP Inspector interoperability over Streamable HTTP.
- Before-and-after disk diff visibility.
- Replayable audit history and shareable SHA-256 receipts.
- A public repository with setup instructions, architecture documentation, and a friction log.
What we learned
Observable systems are easier to trust than opaque agent responses. MCP provided a clear interoperability boundary, while XState made the repair lifecycle and failure paths explicit.
The project also reinforced that verification must be a separate gate: generating a patch is not the same as proving that the patch works.
What's next
Next steps include broader repository support, richer OpenTelemetry observability, more verification adapters, and additional MCP clients.
Built With
- agentic-ai
- alexaplus
- fastmcp
- javascript
- mcp
- model-context-protocol
- next.js
- node.js
- railway
- sha256
- state-machine
- streamable-http
- tailwind-css
- typescript
- vercel
- xstate
- zod