Skip to content

Mission 0A: SWE work factory V1 — resumable mission orchestration (repo-local) #62

Description

@Thunderkill016

Mission 0A — SWE work factory V1

Repository-local orchestration layer so long autonomous engineering missions don't lose state, drift scope, or falsely declare success. Deliberately boring: Markdown + JSON artifacts + one Node CLI. No DB, no dashboard, no framework, no multi-agent platform.

Lifecycle

QUEUED → RUNNING → VERIFYING → DONE / FAILED / BLOCKED

Commands (package.json scripts)

  • swe:status — list/detail missions
  • swe:start — QUEUED → RUNNING; refuses on dirty tree or a second non-terminal mission
  • swe:checkpoint — ingest compact checkpoint md, stamp SHA + git state
  • swe:verify — run mission-required project checks (allowlisted: npm run <script> / node tests/*.mjs / node scripts/*.mjs), never duplicated validation logic
  • swe:finish — DONE only with green verification on current HEAD; writes REPORT.md
  • swe:resume — reconstruct context packet for a fresh session (mission + latest checkpoint + git state); BLOCKED → RUNNING

Artifacts

  • missions/TEMPLATE.md
  • missions/<id>/mission.md — JSON frontmatter (id, verification[], …) + narrative sections
  • missions/<id>/state.json, checkpoints/NNN.md, logs/, REPORT.md

Safety

Fail closed: no force-push, no reset --hard, no discarding unrelated uncommitted changes, no production secrets/data. Verification command allowlist. ChatGPT-via-Playwright optional + advisory only, never secrets.

V1 boundary

One non-terminal mission at a time; the queue is pre-authored mission files — no autonomous generation of future work.

Dogfood

Run a harmless validation mission through start → checkpoint → verify → finish → report + resume simulation.

Activity

  1. Thunderkill016 commented on Sep 30, 2026

    @Thunderkill016
    OwnerAuthor

    Implemented on branch devin/swe-factory-001, PR #63. Dogfood: missions 001 (full lifecycle → DONE) + 002 (blocked → resume → DONE) committed. See PR for details.

  2. Thunderkill016 commented on Sep 30, 2026

    @Thunderkill016
    OwnerAuthor

    0A.1 integrity hardening — done in 75b8f04, CI green

    Finding 1 — DONE with uncommitted product changes: CONFIRMED.
    Reproduced live: dirty-tracked product file → verify PASS → finish accepted (SHA matched) → DONE; the change was invisible in the startSha..HEAD report.
    Fix: swe:finish DONE now requires a clean tree under the same policy as swe:start (no tracked modifications, no unsafe untracked outside missions//node_modules). --result failed stays unconditional. Verify may still run on a dirty tree — only DONE is gated.

    Finding 2 — mission definition mutability: CONFIRMED.
    Reproduced live: weakened objective + criteria after start, committed it, verify + finish still produced DONE.
    Fix: swe:start pins missionSha256 into state.json; verify/finish/resume re-hash and fail closed on any drift — committed or not. Restoring original bytes restores the hash → normal operation. No V1 amendment workflow by design.

    Docs: README now states the allowlist guards mission-specified verification commands only — reliability guard on the contract, not a sandbox on the agent.

    Tests: 10 new checks (31 total): dirty-tree refusal, commit+reverify+done, drift detection at all guarded ops, restore-recovers, hash persisted. npm run verify green; verify:full green in CI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions