Skip to content

[Story] Enforce spec-first with headless uf gate #514

Description

@beatrizmcouto

👤 User Story

As a
team practicing spec-driven development

I want to
a headless uf gate --phase <specify|plan|implement|review|pr> --format json that exits non-zero when constitution checks fail

So that
FullSend validation_loop.script and the local pre-commit/pre-PR hook enforce the same spec-first rules and a model cannot bypass them

🎯 Acceptance Criteria

  • uf gate exists and is non-interactive (--format json)
  • Enforces: spec + plan + tasks exist/approved before implement
  • Enforces: review PASS before PR
  • Enforces: coverage strategy present (Constitution IV)
  • Enforces: no direct commits to main
  • Wired as validation_loop.script on write-capable harnesses
  • Same command is runnable as a local pre-commit / pre-PR hook
  • Exit non-zero blocks the loop; output is machine-readable

🚫 Out of Scope

  • Implementing specify/code/forge agents
  • Replacing convention packs or the constitution text
  • Soft warnings that the model can ignore

Dependencies

  • Can start after Phase 0; must land before write-capable Increments 3–5

Cross-cutting; starts with Increment 3. Deterministic gate — not prompt-only. Comparable to ComplyTime policy/validation CLI work (M).

🏁 Definition of Done — 🛠️ Quality & Testing

  • Code has been peer-reviewed for bugs and vulnerabilities.
  • Proper testing has been completed and passes (Unit, Integration, E2E via GitHub Actions).
  • The feature has been demonstrated/validated successfully in the target environment.

🏁 Definition of Done — 📝 Architecture & Docs

  • Usage documentation or changelog updated (if user-facing changes introduced).
  • Local ADR written and verified by Tech Lead if technical architecture deviated.
  • Any newly introduced technical debt has been logged as a GitHub issue.

Context


Implementation Notes (added by @jflowers, Aug 2026)

CLI signature:

uf gate --phase <specify|plan|implement|review|pr> --format json

Behavior:

  • Exits non-zero on constitution-check failure (blocks the validation loop)
  • Machine-readable JSON output on stdout for programmatic consumption
  • Enforces:
    • Spec + plan + tasks exist and are approved before --phase implement
    • Review PASS before --phase pr
    • Coverage strategy present (Constitution Principle IV: Testability)
    • No direct commits to main (branch protection check)

Integration with FullSend:

  • Wired as validation_loop.script on write-capable harnesses (Inc3–5)
  • Non-zero exit blocks the validation loop, triggering retry or failure
  • Same command runnable as a local pre-commit / pre-PR hook (parity)

Implementation location: cmd/unbound-force/ — new subcommand (does not exist today). The CLI currently has: init, version, doctor, setup, sandbox, gateway, config. This adds gate.

Must land before: Inc3 (#516), Inc4 (#517), Inc5 (#518) — all write-capable agents require uf gate enforcement.

Activity

  1. added
    enhancement
    llm_assisted
    on Aug 17, 2026
  2. added this to the FullSend BYOA milestone on Aug 18, 2026
  3. jflowers commented on Aug 24, 2026

    @jflowers
    Contributor

    Confirmed: wiring point exists

    internal/harness ValidationLoop{Script, MaxIterations, FeedbackMode, Schema, PreflightCheck} is present on fullsend main — uf gate slots into validation_loop.script as planned. Add the newly required cross-runtime contract: the runtime must honor RunParams.Prompt on retry iterations (fall back to runtime.DefaultAgentPrompt when empty), or feedback_mode: append is a silent no-op (fullsend-ai/fullsend#1050).

  4. moved this from Ready 🚀 to In Progress 📋 in Unbound Force Planningon Sep 3, 2026
  5. moved this from In Progress 📋 to Ready for Review 👀 in Unbound Force Planningon Sep 8, 2026
  6. added 8 commits that reference this issue on Oct 29, 2026
    a46f052
    8e493f8
    bfce395
    f88ff71
    be501c8
    a1f6047
    d39ccf5
    683d53f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementllm_assisted

Projects

Relationships

None yet

Development

No branches or pull requests

Issue actions