From one idea to a merged stack.
People keep asking what Monkeypuzzle actually does. So here's the whole loop — the same one whether you're a human in a terminal or an agent driving the API. Scroll, and watch it play out.
Start one small idea.
Every unit of work is a piece — a branch in its own git worktree. Cut one and Monkeypuzzle spins up the worktree, an optional tmux session, and fires your on-create hooks.
mp create --name auth-schema— or justmp new.mp create --prompt "…"hands the brief to an agent to scaffold.- Your other work never moves — no stashing, no dirty tree.
Build features in layers.
Real features are more than one idea. Stack the next piece on top of
the last with mp stack append — schema, then API, then UI — each a
clean, reviewable layer rebased on the one below.
mp stack status draws the whole tree, so you always know what sits on what.
Switch without losing your place.
Jump between pieces without breaking flow. The tmux plugin pops a fuzzy picker over your current layout — pick a piece, land in its worktree and session.
Change one piece, fix the whole tree.
Edit a piece low in the stack and everything above it is now stale.
mp stack sync rebases the tree onto the new base — in order — and
stops cleanly the moment a conflict needs you.
- Conflicts are surfaced, never silently dropped — fix, then
mp stack continue. mp stack undorestores every branch to the pre-sync snapshot.- Pieces that didn't change are left untouched.
One idea per pull request.
Ship the stack. mp pr create pushes the piece and opens a PR
based on the piece below it — so each PR is a single idea, and
reviewers never wade through the whole feature at once.
- Stacked bases wired parent-to-parent; the stack is drawn into every description.
mp pr readyflips a draft when it's time for eyes.mp pr create --stacksubmits every piece in one go.
See every stack, live.
The server syncs your GitHub PRs and draws each stack as a living tree — across repos and teammates. Review state, CI, and "needs restack" flow in on their own.
Land it, clean up after.
When the bottom piece is approved, mp merge lands it on the trunk —
fast-forward only — then restacks the rest. mp done
wraps a finished piece: merge, delete the branch, tear down the worktree and session.
- Refuses to merge when main has moved on — sync first, no surprise overwrites.
- Worktrees and tmux sessions are cleaned up for you.
The same workflow, for your agents.
Here's the part that surprises people: there's no separate agent mode.
Every command takes flags, or JSON on stdin, and prints JSON on stdout.
--schema documents the shape of each one.
So an AI agent cuts pieces, restacks, and opens PRs through the exact same
mp — and the bundled MCP server hands that whole workflow to
assistants like Claude, with the same safety rails you get.
Cut. Stack. Restack. Submit. Merge.
One workflow for your terminal, your team's dashboard, and your agents.