docs: add harness design documentation (gt-cr9)

Create comprehensive harness documentation covering:
- What a harness is (installation directory vs town concept)
- Harness structure and creation with gt install
- Beads redirect patterns for complex setups
- Multi-system sharing (PGT/GGT coexistence)
- Configuration files (town.json, rigs.json, state.json)
- Harness templates for organizations
- Migration between harnesses

Update architecture.md to:
- Rename "Town" section to "Harness (Town)" with clearer explanation
- Add cross-references to new harness.md
- Update directory structure section with "Harness Level" heading
- Expand CLI commands section with more gt install options

Update install.go help text to reference harness.md.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Steve Yegge
2025-12-19 12:02:04 -08:00
parent 95ba8fcb6b
commit 1e6a363757
3 changed files with 386 additions and 24 deletions

View File

@@ -45,12 +45,28 @@ graph TB
## Core Concepts
### Town
### Harness (Town)
A **Town** is a complete Gas Town installation - the workspace where everything lives. A town contains:
- Town configuration (`config/` directory)
- Mayor's home (`mayor/` directory at town level)
- One or more **Rigs** (managed project repositories)
A **Harness** is the installation directory where Gas Town lives - the physical root of your workspace. The terms "harness" and "town" are often used interchangeably:
- **Harness** = physical (the directory at `~/gt/`)
- **Town** = logical (the Gas Town workspace concept)
A harness contains:
- `CLAUDE.md` - Mayor role context (Mayor runs from harness root)
- `mayor/` - Mayor configuration, state, and registry
- `.beads/` - Town-level beads (gm-* prefix for mayor mail)
- `rigs/` or rig directories - Managed project containers
Create a harness with `gt install`:
```bash
gt install ~/gt --git # Create harness with git
```
**See**: [docs/harness.md](harness.md) for comprehensive harness documentation, including:
- Beads redirect patterns for complex setups
- Multi-system sharing (PGT/GGT coexistence)
- Harness templates for organizations
- Migration between harnesses
### Rig
@@ -216,25 +232,33 @@ This enables "Engineer in a Box" - polecats that execute structured workflows wi
## Directory Structure
### Town Level
### Harness Level
The harness (town root) is created by `gt install`:
```
~/gt/ # Town root (Gas Town harness)
├── CLAUDE.md # Mayor role prompting (at town root)
~/gt/ # HARNESS ROOT (Gas Town installation)
├── CLAUDE.md # Mayor role context (runs from here)
├── .beads/ # Town-level beads (prefix: gm-)
│ ├── beads.db # Mayor mail, coordination, handoffs
│ └── config.yaml
├── mayor/ # Mayor's HOME at town level
├── mayor/ # Mayor configuration and state
│ ├── town.json # {"type": "town", "name": "..."}
│ ├── rigs.json # Registry of managed rigs
│ └── state.json # Mayor state (NO mail/ directory)
│ └── state.json # Mayor agent state
├── gastown/ # A rig (project container)
└── wyvern/ # Another rig
├── rigs/ # Standard location for rigs
│ ├── gastown/ # A rig (project container)
│ └── wyvern/ # Another rig
└── <rig>/ # OR rigs at harness root (legacy)
```
**Note**: Mayor's mail is now in town beads (`gm-*` issues), not JSONL files.
**Notes**:
- Mayor's mail is in town beads (`gm-*` issues), not JSONL files
- Rigs can be in `rigs/` or at harness root (both work)
- See [docs/harness.md](harness.md) for advanced harness configurations
### Rig Level
@@ -316,19 +340,19 @@ graph TB
### ASCII Directory Layout
For reference without mermaid rendering:
For reference without mermaid rendering (see [harness.md](harness.md) for creation/setup):
```
~/gt/ # TOWN ROOT (Gas Town harness)
├── CLAUDE.md # Mayor role prompting
~/gt/ # HARNESS ROOT (Gas Town installation)
├── CLAUDE.md # Mayor role context
├── .beads/ # Town-level beads (gm-* prefix)
│ ├── beads.db # Mayor mail, coordination
│ └── config.yaml
├── mayor/ # Mayor's home (at town level)
├── mayor/ # Mayor configuration and state
│ ├── town.json # {"type": "town", "name": "..."}
│ ├── rigs.json # Registry of managed rigs
│ └── state.json # Mayor state (no mail/ dir)
│ └── state.json # Mayor agent state
├── gastown/ # RIG (container, NOT a git clone)
│ ├── config.json # Rig configuration
@@ -1042,10 +1066,13 @@ This ensures all agents in the rig share a single beads database, separate from
## CLI Commands
### Town Management
### Harness Management
```bash
gt install [path] # Install Gas Town at path
gt install [path] # Create Gas Town harness (see harness.md)
gt install --git # Also initialize git with .gitignore
gt install --github=u/r # Also create GitHub repo
gt git-init # Initialize git for existing harness
gt doctor # Check workspace health
gt doctor --fix # Auto-fix issues
```