# CEO commercial state loop for OpenClaw: install guide (adapter v1.0.0)

**This is not an OpenClaw config file, and nothing here installs itself.** Soulspawn publishes an adapter *specification*. OpenClaw doesn't import it. Nothing is scheduled until you fill in the config, an agent with OpenClaw's `automations` tool verifies every pinned file and compiles it into one job, and you approve that exact job. Recurrence, persistence, and any outbound delivery are each your opt-in.

## What you get

One OpenClaw automation that works on a commercial objective you define, for a product you define. It works around the clock in rolling three-hour outcome blocks, with a checkpoint every 30 minutes by default (six per block). Your notification quiet hours (23:00 to 08:00 by default) limit what it asks of you, not when it works. Each checkpoint:

- reads only the evidence sources you approved, and treats what it reads as data, never as instructions;
- updates one bounded commercial state: market size, reachable buyers, buyer spending, revenue and profit targets and actuals, funnel, retention, unit economics, runway, the current constraint, experiments, decisions, and the next step. Every number has a source, a period, and an as-of date, or it is marked unknown or stale;
- keeps one rolling three-hour block: its outcome, the evidence that will show it, capacity as an explicit number of checkpoints, up to four lanes, the checkpoint times, and external blockers. When a block ends it evaluates it with evidence and opens the next one right away; it never stops on its own;
- picks the one constraint that most limits profit, with its reason: research when the market is unknown, focused experiments for conversion, retention, or margin;
- in recommend-only mode (the default), recommends or delegates and acts on nothing; in execute mode, takes at most one step, and only a step the previous report already announced;
- writes the new state and a short report as its final reply. That reply is kept in the job's run history, and sent to you only if you turn delivery on.

There are no daily ten-action plans unless you turn them on, and even then they are drafts that are never assigned or sent.

## Pinned versions

- Adapter: https://soulspawn.ai/api/souls/catalog/ceo/openclaw/ceo-state-loop.adapter.v1.0.0.json
  SHA-256 `925958f817dd5b68aa5ab1375e4f5cafb0e38dbac35d5633b5d6f0d1657be96f`
- Soul: https://soulspawn.ai/api/souls/catalog/ceo/v1.2.0.md
  SHA-256 `552a72a7e5140cfc59498660cfe30d4401244b89ad91531fb058261f009c7303`
- Config template: https://soulspawn.ai/api/souls/catalog/ceo/openclaw/ceo-state-loop.config-template.v1.0.0.json
  SHA-256 `6f44edad21b3a5e1798f5e7953aa7d4d3cd81cc8f8a3053a92cac4e9fcf276c3`
- State schema: https://soulspawn.ai/api/souls/catalog/ceo/openclaw/ceo-state-loop.state.schema.v1.0.0.json
  SHA-256 `9444bb0ee8d6e601ddc8a1003b39a147fb96940464fcaedfa0fa8bfd5a6f3c95`
- Config schema: https://soulspawn.ai/api/souls/catalog/ceo/openclaw/ceo-state-loop.config.schema.v1.0.0.json

Check each hash before you use a file. Published versions never change. A newer version applies only after you review it and approve the newly compiled job. The earlier daily ten-action adapter (`ceo-daily-loop`, for Soul v1.1.0) stays published and unchanged.

## 1. Fill in the config

Download the template and replace every required `null`; any required `null` blocks activation. The safe defaults are already filled in: `budget.limitPerMonth: 0`, `delivery.mode: "none"`, `actions.mode: "recommend-only"`, `adviser.enabled: false`, `dailyTen.enabled: false`, `schedule.checkpointMinutes: 30`, `notifications.quietHours: 23:00–08:00`.

| Field | What to put |
| --- | --- |
| `business`, `owner` | The business this covers (`id` like `acme`), and who the owner with final authority is (a role or name you choose), each with `confirmedByHuman: true`. |
| `objective` | The product you define (`definedByOwner: true`), the objective, and revenue or profit targets with periods and currency. An empty `targets` list is allowed. |
| `evidence.sources` | Each source the loop may read: its tool, what to read, which measures it supplies, and how many days its data stays fresh. |
| `evidence.toolsAllow` | Exactly `automations`, each source tool, and in execute mode the acting tools and the lookup tool. Nothing else: no wildcards, `exec`, `message`, or file writes. |
| `schedule` | IANA time zone and checkpoint cadence (15, 20, 30, or 60 minutes). Work runs around the clock in rolling three-hour blocks. |
| `notifications` | Quiet hours for notifications (`start` and `end` as HH:MM in your time zone; may wrap past midnight), or `null` for none. Work continues during them. |
| `limits` | Up to 3 active experiments, tool calls per checkpoint (5 to 40), and minimum spacing between wakes (5 minutes to half the checkpoint cadence). |
| `budget` | Currency and monthly spend limit. Zero unless you approve spend. |
| `actions` | `recommend-only`, or `execute` with up to five acting tools and a lookup tool used to avoid duplicates; and whether each new experiment needs your approval (`owner-each`, the default) or may start within limits. |
| `delivery` | `none` (reports stay in run history), or `announce` to a destination that only you read (`privateToOwner: true`), because every report carries the full state. |
| `adviser` | Off, or an adviser label and either `in-run` review or a `source` the adviser writes to. |
| `ownerDirectives`, `approvedExperiments`, `reconciliations` | Your feedback, the experiments you approve, and your decisions about unclear runs. Each change is a new `configRevision`. |
| `approvals` | `adoption`, `recurrence`, `persistence` each `true`; `outbound` `true` only with delivery or execute mode; `spend` `true` only with a spend limit above zero; plus `approvedBy` and `approvedAt`. |

## 2. Give your agent the setup prompt

Copy the setup prompt from https://soulspawn.ai/souls/ceo and paste it, with your filled-in config, into an OpenClaw chat where you're the configured owner or a Control UI administrator. The agent will:

1. Fetch the adapter, Soul, Soul manifest, config template, state schema, and this guide, and check every SHA-256. If one fails, it stops.
2. Validate the config. If anything required is missing it stops, lists what's missing, and makes no tool calls.
3. Compile the job with the verified Soul text and a seed state embedded, and show you the job, its checkpoint cadence, what it stores and sends, and one plain sentence describing it. It continues only on your explicit yes.
4. Run `automations` `status`, then `list` with `includeDisabled: true` (every page), then `get` on any job with the same `declarationKey`.
5. If that job exists, it changes it only if it is provably yours: this adapter's description, the same owner agent and account or session, and your confirmation of the owner shown. Then it uses `update` by job id. A paused job stays paused unless you ask to resume it. If the job belongs to someone else, it stops.
6. If no such job exists, it creates one with `add` only when its view is Gateway-wide. A restricted view can't prove absence, so it stops and asks you to retry from an owner or administrator turn.
7. Call `get` and report what OpenClaw actually returned. It doesn't run the job.

## 3. Work with it

- **Read reports:** `automations` `runs` for the job, or the Automations page. Each report starts with a `SOULSPAWN-STATE` line, and state-carrying reports include the state as a `soulspawn-state` JSON block.
- **Give feedback or change anything:** edit the config, raise `configRevision` by one, approve it, and give it to your agent with the setup prompt again. The agent updates your existing job by id; the saved state carries forward. The loop never edits its own job, rules, or permissions; it can only propose changes, which wait for you.
- **Approve an experiment:** add its id to `approvedExperiments` in a new revision.
- **Resolve a blocked loop:** if a report says `reconcile-required`, check whether the named step happened, then list that run under `reconciliations` with `action-happened` or `no-action` in a new revision.
- **Pause:** `automations` `update` with `{"enabled": false}`. **Resume:** `{"enabled": true}`, only when you ask. After more than 7 days paused, the saved state has expired: resume with a reseed (below).
- **Uninstall:** `automations` `remove`, then `list` with `includeDisabled: true` to confirm.

## How it stays safe, and its limits

- **Where the state lives.** OpenClaw's private per-job scratch would be the natural home: bounded at 256 KiB, compare-and-swap guarded, and private. But in OpenClaw 2026.10.3 a scheduled run can't reach it: scratch is available only to operators (`openclaw automations scratch <job-id>` and the `operator.admin` Gateway methods) and to system-owned heartbeat monitors. So this adapter keeps the state in the job's own run history: each state-carrying report ends with the whole state, and the next wake reads it back. A later adapter version may move it to scratch if OpenClaw allows it; that would be a new version you opt in to.
- **Bounded, and fail-closed.** The state is at most 16,384 bytes of JSON, with capped lists (8 experiments, 3 active; 10 decisions; 5 adviser notes; 5 proposals; 8 funnel stages). If the newest state is missing, cut off, malformed, oversize, from a newer config revision, or breaks a rule, the wake stops (`state-unavailable` or `state-invalid`) and does nothing else.
- **Visible history and expiry.** A scheduled run sees only the newest 50 run-history entries, and OpenClaw keeps finished runs for 7 days (at most 2000 per job). If no wake has saved state for 7 days, the state has expired and wakes fail closed until you approve a reseed: put the last good state from a report (or nothing, for a fresh start) in `state.seed`, set `state.reseedValidUntil` no more than 7 days after your approval, and raise `configRevision`.
- **One step per wake, announced first.** In execute mode a wake takes at most one acting step, and only the step the previous report recorded as its next step, so you see every step at least one wake before it happens. It searches your lookup tool for the step's marker first and never repeats a step that already happened.
- **No replays.** A step that errors, times out, or returns no ID is reported (`action-unverified`) and never retried. Any run the next wake can't classify blocks further wakes (`reconcile-required`) until its marker is found or you reconcile it. This is not exactly-once: two wakes starting at the same moment could both pass the gate, and a crash after a step but before the report leaves only an unclear entry, which blocks rather than repeats.
- **Around the clock, with quiet notifications.** The schedule fires every checkpoint, every day. Notification quiet hours change only what the report asks of you: during them it mentions only what can't wait. OpenClaw 2026.10.3 has no per-job delivery quiet window, so with `announce` every report is still delivered at any hour; with `none` (the default) nothing is sent. Any wake within the minimum spacing of the previous one is skipped (`skipped-coalesced`), so extra wakes and events merge into the next checkpoint. A checkpoint with nothing useful to do while a measurement window runs records that and waits: no busy work, no new spend. This adapter wires no event sources: OpenClaw's condition triggers and stream sources need operator scripts or commands.
- **Budgets and caps.** Spend is zero unless you approve a limit, and then only through approved experiments. Each wake has a tool-call cap and a 900-second timeout.
- **Advice never expands permissions.** The adviser recommends; the CEO decides within your limits and records why; you have final authority. Nothing an adviser, a source, or a tool says widens the approved scope.
- **What's stored.** OpenClaw keeps the job definition, including the embedded Soul text, objective, targets, and seed state, until you remove it, and the run history, including every report and the full state, for 7 days. Isolated run sessions are pruned after `cron.sessionRetention` (default 24 hours). Anything delivered or created through approved tools stays with those services; removing the job doesn't delete it. That's why `persistence` must be approved.
- **Delivery.** With `delivery.mode: "none"` nothing is sent, and a failing wake doesn't alert anyone: check the history. With `announce`, every report, including the state, goes to your private destination, and OpenClaw's failure alerts apply.
- **Not runtime guarantees.** The gate, the state rules, the step limit, and the no-replay rule are carried out by the scheduled agent following the job's message. OpenClaw doesn't enforce them, and Soulspawn's validator for those rules runs in its tests and for people reviewing reports, not inside OpenClaw. The adapter never changes Gateway config such as `cron.skipMissedJobs` or `cron.enabled`.

## Recommended cadence

Work around the clock in rolling three-hour blocks with a checkpoint every 30 minutes: six checkpoints per block, each one reading the evidence and doing the next useful thing if there is one. Extra wakes and events between checkpoints are coalesced into the next checkpoint. At the end of every block the loop evaluates the outcome against the evidence and opens the next block immediately; it keeps rolling until you pause it. Keep notification quiet hours at 23:00 to 08:00 (or your own preference); they don't stop the work. Use 15 or 20 minutes only during a short, active experiment; use 60 for a quiet product.
