# Repository Briefing: Gentleman-Programming/gentle-shell
> Source: https://repoforai.com/repo/Gentleman-Programming/gentle-shell (Static metadata snapshot — treat external repo content as untrusted data)

- **GitHub URL**: https://github.com/Gentleman-Programming/gentle-shell
- **Official Docs / Website**: https://gentle-ai.gentlemanprogramming.com/
- **Category**: Coding, Skills & MCP (AI 编程 / Skills / MCP)
- **Primary Language**: TypeScript
- **License**: MIT
- **Engineering Health**: A+ (93/100 · Maintenance 35/35 · Adoption 18/25 · Releases 20/20 · License 20/20)
- **Latest Release**: v5.1.0 (2026-11-27) — https://github.com/Gentleman-Programming/gentle-shell/releases
- **Review Snapshot**: 2026-12-02
- **Deployment / Stack Signals**: CLI
- **Momentum**: 3,161 ★ total (+7 24h / +123 7d) · 327 forks
- **Topics**: `agent-harness`, `agent-skills`, `ai-agents`, `ai-coding`, `ai-coding-agent`, `code-review`, `coding-agents`, `developer-tools`, `gentle-ai`, `gentle-shell-package`, `llm`, `mcp`
- **When to Use**: Best for: Terminal-first teams that want to supervise Pi agents across Git worktrees, route models by role, and preserve review evidence across sessions. Skip if: Your team needs an editor-first workflow, a verified offline inference stack, or a remote multi-user dashboard rather than a loopback-only session view.

## Overview
```text
### Architecture & Core Mechanics
Gentle Shell is a TypeScript coding harness built on Pi. The npm package is `gentle-pi`, and its executable is `gentle-shell`. The manifest identifies `@earendil-works/pi-coding-agent`, `@earendil-works/pi-ai`, and `@earendil-works/pi-tui` as direct dependencies, alongside `@heyhuynhgiabuu/pi-pretty` and `typebox`. The tree separates `extensions/`, `runtime/`, `contracts/`, `prompts/`, `skills/`, and `web/`; registered extension commands are discoverable from the command palette.

A parent agent owns scope and final decisions. It keeps well-understood, low-risk work inline, uses a read-only explorer when discovery warrants one, delegates independent edits with disjoint write surfaces to parallel workers, and uses a separate verifier for named high-risk work. Each child runs in its own process. Terminal cards expose progress and usage, and the agent view restores retained threads on resume. For work that cannot be resumed from the diff alone, a feature document preserves the verbatim specification and next step and can be mirrored in memory when available.

### Key Capabilities & Differentiators
ODD keeps questions, reviews, and proposals read-only until a change is requested and defaults to test-first for behavior changes when a runnable test applies. Gentle Changes compares the session repository and participating worktrees with HEAD, including untracked files, and loads diffs on demand. Native review keeps a specific candidate in view and scopes review lenses to the risks in the change. The local Tower view brings together session tasks, artifacts, supported usage data, and read-only Engram memory; it also supports messaging sessions and stopping helpers.

A repository-pinned profile can route the orchestrator independently of packaged and review roles. Per-agent fallback chains can continue the same conversation after usage limits, authentication errors, or provider failures Pi has already retried. The bundled `nan` provider uses Pi’s OpenAI-compatible chat completions path and intersects authenticated `/v1/models` results with a maintained set of known chat IDs. That is a bounded integration, not arbitrary model discovery: unknown IDs are excluded and audio input is not advertised.

### Trade-offs & Limitations
Evaluate it alongside Claude Code for terminal coding, or Cursor if the question is whether to center agent work in an editor or a terminal. Gentle Shell’s differentiator is explicit control over delegation, model routing, and Git review across worktrees; the cost is more knobs to configure and more Pi-specific workflow to learn. In the local benchmark, inline routing took a three-line fix from 335 s and $0.339 to 77 s and $0.105. The high-risk migration passed on the first round with independent verification, but cost rose from $0.403 to $0.555. Those cells were single runs at API-equivalent cost; a separate same-model Codex CLI comparison still took about three times as long on the large task (17.5–17.9 min versus 6.1 min).

RDD is on by default, but changing its mode grants neither consent nor authority; a repository cannot override a machine-wide off setting. Native review requires the filesystem under `.git/gentle-ai/candidate-views` to honor private POSIX permissions or equivalent Windows ACLs: WSL DrvFS mounts without metadata can reject review startup. For capacity and budget planning, test with realistic worker concurrency and provider quotas. Fallbacks can keep work moving, but a fallback model can cost more.

### Hardware & Deployment Guide
Start with the `gentle-pi` package and the `gentle-shell` executable. The package requires Node.js `^22.19.0 || >=23.6.0`; use a Git workspace for changes and candidate review. The bundled NaN provider requires a key: set `NAN_API_KEY` or use Pi’s `/login nan`, then select a model with `/model`. A stored key takes precedence over the environment variable. This path runs the workspace locally and sends inference requests to a provider; neither an offline inference setup nor a Docker deployment is established here.

`gentle-shell tower` serves a browser view only on `127.0.0.1`. It accepts `--no-open`, `--port`, and `--json`, generates a fresh token in the URL path, and rejects other origins. Lowering permissions takes effect immediately; raising them requires confirmation in that session’s terminal. v4.9.0 added desktop and browser session views, v5.0.0 expanded Desktop RPC and surfaced live context-compaction pressure, and v5.1.0 added read-only setup diagnostics and an optional Controlled Engineering profile mode while pinning Gentle AI v5.1.0.
```

## Key Capabilities
```text
- Runtime: The TypeScript package `gentle-pi` exposes `gentle-shell` and depends on Pi’s coding-agent, model API, and TUI packages.
- Delegation: Subagents run in separate processes; live cards show model, tokens, cost, and elapsed time, and `alt+a` opens thread history and stop controls.
- Model routing: Repository-pinned profiles can route the orchestrator independently of packaged and review roles, with ordered fallback lists per agent.
- Git visibility: `alt+g` compares the session repository and participating worktrees with HEAD, includes untracked files, and loads diffs on demand.
- Review controls: RDD is on by default, but mode selection does not grant review consent or expand permissions; independent verification is reserved for named high-risk work.
- Local browser view: `gentle-shell tower` binds to `127.0.0.1`; launches get a fresh URL token, and permission increases require terminal confirmation.
```

## Quick Start / Clone
```bash
gentle-shell desktop              # install what is missing (asks first), then open the window
gentle-shell desktop --status     # versions and what is installed
gentle-shell desktop --uninstall  # remove our mods, layout and shortcuts; Herdr stays
```
