Execution cron builder

From weiyangzen/b3ehive · View interactive version

Execution cron builder is an AI agent skill from the GitHub repository weiyangzen/b3ehive. Executes one authoritative blueprint as a DAG with isolated workers, oracle gates, master-only acceptance, checkpoints, and cleanup, on cron, tmux, or in-session substrates. Use for long implementation runs or to repair an execution controller. 蓝图执行、DAG 并行。

How to use this skill

Skill file

Execution

For a first user-facing run, read docs/getting-started.md and

docs/skill-selection.md. This skill is a long-run execution protocol, not a

b3ehive execution CLI command.

core v2 · loop v2, default shape single. Read references/core.md and

references/loop.md first; this body adds only execution rules.

Acceptance

canonical checkout, re-runs the item's oracle.full at the item's tier, and

refreshes every status surface, the Gantt projection included.

model family when one is available. Three failed generations: block the item,

then replan it or open a compete run that scores repairs by the oracle.

blueprint checkboxes or oracle paths. CI refuses a [_] -> [x] change unless

a master commit carries the evidence row.

integration, or repair, and passing gates. A persistent_pool ends only on

its frozen stop condition or an operator stop.

Specification

Build the controller from this repository's evidence. Carry no controller,

constant, path, item prefix, route, count, or validator over from another

project. Freeze one versioned specification before install:

live target, hard cap, replacement policy

running turns, request starts, in-flight requests, integrations, validators

An unknown field that could alter source, spend money, publish, or delete fails

closed with its name. Low-risk housekeeping defaults stay overridable and are

labeled as defaults. The controller carries the skill version and spec digest;

b3ehive doctor flags controllers generated by an older skill.

Inspect first: repository instructions, branch and dirty state, candidate

blueprints, build, test, lint, and benchmark entry points, generated and large

paths, host CPU, memory, disk, and accelerators, and existing crons, locks,

ledgers, and workers. Preserve user changes; reset, stash, checkout, and delete

stay off limits.

Blueprint

One file holds requirements and the checklist:

- [ ] [ID] title
  - depends_on: [ID, other#ID]
  - owned_paths: src/x/, verify/gates/ID.sh
  - oracle: verify/gates/ID.sh
  - tier: T1
  - budget: loc<5000
  - canon: [A2]

inferred from document order. When layers exist, close lower layers first.

(<name>_Blueprint.<ext> → <name>_Gantt.<ext>) every tick and never parse

it back. Rules: references/execution-pattern.md §2.

Claims And Workspaces

repository copy per claim needs a DECIDE line showing the oracle needs it.

canonical checkout stays outside their reach. The receipt fingerprint covers

committed, staged, unstaged, and untracked content, so a review binds to the

exact final state.

stale claim.

and at harvest.

Item Loop

attempts stall or whose oracle is weak.

generation it replaces.

Effects And Retries

executes. Route on the loop's result field.

a readback proves it absent; a readback that cannot decide blocks.

backoff; budget exhaustion, schema rejection, and policy refusal never retry.

rejection or lost history.

Workers And Transport

Transport-agnostic invariants:

session, and one task root.

execution holds at most one outstanding request.

route, session, and goal.

persistent_pool keeps a live generation until stop or proved death, then

replaces it without exceeding the cap.

counts against every cap.

only an audited operator reset closes it.

Codex workers follow references/transport-codex-tui.md in full. Other runners

follow references/substrate-cron.md.

Admission

turns, request starts per window, in-flight requests, integrations, validator

leases, and path conflicts.

before each launch.

ends, or a named limit binds. Persist the binding reason for every empty slot.

requests, breaker state, handoffs, and backlog as separate numbers.

Detail: references/execution-pattern.md §6.

Scheduler Tick

  1. Take the scheduler lease; validate the specification and transport.
  2. Harvest submissions; reconcile dead, finished, and mismatched claims.
  3. Validate the DAG; regenerate status and Gantt.
  4. Integrate a bounded, conflict-safe, dependency-ready batch.
  5. Reserve claims; release the lease and close lock descriptors before launch.
  6. Launch waves outside the lease; replace proved-dead persistent generations.
  7. Retake the lease briefly; merge outcomes; write status and Gantt atomically.

Model turns, builds, tests, and network calls never run under the lease.

Substrate

Decide one substrate per run: in-session (subagents or a workflow tool),

cron+tmux, or flow (an external agent-flow runner). Cron, tmux,

runner templates, and disk guards: references/substrate-cron.md.

Generated Validation

The controller ships tests showing that validate-only launches nothing; each

submission happens exactly once; claims stay isolated; caps stop lane N+1 and

request R+1; harvest precedes prune; workers inherit no lock; the checkbox and

oracle guards hold; persistent replacement restores exactly the target; the

Gantt covers every id and stays fresh; cleanup touches only its own runtime; and

two unlike fixture repositories share no constants. Full list:

references/gate-rules.md.

References

tick, integration, cleanup, observability

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.