Repository navigation
v0.0.11 — trust → isolation: worktree-sandbox + trust-layer calibration
[0.0.11] — 2026-05-04
Theme: trust → isolation — runs sandboxed in their own git worktree, plus calibration of the v0.0.10 trust-contract layer. v0.0.11 closes the long-deferred worktree-sandbox candidate (BACKLOG since the original ROADMAP's v0.1.0 list) and ships five sibling polish specs that pay down friction surfaced by the v0.0.10 BASELINE: holdout-aware convergence, DoD-precision calibration, dynamic DAG walk for run-sequence, charged-token budget surfacing, and CI publish hygiene.
Added
factory-runtime run --worktree(factory-runtime). Each run materializes an isolatedgit worktreeat<projectRoot>/.factory/worktrees/<runId>/on a throwaway branchfactory-run/<runId>; the implement / validate / DoD phases all execute against that checkout, so the maintainer's main tree is never touched by the agent. Strong undo by construction (git worktree remove); enables parallel runs against distinct worktree paths. New CLI subcommandfactory-runtime worktree { list | clean [--all] [--keep-failed] }for forensic inspection + maintenance. New context record typefactory-worktree(parents=[runId]) carryingrunId / worktreePath / branch / baseSha / baseRef / createdAt / status. Public surface:+3exports (23 → 26:createWorktree,WorktreeOptions,CreatedWorktree). NewRuntimeErrorCode:runtime/worktree-failed(14 → 15).- Holdout-aware convergence (factory-runtime).
validatePhase({ checkHoldouts: true })runs## Holdout Scenarioseach iteration alongside the visible scenarios; convergence requires both to pass. New CLI flag--check-holdoutsandfactory.config.jsonkeyruntime.checkHoldouts. The persistedfactory-validate-reportpayload gains aholdouts: []array (legacy records without it still parse). - DoD-precision calibration (factory-spec-review). The
dod-precisionjudge is recalibrated against v0.0.10 BASELINE evidence; threshold + prompt updated to reduce false-positive flags on prose DoD bullets. - Charged-token budget surfacing (factory-runtime).
RunReport.chargedTokensnow exposes the budget-relevant total (input + output) — cache reads/creates are excluded per Anthropic's pricing. CLI converged/no-converge stdout printscharged=<n>/<budget>. The existingRunReport.totalTokensis preserved as a deprecated alias for back-compat. - Dynamic DAG walk for run-sequence (factory-runtime).
factory-runtime run-sequencenow promotes drafting specs dynamically as their deps converge during the same invocation (auto-promotion log line:<dep> converged → promoting <dependent>). Single-invocation cluster shipping for ready→drafting chains;--include-drafting(andruntime.includeDrafting) preserve the legacy walk-everything-from-start semantic. factory ci publishhardening (factory-core). CI publish workflow + scripted manual-fallback path normalize tarball checks across all six packages.
Changed
- All six
@wifo/factory-*packages bumped to0.0.11in lockstep.init-templates.tsPACKAGE_JSON_TEMPLATE.dependenciesbumped from^0.0.10to^0.0.11for every@wifo/factory-*dep.
Public API surface
| Package | v0.0.10 | v0.0.11 |
|---|---|---|
@wifo/factory-core |
33 | 33 |
@wifo/factory-context |
18 | 18 |
@wifo/factory-harness |
~16 | ~16 |
@wifo/factory-runtime |
23 | 26 (+createWorktree, +WorktreeOptions, +CreatedWorktree) |
@wifo/factory-spec-review |
10 | 10 |
@wifo/factory-twin |
~7 | ~7 |
Reconciliations worth knowing
--worktreeis opt-in for v0.0.11. Defaultfalse. Becomes opt-out post-v0.1.0 once soaked.- One worktree per
run()invocation. All phases share the worktree for that run. Cleanup is opt-in viafactory-runtime worktree clean(default removes only converged worktrees;--allalso removes failed ones, preserving forensic value of failed runs). - Worktree creation is atomic — a partial failure (disk full, permission denied) leaves no orphan record/branch. NO
factory-runrecord persists whencreateWorktreefails (the run never started). - v0.0.11 explicitly does NOT ship: parallel agent execution within a single sequence; auto-cleanup of converged worktrees on run end; worktree GC after N days; auto-merge of converged worktrees back into the main branch (the maintainer reviews + merges manually); per-spec worktree options in spec frontmatter (only
RunOptions.worktreefor now); cross-platform Windows worktree handling (best-effort; tested on macOS/Linux).