WADE
← Back to journal

Dev Projects

Mindmerge: A Local-First AI Coding Agent That Never Sends Your Code to the Cloud

Mindmerge is a self-hosted coding agent with a real plan-execute-verify loop, a live file explorer, and zero dependency on OpenAI, Anthropic, or any cloud API — everything runs through Ollama on your own machine.

By Wade StudioAugust 12, 20266 min read
A dark-themed code editor interface with an AI assistant panel open beside it

Most AI coding tools ship your code to someone else's servers the moment you hit enter. That's a fine trade-off for a lot of developers, but it's a dealbreaker for anyone working with client code under NDA, proprietary systems, or just a personal preference not to hand a third party a live feed of everything they type. Mindmerge exists for that second group. It's a coding agent that runs entirely on your own machine, talking to a local model through Ollama instead of an API key from a cloud provider.

What it actually is

Mindmerge is a Next.js web app that puts a full agentic coding assistant behind a clean browser interface. You describe what you want built — "build a React todo app," "create a REST API," "set up a Python CLI tool" — and the agent plans the work, writes the files, runs shell commands, and shows you every step it took along the way, live, in a chat-style interface with a file explorer sitting right next to it.

The entire stack is local-first by design. There's no cloud LLM call anywhere in the loop; the app talks to Ollama running on localhost:11434, which means whatever model you've pulled — a Codellama variant, Qwen, or anything else Ollama supports — is doing the actual reasoning, on your hardware, with your code never leaving the machine.

The agent loop

The interesting part isn't the chat window, it's what happens after you send a message. Mindmerge runs a genuine plan → execute → verify cycle rather than a single prompt-response exchange:

  1. Your message goes to the local model along with full conversation context and a defined set of tools.
  2. The model responds with tool calls — create_plan, read_file, write_file, shell_exec, list_dir — which the backend actually executes against a sandboxed workspace.
  3. Results get fed back to the model, and the loop continues, iterating up to 80 steps until the task is done.
  4. Every token, tool call, and result streams to the browser over Server-Sent Events, so you're watching the agent think and act in real time instead of waiting on a spinner.

That sandbox matters more than it sounds like it should. The Sandbox class scopes every file operation to a configurable root directory, so the agent can read, write, and run shell commands without any path traversal outside the workspace it's been given.

What you actually see on screen

The UI drops the sidebar-heavy layout most tools default to. Navigation lives entirely in a floating top navbar — Chat, Templates, Projects, Statistics, Settings, Help — which keeps the main pane focused on the conversation. A Files panel slides out from the right on demand, showing a live tree of whatever the agent has written, and a History panel tracks past sessions so you can pick a thread back up later.

The whole thing runs on a single-page-app pattern: every view is rendered inside one page.tsx behind an activePage state switch rather than separate routed pages, which keeps transitions between chat, templates, and stats feeling instant.

The stack underneath

Mindmerge leans on a modern, fairly opinionated set of tools rather than reinventing plumbing it doesn't need to:

  • Frontend: Next.js 16 with the App Router, React 19, TypeScript
  • Styling: Tailwind CSS 4, shadcn/ui components, Framer Motion for the interface polish
  • State: Zustand, kept entirely on the client
  • Backend: Next.js API routes running on Node
  • Database: Prisma ORM over SQLite, for session and history persistence
  • Auth: NextAuth.js
  • Deployment: a standalone Next.js output behind a Caddy reverse proxy

It's a stack built for someone who wants to bun install, point it at a running Ollama instance, and be building inside their own agent within a few minutes — not a research project requiring a GPU cluster to stand up.

Why "local-first" is the actual pitch

Cloud-based coding agents win on raw model quality — GPT and Claude-class models are, for now, simply stronger than most models you can run on a laptop. Mindmerge isn't trying to win that fight. It's making a different bet: that for a meaningful slice of developers, control over where the code goes matters more than squeezing out the last few points of model capability. Pull a capable local model, run the agent against it, and the tool never has a reason to phone home.

That's a genuinely different value proposition from most of what's shipping in the AI-coding-tool space right now, and it's the kind of project worth watching as local models keep closing the gap with their cloud counterparts.