FrankenTerm

10-Minute Tour

959 words4 min read8 subsectionsFrom the README at ft 0.15.21

On this page8
1 · Install + verify (1 minute)2 · See the fleet (1 minute, no daemon yet)3 · Start observing (2 minutes)4 · React safely (2 minutes — send + wait-for + policy gate)5 · Search the past (1 minute)6 · Orchestrate transactionally (2 minutes — mission + tx)7 · Verify the release attestation (1 minute)Where to go next

A guided walkthrough from "I cloned this" to "I have an AI driving an AI." Each step builds on the previous one.

1 · Install + verify (1 minute)

bash
curl -fsSL https://raw.githubusercontent.com/Dicklesworthstone/frankenterm/main/install.sh | bash

# An idle first install should report activation=current. If it is pending,
# use the printed absolute "Candidate CLI" path without changing live authority:
/absolute/candidate/generation/ft --version
/absolute/candidate/generation/ft doctor

The installer selects one DSR release generation and verifies its checksum and minisign signature before publication. It automatically activates a first process-family generation only when two bounded censuses report the host idle and the stable paths pass --version plus ft doctor --json. It never treats a standalone ft binary as a complete installation. ft talks to a live FrankenTerm/WezTerm-fork mux. Native vendored builds can use the direct pooled mux protocol; compatibility configurations may instead require the external wezterm CLI in PATH. ft doctor reports the available backend prerequisites. If you need a source build or optional features (mcp, web, distributed, semantic-search, ftui), see Installation below. Do not substitute the stable ft path for the printed candidate path unless the installer receipt explicitly says the generation is current.

2 · See the fleet (1 minute, no daemon yet)

ft robot state gives an AI-readable snapshot of every pane the mux can see, without starting a long-running daemon. This is the call a meta-agent makes when it wants a one-shot view. The full RobotResponse envelope wraps every response with ok, data, elapsed_ms, version, now, and schema_version (the MCP transport adds mcp_version on top of that); data for the state endpoint is a bare array of pane records (truncated below for clarity):

bash
$ ft robot state
{
  "ok": true,
  "data": [
    {"pane_id": 0, "title": "claude-code", "domain": "local", "cwd": "/project"},
    {"pane_id": 1, "title": "codex",       "domain": "local", "cwd": "/project"},
    {"pane_id": 2, "title": "build",       "domain": "local", "cwd": "/project"}
  ],
  "elapsed_ms": 4,
  "version": "0.2.0",
  "now": 1747371642000,
  "schema_version": 1
}

For AI-to-AI use, add --format toon to swap the JSON encoder for the lower-token TOON serialization. Exact savings depend on payload shape; pass --stats and the CLI prints estimated JSON and TOON token counts and the savings percentage to stderr.

3 · Start observing (2 minutes)

Now start the watcher so capture, pattern detection, and workflow execution kick in. Run it in the foreground for the tour:

bash
ft watch --foreground
# (leave this running; new terminal for the next steps)

In a second shell, peek at what the watcher is seeing. ft robot events returns an EventsData envelope that wraps the event list with filter + count metadata:

bash
$ ft status                                     # human-readable fleet overview
$ ft robot events --limit 5                     # recent pattern-triggered detections
{
  "ok": true,
  "data": {
    "events": [
      {
        "id": 1247,
        "pane_id": 1,
        "rule_id": "codex.usage.reached",
        "pack_id": "builtin:core",
        "event_type": "detection",
        "severity": "warn",
        "confidence": 0.95,
        "captured_at": 1747371642000
      }
    ],
    "total_count": 1,
    "limit": 5,
    "unhandled_only": false
  },
  "elapsed_ms": 3,
  "version": "0.2.0",
  "now": 1747371643000,
  "schema_version": 1
}

The watcher's pattern engine has already noticed pane 1 hit a rate limit; the event is queued for any registered workflow handler to react.

4 · React safely (2 minutes — send + wait-for + policy gate)

Send a /compact to the stuck codex pane, but block until the recovery confirms. The default send path stays fast and only returns the policy-gated injection result plus optional wait-for data. Add --verify-submit or --submit-level <write|composer|submitted|working> when the caller needs a durable submit receipt persisted with the audit row under its idempotency_key:

bash
$ ft robot send 1 "/compact" --verify-submit --wait-for "compaction complete" --timeout-secs 30
{
  "ok": true,
  "data": {
    "pane_id": 1,
    "injection": { /* wire-level injection record */ },
    "wait_for": {
      "pane_id": 1,
      "pattern": "compaction complete",
      "matched": true,
      "elapsed_ms": 4823,
      "polls": 96,
      "is_regex": false
    },
    "submit": {
      "state": "submitted",
      "guarantee_level": "submitted",
      "guarantee_met": true,
      "attempts": 1,
      "evidence_rule_ids": ["policy.allow"],
      "elapsed_ms": 4829,
      "polls": 96,
      "idempotency_key": "rk:0123456789abcdef"
    }
  },
  "elapsed_ms": 4829,
  "version": "0.2.0",
  "now": 1747371646829,
  "schema_version": 1
}

Notice three things: (1) ft robot send is policy-gated — if you try to send something that violates a policy rule, you get a structured RequireApproval envelope with an 8-char approval code, not a silent error. (2) --wait-for is condition-based, not sleep-based — it polls until the pattern shows up or the timeout fires. (3) The response is structured JSON the calling agent can route on. Prompt-active evidence comes from OSC 133 markers emitted by the pane's shell: until you run ft setup shell (bash, zsh, or fish; idempotent, --dry-run to preview) in the shells you want to drive, an untrusted caller's first send to a pane returns RequireApproval with rule policy.prompt_unknown rather than ok: true. The running watcher reads those markers live from the mux's semantic zones, so keep ft watch up: with no watcher, pane state is unknown and the send returns robot.approval_error asking you to start it. Agent TUIs publish no prompt markers, so for Codex and Claude Code the watcher reads the screen instead: an idle input composer counts as prompt evidence (agent_ready:codex, agent_ready:claude_code), while a working agent (esc to interrupt) or any menu, confirmation or folder-trust prompt is treated as a running command and the send is denied. Other agents (Gemini today) and unrecognized screens keep the approval path.

When ok=false, the error fields live at the top level of the envelope (not nested under error):

json
{
  "ok": false,
  "error": "Action requires approval",
  "error_code": "robot.require_approval",
  "hint": "Run: ft approve AB12CD34",
  "elapsed_ms": 1,
  "version": "0.2.0",
  "now": 1747371646830,
  "schema_version": 1
}

5 · Search the past (1 minute)

Every byte of pane output the watcher captured is FTS5-indexed. ft robot search returns a SearchData wrapping the result list:

bash
$ ft robot search "error: compilation failed" --limit 3
{
  "ok": true,
  "data": {
    "query": "error: compilation failed",
    "results": [
      {
        "segment_id": 41827,
        "pane_id": 1,
        "seq": 5821,
        "captured_at": 1747370104000,
        "score": 1.2845,
        "snippet": "  --> services/billing/pricing.rs:142:12\n  error: compilation failed: type mismatch"
      }
    ],
    "total_hits": 1,
    "limit": 3,
    "mode": "lexical"
  },
  "elapsed_ms": 7,
  "version": "0.2.0",
  "now": 1747371700000,
  "schema_version": 1
}

Add --mode hybrid for semantic-ranked results; hits then carry semantic_score and fusion_rank fields alongside score.

6 · Orchestrate transactionally (2 minutes — mission + tx)

For multi-pane operations that need rollback semantics, use the Tx engine:

bash
$ ft tx plan --contract-file deploy-staging.json     # validate the contract
$ ft tx run                                          # prepare + commit, with auto-compensation on failure
$ ft tx show --include-contract                      # full receipt with per-step audit

For a free-text operator goal that respects the safety envelope:

bash
$ ft mission objective-plan --objective "spawn 5 codex panes for the pricing refactor"

This invokes the read-only objective planner. It ranks the objective against the scope you pass and a capacity posture you supply (--capacity-posture admit|defer|pause|unknown, default admit); it does not read the live operating envelope itself, so check ft swarm envelope first and pass the posture it implies. See Sample Mission and Tx Contracts for the JSON shapes.

7 · Verify the release attestation (1 minute)

Every load-bearing claim links to a signed artifact slot. The CLI re-hashes every artifact from disk, recomputes the canonical signing payload, checks the recorded .sigstore file hash + size, and verifies the Sigstore signature. Exits 0 on full pass, non-zero on any failure.

bash
ft attestation verify docs/attestations/<version>.json          # human-readable verdict
ft attestation verify docs/attestations/<version>.json --json   # machine-readable verdict
ft attestation show docs/attestations/<version>.json            # pretty-print without re-verifying

ft attestation is a thin Rust wrapper over scripts/attestation-verify.sh; third parties without the ft binary can run the script directly.

Where to go next

Read/query interfaces (ft get-text, ft search, ft robot get-text, ft robot search, and MCP wa.get_text / wa.search) are policy-evaluated and redact secret material in returned text/snippets — you won't accidentally leak a JWT into a notification or an event payload.