cloud / .agents / skills / cloud-rehearsal / SKILL.mdmain at aacbc74
---
name: cloud-rehearsal
description: Set up a rehearsal of iterate Cloud's sign-up chat against a fake Cloudflare. Use when someone asks to set up, start, run or stop a cloud rehearsal ("set up a cloud rehearsal on tthq"), to rehearse, simulate or eval the Cloud sign-up or install chat, or to try the install guide against a Cloudflare condition (a slow card page, an account with no card, an existing domain).
---
# cloud-rehearsal
"Set up a cloud rehearsal on tthq" is a whole request. Ask nothing. From the repo's root:
```sh
node scripts/cloud-rehearsal/start.ts --mind tthq.app
```
It takes about half a minute and makes no commit. Answer with the chat's link, which it prints.
"tthq" is Misha's test mind, `tthq.app`.
## What they may add
- **How Cloudflare should behave** ("the card is already added", "the card page stays shut for
five minutes"): pass their words as they are, `--scenario "<their words>"`. Without it the world
is the usual start: an old account with a card and Workers Paid, and a new account named iterate
with no card, whose card page opens two minutes after the consent.
- **A draft of the guide**: `--guide <file>`. Without it the sign-up agent is told the mind's own
draft when it has one (`apps/cloud-rehearsal/onboarding.md` in its config repo, which people
edit at `https://docs.<mind>/?doc=apps/cloud-rehearsal/onboarding.md`), else iterate Cloud's own
guide as it is on GitHub now. A draft must name the agent's tools as that guide does.
- **Another person** who plays the new person: `--person "First Last <email>"`. Without it, the
person the CLI is signed in to the mind as.
- **Another mind**: `--mind <domain>`.
## The hand-over at the end is real
Everything of Cloudflare is fake. The hand-over is not: when the person picks a domain where a real mind runs, the rehearsal sends that mind a sign-up record through the mind meld, and its onboarding agent gets it once the owner signs the rule at the link the chat gives (`scripts/cloud-rehearsal/README.md`, "The hand-over is real").
- Put a real mind's domain into the scenario only when they ask for a hand-over ("… and hand over to benjerate.com"): `--scenario "The new account already owns benjerate.com, and its zone is active."`
- Never the domain of a mind that somebody uses: its onboarding agent would get a stranger's record. Ask when you are not sure whose it is.
- With any other domain the chat's hand-over step never arrives. That is a fine end for a rehearsal of the steps before it.
## When the start refuses
Each refusal says what to do. Do it, then start again.
- **"iterate Cloud's app changed since the rehearsal app was copied"**: the rehearsal app is a copy
of iterate Cloud's app, and that has moved on. Bring the changes over
(`scripts/cloud-rehearsal/README.md`, "When iterate Cloud's app changes"). It is part of setting
up: a rehearsal of yesterday's Cloud misleads. Say in your answer what you brought over. Only
when they want the old one as it is: `--stale-app`.
- **"This mind has no rehearsal app, or not this checkout's"**:
`node scripts/cloud-rehearsal/install.ts --mind <domain>`. That is one commit to the mind's
config repo: say so in your answer.
- **"The CLI is not signed in"**: `iterate login <domain>`, which the person approves.
- **"No agent can be the fake's author"**: neither `claude -p` nor `codex exec` works on this
machine. Tell the person which one to sign in to.
## While it runs
The run's folder is `scripts/cloud-rehearsal/runs.ignoreme/fake-cf-<time>/`.
- `run.jsonl` is every call and who answered it. "agent" means that the author wrote a rule for
it. "Cloudflare's routes: no such route" means that the chat called something that is not
Cloudflare's API.
- To change the rehearsal under way (a wait, a card, a domain), edit `world.json`. To change an
answer, add a rule to `rules.mjs` (`RULES.md` beside it).
- A rule that every rehearsal should have goes into `scripts/cloud-rehearsal/base-rules.ts`, with a
test in `fake-cloudflare.test.ts`.
## Stopping one
`node scripts/cloud-rehearsal/stop.ts fake-cf-<time>`. `pids.json` in a run's folder means that it
was started; `ps -p <pid>` says whether it still runs. The folder and the chat in the mind stay:
they are the record. To take the mind's part away, see the README's "Removing a rehearsal from a
mind".