Skip to content

Model Peer v0.2.0

Choose a tag to compare

@makedirectory makedirectory released this 09 Aug 18:51
· 20 commits to main since this release
1849587

Cross-model peer review, now with a bounded consultation chain.

Install

curl -fsSL https://raw.githubusercontent.com/makedirectory/ModelPeer/v0.2.0/install.sh | bash

As with any remote shell installer, inspect it before piping it into a shell.

Highlights

Peer-chain depth

--depth N on ask and review, plus MODEL_PEER_MAX_DEPTH, bounds how far consultation can recurse. Default 1 (a peer answers alone), ceiling 10. The limit propagates down the chain, so a peer cannot raise its own ceiling.

model-peer ask claude "..."              # depth 1: claude answers alone
model-peer ask claude --depth 2 "..."    # claude may consult one further peer
model-peer review --depth 2 "..."        # each reviewer may consult one peer

Depth is a limit, not a permission

The governing invariant:

Increasing depth may increase how many models can participate.
Increasing depth must never increase what a model can do to the host system.

Delegation — the permission to initiate a further consultation — is tracked separately from depth and granted only where a provider's sandbox can scope it to Model Peer alone:

Provider Nested consultation What delegation grants
Claude yes Bash auto-approved only for Bash(model-peer:*)
Codex yes nothing — the read-only sandbox already permits it
Gemini no n/a; its deny rules are unconditional at every depth

Gemini is deliberately excluded: its policy engine can only allow or deny run_shell_command wholesale, and an uneven provider matrix is more honest than a weakened boundary. A depth budget a provider cannot safely hold is reported on stderr, never silently converted into a wider sandbox.

This is a known implementation limitation rather than the intended end state. The README documents a consultation broker roadmap, where peers request a consultation from the parent process instead of executing model-peer, so peers stay read-only at every depth.

Chain guards

Two independent guards, both exiting 64: the chain may not exceed the depth limit, and a model is never consulted by itself at any depth.

Fixed

  • model-peer review overwrote MODEL_PEER_STACK, so a review launched from inside a peer chain escaped the recursion guard entirely. The synthesizer is now always a leaf.
  • install.sh embeds a verbatim copy of bin/model-peer for the curl path and could drift from it silently. make sync regenerates it; make check-sync fails the build on drift.
  • The documented one-line install pointed at a YOUR_GITHUB_USERNAME placeholder and could never have worked.
  • CI had never passed on this repository — make lint failed shellcheck from the first commit. It is green on ubuntu and macOS as of this release.

Changed

  • Agent rules consolidate into a single AGENTS.md, with CLAUDE.md and GEMINI.md as symlinks so all three CLIs read one file. examples/ ships one shared template instead of three near-identical copies.
  • model-peer doctor reports the per-provider nested-consultation matrix, the effective depth limit, and any active chain.

Full detail in CHANGELOG.md.