cd /news/ai-agents/show-hn-stackmaestro-local-managemen… · home › topics › ai-agents › article
[ARTICLE · art-176477] src=github.com ↗ pub= topic=ai-agents verified=true sentiment=↑ positive

Show HN: StackMaestro – Local management of agent-generated stacks

Developer Mark Lyons released StackMaestro 0.1.0, an open-source tool that infers a stack-first view of branches and pull requests from git ancestry, requiring no hand-maintained plan, backend or database. StackMaestro stores coordination state — claims, agent identity and layer titles — in a single file, `.git/stackmaestro/state.json`, shared across every worktree of a clone, and ships as a Cursor/VS Code sidebar, an MCP server exposing 9 tools (`list_stack`, `plan_feature`, `register_agent`, `claim_layer`, `release_layer`, `create_layer`, `ensure_worktree`, `publish_layer`, `sync_github_stack`), and a macOS-only desktop app. The tool requires the authenticated GitHub CLI (`gh`) plus Node 20+ and pnpm, and publishes layers as draft PRs registered through GitHub's native Stacked-PRs API; claims carry a 90-minute TTL and are local-machine-only by design.

key takeaway

StackMaestro derives stack structure from git ancestry instead of a plan file, keeps claims and agent identity in `.git/stackmaestro/state.json` with a 90-minute claim TTL, and exposes 9 MCP tools including `claim_layer` and `publish_layer` for coordinating multiple agents on stacked PRs.

read2 min views5 publishedNov 26, 2026
Show HN: StackMaestro – Local management of agent-generated stacks
Image: Michielbdejong (auto-discovered)

A stack-first view of your branches and PRs, inferred from git ancestry — no hand-maintained plan, no backend, no database. Coordination state (claims, agent identity, layer titles) lives in one file, .git/stackmaestro/state.json, shared across every worktree of a clone.

Read more: StackMaestro: trying to make agent-written code understandable by humans.

Three ways to use it: a Cursor/VS Code sidebar, an MCP server for any agent's chat, and a standalone desktop app.

  • GitHub CLI (gh), installed and authenticated (gh auth login ) — required. StackMaestro shells out to it for every PR/stack operation (gh pr create ,gh pr list ,gh api .../stacks ); without it, publishing and PR status just fail.
  • Node 20+, pnpm (corepack enable picks up the version this repo pins automatically)
  • A regular git repo with a GitHub remote
git clone https://github.com/marklyons/stackmaestro && cd stackmaestro
pnpm install
pnpm -r build
pnpm --filter stackmaestro package              # → apps/extension/stackmaestro-0.1.0.vsix
cursor --install-extension apps/extension/stackmaestro-0.1.0.vsix

No cursor on your PATH? Cmd+Shift+P → "Shell Command: Install 'cursor' command in PATH", or substitute code. Open any git repo afterward — the Explorer sidebar gets a "StackMaestro" section under your file tree.

Claude Code:

claude mcp add --scope user stackmaestro -- node /absolute/path/to/stackmaestro/apps/mcp-server/dist/index.js

Cursor — add to ~/.cursor/mcp.json:

{
  "mcpServers": {
    "stackmaestro": {
      "command": "node",
      "args": ["/absolute/path/to/stackmaestro/apps/mcp-server/dist/index.js"]
    }
  }
}

Exposes 9 tools: list_stack, plan_feature, register_agent, claim_layer, release_layer, create_layer, ensure_worktree, publish_layer, sync_github_stack.

pnpm --filter @stackmaestro/desktop package:app   # macOS only → apps/desktop/release/StackMaestro.app
open apps/desktop/release/StackMaestro.app

Quick iteration without a real app bundle: pnpm --filter @stackmaestro/desktop start.

  • Stack = git ancestry. A branch's parent is its closest real ancestor by commit graph — no naming convention, no separate plan file.plan_feature /create_layer also record the declared parent at creation time, so a freshly-planned stack shows up correctly nested before anyone's committed a line.

  • Claims mark "someone's working on this layer" — name, reason, 90 -minute TTL. A conflicting claim is rejected with who already holds it.

  • Agent identity. Callregister_agent once (prompt, optionallab for branding, optionalparentAgentId if spawned by another agent) before claiming anything. You get anagentId and a Greek-mythology name, shown as a floating badge with a lab-colored icon, and a "subagent of X" lineage tag when applicable.

  • Publishing pushes the branch, opens a draft PR against its stack parent, and registers/extends it as a real GitHub stack (native Stacked-PRs API) — linked on github.com, not just base-branch-chained.

  • Marketplace publishing / a signed desktop installer

  • UI for picking a sibling on a genuine fork (two children on one layer)

  • Agent registrations aren't pruned (claims expire; registrations don't)

  • Remote/team visibility — claims are local-machine-only by design

── more in #ai-agents 4 stories · sorted by recency
── more on @stackmaestro 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/show-hn-stackmaestro…] indexed:0 read:2min 2026-11-26 · —