{
  "$schema": "https://pi-tui.ratstack.sh/schema/pattern.schema.json",
  "aka": [
    "Human takeover"
  ],
  "animated": true,
  "apis": [
    {
      "name": "ctx.ui.custom",
      "url": "https://github.com/earendil-works/pi/blob/v1.0.3/packages/coding-agent/docs/tui.md#use-custom-screens-and-overlays"
    },
    {
      "name": "Component",
      "url": "https://github.com/earendil-works/pi/blob/v1.0.3/packages/coding-agent/docs/tui.md#understand-the-component-model"
    },
    {
      "name": "TUI.requestRender",
      "url": "https://github.com/earendil-works/pi/blob/v1.0.3/packages/coding-agent/docs/tui.md#understand-the-component-model"
    },
    {
      "name": "custom",
      "url": null
    },
    {
      "name": "Box",
      "url": null
    },
    {
      "name": "DynamicBorder",
      "url": null
    },
    {
      "name": "matchesKey",
      "url": null
    }
  ],
  "applicability": [
    "Use this when long-running terminal work alternates between agent and human control."
  ],
  "category": "keys",
  "categoryLabel": "Keys and focus",
  "consequences": [
    "Agent and human control can alternate without closing the view.",
    "Takeover must flush pending output and respect update budgets."
  ],
  "family": "behavioral",
  "familyLabel": "Behavioral",
  "id": "control-baton",
  "implementation": [
    "Flush pending output before takeover.",
    "Bound per-update and total output budgets."
  ],
  "intent": "Pause automatic output updates while the user controls an interactive job.",
  "jsonUrl": "https://pi-tui.ratstack.sh/patterns/control-baton.json",
  "kind": "screen",
  "knownUses": [
    {
      "example": "shell-handsfree-control",
      "moreRefs": 0,
      "refs": [
        {
          "file": "overlay-component.ts",
          "lines": "300-445",
          "sha": "77df9a81",
          "url": "https://github.com/nicobailon/pi-interactive-shell/blob/77df9a8142a2f731635a4c5a01d68feecb5cced4/overlay-component.ts#L300-L445"
        }
      ],
      "repo": "pi-interactive-shell",
      "repoUrl": "https://github.com/nicobailon/pi-interactive-shell",
      "title": "Separate hands-free updates from user takeover"
    }
  ],
  "linkedFrom": [
    {
      "how": "changes control ownership",
      "id": "action-sieve",
      "jsonUrl": "https://pi-tui.ratstack.sh/patterns/action-sieve.json",
      "mdUrl": "https://pi-tui.ratstack.sh/patterns/action-sieve.md",
      "name": "Action Sieve",
      "url": "https://pi-tui.ratstack.sh/patterns/action-sieve/"
    }
  ],
  "links": {
    "agentGuide": "https://pi-tui.ratstack.sh/llms.txt",
    "index": "https://pi-tui.ratstack.sh/patterns.md",
    "skill": "https://pi-tui.ratstack.sh/skills/build-pi-tui-component.md"
  },
  "mdUrl": "https://pi-tui.ratstack.sh/patterns/control-baton.md",
  "motivation": "Interactive Shell must stop automatic output updates when a human takes over its live terminal.",
  "name": "Control Baton",
  "participants": [
    {
      "name": "ctx.ui.custom",
      "role": "Mounts one interaction and resolves through done.",
      "url": "https://github.com/earendil-works/pi/blob/v1.0.3/packages/coding-agent/docs/tui.md#use-custom-screens-and-overlays"
    },
    {
      "name": "Component",
      "role": "Renders width-bounded lines and invalidates cached output.",
      "url": "https://github.com/earendil-works/pi/blob/v1.0.3/packages/coding-agent/docs/tui.md#understand-the-component-model"
    },
    {
      "name": "TUI.requestRender",
      "role": "Requests a coalesced redraw after state changes.",
      "url": "https://github.com/earendil-works/pi/blob/v1.0.3/packages/coding-agent/docs/tui.md#understand-the-component-model"
    },
    {
      "name": "Control state",
      "role": "Separates automatic updates from human terminal control.",
      "url": null
    }
  ],
  "pi": "1.0.3",
  "related": [
    {
      "how": "offers only valid handoff actions",
      "id": "action-sieve",
      "jsonUrl": "https://pi-tui.ratstack.sh/patterns/action-sieve.json",
      "mdUrl": "https://pi-tui.ratstack.sh/patterns/action-sieve.md",
      "name": "Action Sieve",
      "url": "https://pi-tui.ratstack.sh/patterns/action-sieve/"
    }
  ],
  "sampleCode": {
    "code": "// Control Baton: flush pending output before handing a synthetic job to a human.\n// Machine: automatic --takeover/flush--> human --return--> automatic.\nimport { Box, Text, matchesKey, type Component } from \"@earendil-works/pi-tui\";\nimport { DynamicBorder } from \"@earendil-works/pi-coding-agent\";\nimport type { PatternStory } from \"../../../src/pattern.ts\";\n\nexport const story: PatternStory = {\n  id: \"control-baton\",\n  title: \"Control Baton\",\n  kind: \"screen\",\n  apis: [\"custom\", \"Component\", \"TUI.requestRender\", \"Box\", \"DynamicBorder\", \"matchesKey\"],\n  states: [\n    { id: \"automatic\", label: \"Automatic updates\", animated: true, steps: [{ type: \"tick\", ms: 700 }] },\n    { id: \"takeover\", label: \"Human control\", animated: true, steps: [\n      { type: \"keys\", data: \"h\" }, { type: \"tick\", ms: 500 }, { type: \"keys\", data: \"n\" },\n    ] },\n    { id: \"returned\", label: \"Agent control\", animated: true, steps: [\n      { type: \"keys\", data: \"a\" }, { type: \"tick\", ms: 700 },\n    ] },\n  ],\n  setup({ ui, theme }) {\n    ui.setHeader(() => new Text(theme.fg(\"accent\", \"Pi · Control Baton\"), 0, 0));\n    ui.setEditorText(\"Explain the parser test results\");\n    ui.setWidget(\"job-context\", [theme.fg(\"muted\", \"Job: token boundary test suite\")]);\n    void ui.custom((tui, panelTheme, _keys, done) => {\n      let owner: \"automatic\" | \"human\" = \"automatic\";\n      let produced = 0;\n      let pending: string[] = [];\n      let visible: string[] = [];\n      let lastHandoff = \"No handoff yet\";\n      const panel = new Box(1, 0, line => panelTheme.bg(\"customMessageBg\", line));\n      const content = new Text(\"\", 0, 0);\n      panel.addChild(new DynamicBorder(line => panelTheme.fg(\"borderAccent\", line)));\n      panel.addChild(content);\n      panel.addChild(new DynamicBorder(line => panelTheme.fg(\"borderAccent\", line)));\n      function flush() {\n        // At most two lines per flush and three lines retained in the view.\n        visible = [...visible, ...pending.splice(0, 2)].slice(-3);\n      }\n      const timer = setInterval(() => {\n        if (owner !== \"automatic\") return;\n        pending.push(\"check \" + (++produced) + \" · token case passed\");\n        if (pending.length >= 2) flush();\n        tui.requestRender();\n      }, 200);\n      const job: Component & { dispose(): void } = {\n        invalidate() { panel.invalidate(); },\n        dispose() { clearInterval(timer); },\n        handleInput(data) {\n          if (matchesKey(data, \"h\") && owner === \"automatic\") {\n            const count = pending.length;\n            flush();\n            owner = \"human\";\n            lastHandoff = \"Flushed \" + count + \" pending line\";\n          } else if (matchesKey(data, \"a\")) owner = \"automatic\";\n          else if (matchesKey(data, \"n\") && owner === \"human\") {\n            visible = [...visible, \"human > inspect next case\"].slice(-3);\n          } else if (matchesKey(data, \"escape\")) done(undefined);\n          tui.requestRender();\n        },\n        render(width) {\n          content.setText([\n            panelTheme.fg(\"accent\", \"Token tests · \" + (owner === \"human\" ? \"HUMAN\" : \"AGENT\")),\n            panelTheme.fg(owner === \"human\" ? \"warning\" : \"success\",\n              owner === \"human\" ? \"Auto updates PAUSED\" : \"Auto updates ACTIVE\"),\n            ...visible.map(line => panelTheme.fg(\"toolOutput\", line)),\n            panelTheme.fg(\"muted\", \"Produced \" + produced + \" · pending \" + pending.length),\n            panelTheme.fg(\"dim\", lastHandoff),\n            panelTheme.fg(\"muted\", owner === \"human\" ? \"n inspect · a return · Esc close\" : \"h take over · Esc close\"),\n          ].join(\"\\n\"));\n          return panel.render(width);\n        },\n      };\n      return job;\n    }, { overlay: true, overlayOptions: { width: \"85%\", anchor: \"top-center\", row: 1, margin: 1 } });\n    return () => ui.setWidget(\"job-context\", undefined);\n  },\n};\n",
    "lang": "ts",
    "path": "stories/patterns/behavioral/control-baton.ts"
  },
  "states": [
    {
      "dont": false,
      "expectFail": [],
      "frames": [
        {
          "alt": "Control Baton, Automatic updates state, 40 columns, dark theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-40-dark.anim.a720783e5016.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-40-dark.ce381821bfe8.webp",
          "theme": "dark",
          "w": 800,
          "width": 40
        },
        {
          "alt": "Control Baton, Automatic updates state, 40 columns, light theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-40-light.anim.25a3a5c5a619.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-40-light.78b74e21c901.webp",
          "theme": "light",
          "w": 800,
          "width": 40
        },
        {
          "alt": "Control Baton, Automatic updates state, 60 columns, dark theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-60-dark.anim.278aea753a84.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-60-dark.3064098fffce.webp",
          "theme": "dark",
          "w": 1200,
          "width": 60
        },
        {
          "alt": "Control Baton, Automatic updates state, 60 columns, light theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-60-light.anim.251129869752.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-60-light.2c33bdad37f6.webp",
          "theme": "light",
          "w": 1200,
          "width": 60
        },
        {
          "alt": "Control Baton, Automatic updates state, 80 columns, dark theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-80-dark.anim.2863f18ffcd2.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-80-dark.42c048d94fb2.webp",
          "theme": "dark",
          "w": 1600,
          "width": 80
        },
        {
          "alt": "Control Baton, Automatic updates state, 80 columns, light theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-80-light.anim.5593ba75e009.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-80-light.8231551afcc7.webp",
          "theme": "light",
          "w": 1600,
          "width": 80
        },
        {
          "alt": "Control Baton, Automatic updates state, 120 columns, dark theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-120-dark.anim.03c4b92ae9de.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-120-dark.eb44e6e47483.webp",
          "theme": "dark",
          "w": 2400,
          "width": 120
        },
        {
          "alt": "Control Baton, Automatic updates state, 120 columns, light theme, 11 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-120-light.anim.519759d19cdb.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 484,
          "rows": 11,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/automatic-120-light.325aa09b85c2.webp",
          "theme": "light",
          "w": 2400,
          "width": 120
        }
      ],
      "how": "Show a synthetic job with bounded agent progress updates.",
      "id": "automatic",
      "label": "Automatic updates",
      "problems": []
    },
    {
      "dont": false,
      "expectFail": [],
      "frames": [
        {
          "alt": "Control Baton, Human control state, 40 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-40-dark.anim.89a7a6e5f450.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-40-dark.77fbc071ca21.webp",
          "theme": "dark",
          "w": 800,
          "width": 40
        },
        {
          "alt": "Control Baton, Human control state, 40 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-40-light.anim.ebbccf4b45e0.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-40-light.466e42254254.webp",
          "theme": "light",
          "w": 800,
          "width": 40
        },
        {
          "alt": "Control Baton, Human control state, 60 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-60-dark.anim.fe2d11873dba.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-60-dark.be43e7a688bd.webp",
          "theme": "dark",
          "w": 1200,
          "width": 60
        },
        {
          "alt": "Control Baton, Human control state, 60 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-60-light.anim.1c5532cf1ceb.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-60-light.1cab1c3dd338.webp",
          "theme": "light",
          "w": 1200,
          "width": 60
        },
        {
          "alt": "Control Baton, Human control state, 80 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-80-dark.anim.2dc8669bb66e.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-80-dark.c965fb9e7839.webp",
          "theme": "dark",
          "w": 1600,
          "width": 80
        },
        {
          "alt": "Control Baton, Human control state, 80 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-80-light.anim.bfa48aa18714.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-80-light.2d6260cbe18d.webp",
          "theme": "light",
          "w": 1600,
          "width": 80
        },
        {
          "alt": "Control Baton, Human control state, 120 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-120-dark.anim.201d7a934be6.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-120-dark.15ce09a0929a.webp",
          "theme": "dark",
          "w": 2400,
          "width": 120
        },
        {
          "alt": "Control Baton, Human control state, 120 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-120-light.anim.4369c548a019.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/takeover-120-light.05b9ca18dfa6.webp",
          "theme": "light",
          "w": 2400,
          "width": 120
        }
      ],
      "how": "Flush pending output and show that automatic updates have stopped.",
      "id": "takeover",
      "label": "Human control",
      "problems": []
    },
    {
      "dont": false,
      "expectFail": [],
      "frames": [
        {
          "alt": "Control Baton, Agent control state, 40 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-40-dark.anim.4a6a60656e8f.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-40-dark.47412eabb1e0.webp",
          "theme": "dark",
          "w": 800,
          "width": 40
        },
        {
          "alt": "Control Baton, Agent control state, 40 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-40-light.anim.38a09ed05d57.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-40-light.ff72be03adb4.webp",
          "theme": "light",
          "w": 800,
          "width": 40
        },
        {
          "alt": "Control Baton, Agent control state, 60 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-60-dark.anim.19b84d938905.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-60-dark.962e7606beb2.webp",
          "theme": "dark",
          "w": 1200,
          "width": 60
        },
        {
          "alt": "Control Baton, Agent control state, 60 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-60-light.anim.770700ec3322.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-60-light.461a3340f314.webp",
          "theme": "light",
          "w": 1200,
          "width": 60
        },
        {
          "alt": "Control Baton, Agent control state, 80 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-80-dark.anim.08a6cade3789.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-80-dark.05bc7938aa5a.webp",
          "theme": "dark",
          "w": 1600,
          "width": 80
        },
        {
          "alt": "Control Baton, Agent control state, 80 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-80-light.anim.44e3a81be1fd.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-80-light.ca96f7e077c6.webp",
          "theme": "light",
          "w": 1600,
          "width": 80
        },
        {
          "alt": "Control Baton, Agent control state, 120 columns, dark theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-120-dark.anim.ce7b41d1b8f5.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-120-dark.74c211742a05.webp",
          "theme": "dark",
          "w": 2400,
          "width": 120
        },
        {
          "alt": "Control Baton, Agent control state, 120 columns, light theme, 12 rows, animated",
          "animated": true,
          "animation": "https://pi-tui.ratstack.sh/frames/control-baton/returned-120-light.anim.db1d2c28a81c.webp",
          "checks": [
            {
              "evidence": [],
              "name": "width",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "style-leak",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "hard-coded-colour",
              "status": "pass",
              "verdict": "pass"
            },
            {
              "evidence": [],
              "name": "height",
              "status": "pass",
              "verdict": "pass"
            }
          ],
          "h": 528,
          "rows": 12,
          "still": "https://pi-tui.ratstack.sh/frames/control-baton/returned-120-light.a6b4e9bce85a.webp",
          "theme": "light",
          "w": 2400,
          "width": 120
        }
      ],
      "how": "Return control and resume bounded automatic updates.",
      "id": "returned",
      "label": "Agent control",
      "problems": []
    }
  ],
  "structure": "agent updates -> flush\nflush -> human control\nreturn -> agent updates",
  "thumbnails": {
    "dark": {
      "animation": "https://pi-tui.ratstack.sh/thumbs/control-baton/dark.anim.9e6e99ca7f96.webp",
      "src": "https://pi-tui.ratstack.sh/thumbs/control-baton/dark.f8eb6b1837ce.webp"
    },
    "light": {
      "animation": "https://pi-tui.ratstack.sh/thumbs/control-baton/light.anim.bae867217cee.webp",
      "src": "https://pi-tui.ratstack.sh/thumbs/control-baton/light.669eb6ae6559.webp"
    }
  },
  "url": "https://pi-tui.ratstack.sh/patterns/control-baton/",
  "widths": [
    40,
    60,
    80,
    120
  ]
}
