Dibs logo

Dibs

by polymatx

Coordinates parallel coding agents with expiring file claims, hooks, presence, handoffs, and searchable git-based lessons.

Install Dibs

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "polymatx-dibs": {
      "command": "npx",
      "args": [
        "-y",
        "dibs"
      ],
      "env": {
        "DIBS_AGENT": "YOUR_VALUE_HERE"
      }
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Values are written into the snippet above so you can paste it as is. They never leave your browser.

We couldn’t confirm it starts correctly

We ran the install command but it didn't respond within our test window — this can mean a slow first-time install rather than a real problem.

npx -y dibs

Process exited before answering initialize.

This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked 7d ago.

Overview

polymatx/dibs MCP server coordinates coding agents working in the same Git repository by exposing dibs operations through stdio. It stores short-lived claims and coordination state in the repository’s shared Git directory, while lessons live in committed `.dibs/lessons/` files. Use it when multiple agents or worktrees need to avoid editing the same files, exchange handoff notes, and retain searchable project knowledge. Optional Claude Code and pre-commit hooks can enforce claims before edits or commits.

Use cases

  • Coordinate file ownership across parallel coding agents
  • Prevent conflicting edits with Claude Code hooks
  • Reject colliding commits with a pre-commit hook
  • Broadcast handoff notes between worktrees
  • Search committed lessons from earlier sessions

Key features

  • TTL-based file and glob claims
  • Shared Git worktree coordination state
  • Claude Code and pre-commit enforcement hooks
  • Agent presence and handoff notes
  • BM25-searchable Markdown lessons
  • Stdio MCP server

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 2d ago

Recent health check succeeded.

7/7 checks healthy over the last 45d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 7d ago via OSV.dev · dibs (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars2Stargazers on the source repository.
npm downloads15Package downloads in the last 30 days.
Last commit9d agoMost recent push to the default branch.
Install checkInconclusiveDidn't respond in our test window — often a slow first install.
Directory activity3 viewsConfig copies, upvotes, and views on AllMCPs.

How Dibs works

What polymatx/dibs does

polymatx/dibs coordinates multiple coding agents that operate on one Git repository, including repositories divided into worktrees. Its core unit is a file claim: an agent leases a path, directory, or glob for a limited period and gives a reason for the lease. Other agents can inspect claims, avoid conflicting work, or send a note to the current holder.

The project also tracks agent presence, unread notes, lease events, and a journal of coordination activity. Lessons are stored as Markdown files under .dibs/lessons/, committed with the repository, and searchable with BM25 so later sessions can find prior findings.

How it works

polymatx/dibs keeps live coordination data in the Git common directory returned by git rev-parse --git-common-dir. Because all worktrees share that directory, claims and presence updates are visible across worktrees without commits. This state is machine-local and does not appear in normal Git status output. Knowledge files use the repository’s .dibs/ directory instead, making lessons available through Git history, review, and CI.

Claims are JSON records containing an agent identity, patterns, a reason, and an expiry. Conflict checks use an advisory lock, while expired leases are discarded logically when state is read. The default lease duration is 30 minutes and the maximum is 24 hours. Agent identity comes from --agent, then DIBS_AGENT, and finally a stable name derived from the worktree path.

Patterns are doublestar globs relative to the repository root. Directory claims cover their subtrees, and paths that do not exist yet can still be claimed. Conflict detection for two globs is conservative when their static prefixes overlap in a nested way.

Setup and configuration

Install the binary with go install github.com/polymatx/dibs/cmd/dibs@latest, use a release binary for Linux, macOS, or Windows, or run the published container image. Building from source requires Go 1.26 or newer; running dibs requires Git.

From the repository root, run dibs init to create the .dibs/ directory. The optional --agents-md flag adds the coordination protocol to AGENTS.md. Run dibs mcp to start the MCP server over stdio. The container example mounts the repository at /workspace and invokes the same MCP command.

Tools and capabilities

polymatx/dibs supports these command-level operations:

  • Claim, release, renew, and check file leases.
  • Show agents, claims, expiry information, and unread note counts.
  • Broadcast notes and read them with per-agent tracking.
  • Add, list, show, and BM25-search lessons.
  • Inspect journal events and identify the current agent.
  • Install or remove Claude Code and pre-commit enforcement hooks.

State-reading commands support --json for scripting. Exit code 2 indicates a denied operation or a path held by another agent.

Limitations and notes

The system has no database, daemon, background process, or separate coordination service. Claims are leases, so a crashed agent’s claims expire rather than requiring manual cleanup. Enforcement is opt-in: the Claude Code hook blocks conflicting edit attempts, while the pre-commit hook rejects commits that touch another agent’s claimed files. Both hooks fail open if dibs cannot run, allowing the edit or commit to continue.

The Claude Code hook is specifically for Claude Code. The pre-commit hook applies at Git commit time and can cover agents that use the repository’s commit workflow. Existing Claude settings and Git hooks are preserved during additive, idempotent installation.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Dibs

polymatx/dibs is an MCP server that connects coding agents sharing a Git repository and provides coordination for file claims, agent status, notes, and lessons. It uses expiring leases to identify ownership, stores live state in the Git common directory, and keeps searchable Markdown lessons under `.dibs/lessons/`.

Install it with `go install github.com/polymatx/dibs/cmd/dibs@latest`, download a release binary, or use the published container image. Initialize a repository with `dibs init`, then start the stdio MCP server with `dibs mcp`.

It uses expiring claims and optional enforcement hooks. Agents claim paths or globs before editing; the Claude Code hook blocks conflicting edit attempts, and the pre-commit hook rejects commits that touch files claimed by another agent.

Yes, the project documentation names Cursor as a supported parallel-agent workflow. Coordination state is shared through the repository’s Git common directory, while enforcement specifically documented by the project is available for Claude Code and Git pre-commit operations.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewDibs AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/polymatx-dibs?style=directory)](https://allmcps.com/mcp/polymatx-dibs)
HTML Embed
<a href="https://allmcps.com/mcp/polymatx-dibs"><img src="https://allmcps.com/api/badge/polymatx-dibs?style=directory" alt="Dibs on AllMCPs" /></a>