A reflex is a small decision xcb makes many times a day and can learn from how you respond. Two ship today: route picks the frontier or standard model tier for a new task, and settle categorizes how a worker's turn ended, including whether it stopped before the task was done.
xcb reflex # status of both reflexes
xcb reflex status route # generation, program digest, labels, holdout metricsHow a decision is made
Each decision is a small ALGAL program applied to deterministic features, learned parameters, and typed evidence. The program has no effects and makes no model calls, so every decision is a replayable receipt. Parameters are data: learning adds a generation and never edits the program.
| Reflex | Reads | Decides | Default |
|---|---|---|---|
| route | Prompt shape (imperative opening, resume language, action verbs, length), keyword cues, and the optional judge's answers | frontier or standard | active |
| settle | The end of the worker's last message (a promised next step, waiting on CI, open checklist items, completion claims) and the turn's settlement facts | done, stopped short, question, needs approval, blocked, interrupted, … | observe |
The shipped parameters reproduce xcb's behavior before reflexes, so nothing changes until your own evidence earns a promotion.
How it learns from you
- Reply
continue,keep going, orproceedright after a task completes, and xcb records that the turn stopped short. With settle active, it also reopens that task in its session. - Start something else after a task completes, and that turn is recorded as finished, at half weight.
- Ask for a stronger or lighter model (“use opus”, “cheaper model”) and the previous task's route is labeled.
- Label anything explicitly. Explicit labels always win over inferred ones.
xcb reflex label route t_… frontier
xcb reflex label settle t_… unfinished
xcb reflex train settleEvery 16 labels, xcb fits a candidate anchored on the shipped prior. One fifth of your labels is a fixed holdout that training never sees. A candidate replaces the active generation only if the holdout has at least five examples of each class and the candidate lowers log loss there without losing accuracy or ranking quality. Every generation records its parent and the evidence that promoted it.
Continuing work that stopped short
With settle set to active, a completed turn categorized as stopped short is continued in its existing session with a prompt to carry out the step it described. The same gates as any automatic continuation apply first: a joined and settled worker, no pending question or approval, no failure or uncertain effect, a response that is not a repeat, and remaining attempt and time budget. A configured judge can still veto it.
Configure, roll back, or replace
# config.json → extensions.reflexes
{ "route": "active", "settle": "observe", "learn": true }
xcb reflex rollback route 0 # back to the shipped prior
xcb reflex import route history.jsonl
xcb reflex check my-route.algal.jsonEach reflex can be off, observe, or active. To change the decision logic itself, put an organism at reflexes/route.algal.json or reflexes/settle.algal.json in the state directory. xcb admits it only if it has no effectful cells and no agent calls; otherwise status reports the rejection and the shipped program runs.
The ledger stores numeric features, decisions, and labels, never prompt or response text. A learned route predicts the tier you would pick, not measured model quality. It only chooses between routes that are already eligible and cannot demote the quality floor for large prompts. See the reflex reference for the full contract.