ForkMind ๐Ÿง 

Local-first LLM state branching & debugging.

Treat AI context windows like a Git repo. Capture, visualize, branch, and regression-test LLM calls as a DAG โ€” free & local via Ollama, any OpenAI-compatible API, and MCP for agents. Zero config, no cloud, no account.

MIT CI Node >=18 Contributing Contributors
# run straight from the git link โ€” no registry needed
npx github:medhovarsh/forkmind init
npx github:medhovarsh/forkmind start
ForkMind dashboard demo: conversation DAG, node inspector, fork dialog

The dashboard: a conversation tree with a branch off the root, the node inspector (request/response, tokens, provenance), and the Fork dialog.

What it does

๐ŸŒณ

Branch like Git

Every LLM call is a node in a DAG. Fork an alternative prompt or model from any historical turn.

๐Ÿ†“

Free & local

Defaults to open-source models via Ollama. No API key, no database, no telemetry.

๐Ÿ”Œ

Any provider

Provider-agnostic proxy. OpenAI, Groq, OpenRouter, Together, LM Studio, vLLM, Anthropic.

๐Ÿ“ก

Streaming

Bytes pass through untouched; the proxy reconstructs the full message โ€” text and tool calls.

๐Ÿค–

MCP for agents

An agent can query its own history mid-task โ€” recall attempts, trace lineage, self-correct.

โœ…

Regression tests

Pin good outputs as baselines, re-run after prompt tweaks, catch drift in CI.

Quick start

# 1. a free local model (install Ollama from ollama.com)
ollama pull llama3

# 2. start ForkMind (proxy + dashboard on :4500)
npx github:medhovarsh/forkmind start

# 3. point your OpenAI client at the proxy
#    baseURL: http://localhost:4500/v1
#    open http://localhost:4500 for the dashboard

Full documentation on GitHub โ†’

FAQ

What is ForkMind?

ForkMind is a local-first tool that treats AI context windows like a Git repository. It captures every LLM call into a local .forkmind directory, visualizes the conversation as a Directed Acyclic Graph (DAG), and lets you branch alternative prompts or models from any historical turn โ€” all on your machine, no cloud, no account.

Is ForkMind free?

Yes. ForkMind is MIT-licensed and runs entirely on your machine. It defaults to free, open-source models via Ollama โ€” no API key, no database, no telemetry.

Which LLM providers does ForkMind support?

ForkMind is a provider-agnostic proxy. It works with any OpenAI-compatible API, including Ollama, OpenAI, Anthropic, Groq, OpenRouter, Together, LM Studio, and vLLM.

How do I install ForkMind?

ForkMind runs straight from its git link โ€” no npm registry needed. Run npx github:medhovarsh/forkmind start to launch the proxy and dashboard on port 4500, then point your OpenAI client at http://localhost:4500/v1.

How can AI agents use ForkMind?

ForkMind exposes an MCP (Model Context Protocol) server. An agent can query its own history mid-task to recall previous attempts, trace lineage, and self-correct.