Track the delegated agent task prompts under docs/jobs/ so the slice decomposition of the gigafactory roadmap is reproducible and reviewable.
5.2 KiB
| engine | cwd | yolo | lock | timeout |
|---|---|---|---|---|
| devin | /Users/sd9235/code/mygh/learning_ai_devops_tools | true | devops-tools | 3h |
ROLE: Senior engineer. Implement Phase 1 — Slice 2 (Profiles + deps/DAG, single host).
SOURCE OF TRUTH: agent-queue/docs/GIGAFACTORY_ROADMAP.md (read §5 deps, §6 profiles, §14 Phase 1). This slice implements ONLY the items below.
PREREQUISITE / BRANCHING:
- This builds on Slice 1 (PR #1, branch feat/gigafactory-p1-slice1).
- Base your work on
mainIF PR #1 has been merged; otherwise branch off feat/gigafactory-p1-slice1. Do NOT duplicate or revert Slice 1 code. - New branch: feat/gigafactory-p1-slice2. Push + open a PR. DO NOT merge.
STRICT SCOPE:
- Edit ONLY under agent-queue/ (agent-queue.sh, selftest.sh, README.md, new profiles/ dir, docs/GIGAFACTORY_ROADMAP.md). No other repo.
- DO NOT modify/delete anything under agent-queue/queue/ (live jobs). DO NOT run
agent-queue.sh run. selftest.sh uses its own temp AGENT_QUEUE_ROOT only. - bash, single host. No service/Cosmos work (that is Phase 2).
A. PROFILES (§6)
- Create agent-queue/profiles/ with a starter catalog as profiles/.md:
developer, backend-engineer, frontend-engineer, ux-designer, ui-designer, qa,
reviewer, docs-writer (and a reserved
planner). Each has frontmatter: name, persona (multi-line block), capabilities, default-verify, engine-class, prefers-engine, allowed-scope, review-policy. - Profile resolution: when a job sets
profile: X, inherit any of {verify, capabilities, engine-class, prefers-engine, allowed-scope, review-policy} that the job OMITS. Job-level fields ALWAYS override the profile. Resolution runs BEFORE the capability gate + engine resolution so inherited caps/engine-class take effect. - Persona injection: prepend the profile's persona to the job body in the stripped body file fed to the engine. Never write secrets to logs.
- allowed-scope guardrail — WARN-ONLY this phase: after the run, if cwd is a git repo, compute changed paths and log a WARNING for any path outside the allowed-scope globs. Non-blocking (do NOT fail the job). Expose the scope-check as a unit-testable function.
- Document the resolution precedence (job > profile > built-in default).
B. DEPS / DAG — single host (§5)
6. deps reference other jobs by idempotency-key (stable, author-controlled). A
dep is satisfied when a job with that key is in shipped/ (default), or in
shipped/ OR testing/ when the dependent job sets deps-mode: soft.
7. A job with unmet deps is BLOCKED: not selected to run, surfaced in status as
"blocked (waiting on )". Implement as a skip-with-reason in inbox
selection (like the busy-lock skip) — do NOT launch, do NOT move to failed.
Re-evaluated every run loop; becomes runnable once deps are satisfied.
8. Submit-time cycle detection on add: build the dep graph from idempotency-keys
across inbox + active stages; reject (die, nonzero) if the new job would create
a cycle.
9. No cross-machine deps (that is P2).
TESTS (selftest.sh — tests are sacred; only ADD):
- profile inherit verify: a profile whose default-verify is
false→ a job using it (no own verify) routes to failed/; a profile with default-verifytrue→ testing/. - persona injection (golden): the body fed to the engine begins with the profile persona (capture via a stub that copies its --prompt-file to a sentinel).
- profile caps inheritance: job omitting capabilities inherits the profile's → unmet → failed/ result=capability_mismatch.
- allowed-scope warn: an out-of-scope change logs a WARNING and the job still succeeds (or assert the scope-check function directly).
- deps block→run: job B deps:[keyA] stays blocked while A is unshipped; once A is in shipped/, B becomes runnable and completes.
- deps-mode soft: dep satisfied when the dependency is in testing/.
- cycle detection: adding A deps:[keyB] while B deps:[keyA] is rejected.
DOCS:
- README: profiles section (catalog + resolution precedence) + deps/blocked semantics.
- docs/GIGAFACTORY_ROADMAP.md: tick the §6 boxes you fully completed and the §5
depsbox; bump §0 Phase 1 %.
CONSTRAINTS: bash style consistent with the existing script; no new runtime deps; macOS + Linux safe; no emojis in code; no leftover debug noise; conventional commits.
VERIFY GATE (must pass):
- bash agent-queue/selftest.sh → fully green (existing + new).
- bash -n agent-queue/agent-queue.sh ; node --check agent-queue/dashboard.mjs.
FINAL OUTPUT — print the implementation report in EXACTLY this format:
Implementation Report — Phase 1 Slice 2
Branch & commits
- branch / based-on: (based on main | feat/gigafactory-p1-slice1)
- commits: (one per line)
- PR: <url or "opened, not merged">
Files changed
- :
What was implemented (A1-5, B6-9)
- : <how, key functions added/changed>
Tests added
- : (plus selftest.sh PASS/FAIL summary)
Verify gate results
- selftest.sh: <PASS/FAIL + counts>
- bash -n / node --check:
Deviations / assumptions
Suggested next slice
- <what should come next (likely: tracker adapter aq from-tracker/to-tracker)>