spec-kit icon indicating copy to clipboard operation
spec-kit copied to clipboard

[Feature]: Declare verdict inputs on the gates of the bundled speckit and catalog bugfix workflows

Open mcowdell-westmar opened this issue 2 weeks ago • 6 comments

Problem Statement

The bundled speckit workflow (1.0.1) and the catalog bugfix workflow (1.0.0) declare no verdict_input on any gate. docs/workflow-steps/types.md, "Gate Verdict Inputs", says that with no verdict input a gate "prompts on a TTY; pauses otherwise". A run started where there is no terminal can therefore pause at a gate but can never get past it. Examples are a GitHub Actions job, or an agent session that drives specify workflow run and specify workflow resume. Each resume pauses again at the same gate.

An overlay cannot add the input: docs/workflows/overlays.md, Limitations: "Overlays cannot add new inputs or change the input schema of the base workflow." Workflow composition does not help either. "Calling a Child Gate" maps a root input only to a child gate that already declares verdict_input. So the only way to answer these gates without a terminal is to copy the bundled workflow and add the inputs.

Two smaller observations from the same setup (Specify CLI 1.3.0 on Windows):

  • When stdin is redirected from /dev/null (Windows NUL), sys.stdin.isatty() returns True. The gate then prompts, reads end of input, and falls back to a rejection, so the run aborts instead of pausing. An empty pipe (: | specify workflow run ...) pauses as documented.
  • docs/workflow-steps/types.md does not say whether a gate may have options other than approve, edit and reject, or which option names on_reject applies to.

Proposed Solution

Declare an optional verdict input for each gate in the bundled and catalog workflows, with a default of "", so the current behaviour (prompt on a TTY, pause otherwise) is unchanged. For example, for speckit:

inputs:
  spec_verdict: {type: string, enum: ["", approve, reject], default: ""}
  plan_verdict: {type: string, enum: ["", approve, reject], default: ""}
steps:
  - id: review-spec
    type: gate
    # ...unchanged...
    verdict_input: spec_verdict

Then specify workflow resume <run_id> --input spec_verdict=approve works with no terminal. The same applies to review-assessment in bugfix.

Alternatives Considered

  • An overlay: not possible, because overlays cannot add inputs.
  • A project-authored copy of the workflow with the inputs added. This works, and it is what we do now, but the copy has to be compared against every release.
  • Answering gates only at a terminal. This rules out unattended runs.

Component

Agent integrations (command files, workflows)

Use Cases

  • A CI job that starts a workflow run and resumes it when a reviewer gives an answer, for example with a label on an issue.
  • An agent session that orchestrates runs and passes a reviewer's verdict on resume.

Acceptance Criteria

  • specify workflow resume <run_id> --input <gate>_verdict=approve passes each gate of the bundled speckit and catalog bugfix with no TTY.
  • With the input empty or absent, behaviour is unchanged.

Additional Context

Specify CLI 1.3.0; docs read at f29319d.

AI Disclosure

Drafted by Claude Code (model Claude Opus 5.5, auto permission mode) for the repository owner, who directed that this request be filed. The facts were checked by running the CLI: gate pause and resume with and without a verdict input, and the NUL versus empty-pipe stdin behaviour.

mcowdell-westmar avatar Nov 11 '26 16:11 mcowdell-westmar

Feature assessment — gate-verdict-inputs · Stage 1/5: Intake

Idea Intake: Gate verdict inputs for bundled workflows

  • Slug: gate-verdict-inputs
  • Created: 2026-11-11T19:36:10Z
  • Source: https://github.com/github/spec-kit/issues/5389
  • Type: improvement

Idea (as captured)

“The bundled speckit workflow (1.0.1) and the catalog bugfix workflow (1.0.0) declare no verdict_input on any gate ... with no verdict input a gate prompts on a TTY; pauses otherwise ... a run started where there is no terminal can pause at a gate but can never get past it ... specify workflow resume --input <...>=approve should pass gates with no terminal ... overlays cannot add workflow inputs, so users must copy workflows to make this work today.”
Source: issue #5389 by @mcowdell-westmar (2026-11-11).

Restated

The request is to make the bundled speckit and catalog bugfix workflows externally resumable in non-interactive environments by declaring optional gate verdict inputs. The ask preserves existing interactive behavior when verdict inputs are empty or omitted.

Origin & Context

  • Raised by: @mcowdell-westmar
  • Trigger: Real-world non-TTY workflow execution and resume loops where gates pause repeatedly without a way to pass verdicts via input.

First-Glance Unknowns

  • [NEEDS CLARIFICATION: Should verdict-input naming be standardized across bundled workflows for automation consistency?]
  • [NEEDS CLARIFICATION: Should docs explicitly cover non-approve options beyond reject when workflows define additional gate options?]
  • [NEEDS CLARIFICATION: Is the observed Windows NUL stdin behavior tracked as a separate bug from this feature request?]

Generated by 💡 Assess a Feature Request by Installing and Running Spec Kit for #5389 · copilot · gpt53codex · 52.5 AIC · ⌖ 0.752 AIC · ⊞ 26.7K · ◷

github-actions[bot] avatar Nov 11 '26 19:11 github-actions[bot]

Feature assessment — gate-verdict-inputs · Stage 2/5: Research

Idea Research: Gate verdict inputs for bundled workflows

  • Slug: gate-verdict-inputs
  • Created: 2026-11-11T19:36:10Z
  • Evidence confidence (overall): medium

Users & Demand

  • Non-interactive runners (CI jobs and agent-driven orchestrations) can pause at gate steps and need resumable, scriptable verdict injection to proceed — [source: https://github.com/github/spec-kit/issues/5389] (confidence: high)
  • Workflow operators currently maintain local copies of bundled workflows to add inputs, creating maintenance churn per upstream release — [source: https://github.com/github/spec-kit/issues/5389] (confidence: medium)
  • Broad prevalence and frequency of this pain across the install base are not quantified in repository telemetry in scope here — [source: ASSUMPTION] (confidence: low)

Prior Art

  • Gate docs already support verdict_input, including empty-string defaults and resume examples, indicating the engine capability exists and is documented — [source: repo:docs/workflow-steps/types.md (Gate Verdict Inputs)] (confidence: high)
  • Bundled speckit workflow gates (review-spec, review-plan) currently have no verdict_input declarations — [source: repo:workflows/speckit/workflow.yml] (confidence: high)
  • Catalog bugfix workflow gate (review-assessment) currently has no verdict_input declaration — [source: repo:workflows/bugfix/workflow.yml] (confidence: high)
  • Overlay limitations explicitly prevent adding new inputs to a base workflow, so users cannot solve this with overlays alone — [source: repo:docs/workflows/overlays.md (Limitations)] (confidence: high)

Market & Context

  • CI-first automation is a core use case for modern workflow systems; inability to pass gate verdicts non-interactively creates friction against unattended orchestration patterns — [source: https://github.com/github/spec-kit/issues/5389] (confidence: medium)
  • Current workaround is workflow forking/copying, which increases drift risk versus upstream defaults — [source: https://github.com/github/spec-kit/issues/5389] (confidence: medium)

Data & Constraints

  • Gate behavior is explicit: missing/empty verdict prompts on TTY and pauses otherwise; non-empty matching option auto-decides — [source: repo:docs/workflow-steps/types.md] (confidence: high)
  • For on_reject: retry, verdict inputs must accept "" in enum to remain resumable after reset — [source: repo:docs/workflow-steps/types.md] (confidence: high)
  • Constraint on implementation path: overlays cannot add inputs, so bundled/catalog workflow definitions are the practical place to expose verdict inputs — [source: repo:docs/workflows/overlays.md] (confidence: high)

Evidence Against the Idea

  • Evidence volume is mostly one issue report; there is limited quantitative signal on how often users hit this blocker — [source: https://github.com/github/spec-kit/issues/5389] (confidence: medium)
  • Additional workflow inputs can increase surface complexity for documentation and user understanding if naming is inconsistent — [source: ASSUMPTION] (confidence: low)
  • The Windows NUL behavior described may be a separate runtime bug and could blur acceptance boundaries if mixed into this feature’s scope — [source: https://github.com/github/spec-kit/issues/5389] (confidence: medium)

Gaps & Open Questions

  • [NEEDS CLARIFICATION: Desired naming convention for verdict inputs across bundled workflows (spec_verdict, plan_verdict, assessment_verdict, etc.).]
  • [NEEDS CLARIFICATION: Whether this feature should include explicit docs updates on gate option constraints and on_reject semantics.]
  • [NEEDS CLARIFICATION: Whether the Windows NUL stdin behavior is intentionally out of scope and should be tracked separately.]

Sources

  • https://github.com/github/spec-kit/issues/5389 (host: github.com, policy: allowlisted)
  • repo:docs/workflow-steps/types.md (host: local-repository, policy: allowlisted)
  • repo:docs/workflows/overlays.md (host: local-repository, policy: allowlisted)
  • repo:workflows/speckit/workflow.yml (host: local-repository, policy: allowlisted)
  • repo:workflows/bugfix/workflow.yml (host: local-repository, policy: allowlisted)

Generated by 💡 Assess a Feature Request by Installing and Running Spec Kit for #5389 · copilot · gpt53codex · 52.5 AIC · ⌖ 0.752 AIC · ⊞ 26.7K · ◷

github-actions[bot] avatar Nov 11 '26 19:11 github-actions[bot]

Feature assessment — gate-verdict-inputs · Stage 3/5: Problem

Problem Definition: Non-interactive gate progression in bundled workflows

  • Slug: gate-verdict-inputs
  • Created: 2026-11-11T19:36:10Z
  • Inputs used: intake.md + research.md

Problem Statement

Teams running bundled Spec Kit workflows in non-interactive environments can reach gate steps that pause but cannot be programmatically resolved because those workflows do not expose verdict inputs. This blocks unattended execution paths and forces users to maintain divergent workflow copies just to pass gate verdicts.

Affected Users & Stakeholders

  • Users: CI operators and agent/session orchestrators — cannot advance paused gates through workflow resume --input on bundled workflows without local forks.
  • Stakeholders: Spec Kit maintainers — own workflow UX consistency, bundled workflow maintainability, and documentation clarity for automation paths.

Goals

  • Enable non-interactive resume of bundled workflow gates using declared verdict inputs.
  • Preserve existing behavior when verdict input is absent/empty (TTY prompt or pause).
  • Reduce need for downstream workflow forks made only to add gate inputs.

Non-Goals

  • Redesigning gate semantics or changing interactive gate behavior.
  • Solving unrelated stdin-runtime edge cases (for example, Windows NUL) in this request.
  • Producing workflow architecture/spec changes beyond exposing gate verdict inputs.

Success Metrics

  • Bundled speckit and catalog bugfix gates can be passed in non-TTY runs with specify workflow resume <run_id> --input <verdict_input>=approve (baseline: not consistently possible without workflow copies).
  • With verdict inputs omitted/empty, gate behavior remains unchanged from documented behavior (baseline: documented prompt/pause behavior).
  • Reduced need for user-maintained copies of bundled workflows for this specific capability (baseline: reported workaround exists; exact incidence unknown).

Cost of Inaction

Non-interactive users continue hitting pause loops at gates, and teams keep carrying workflow forks that drift from upstream releases. This increases operational friction and maintenance overhead for both users and maintainers.

Open Questions

  • [NEEDS CLARIFICATION: Exact verdict input names to standardize across bundled workflows.]
  • [NEEDS CLARIFICATION: Whether docs updates on gate option scope and on_reject semantics should ship in the same change.]
  • [NEEDS CLARIFICATION: Should Windows NUL behavior be opened/tracked as a separate bug immediately.]

Generated by 💡 Assess a Feature Request by Installing and Running Spec Kit for #5389 · copilot · gpt53codex · 52.5 AIC · ⌖ 0.752 AIC · ⊞ 26.7K · ◷

github-actions[bot] avatar Nov 11 '26 19:11 github-actions[bot]

Feature assessment — gate-verdict-inputs · Stage 4/5: Concept

Concept: Expose gate verdict inputs in bundled workflows

  • Slug: gate-verdict-inputs
  • Created: 2026-11-11T19:36:10Z
  • Recommended option: Option A — Add optional verdict inputs to existing bundled/catalog gates

Options

Option A — Add optional verdict inputs to existing bundled/catalog gates

  • Sketch: Keep current workflow flow and gate locations, but expose optional verdict inputs on bundled speckit and catalog bugfix gates so non-interactive operators can resume with explicit verdict values while interactive use remains unchanged when inputs are empty.
  • Appetite: small
  • Trade-offs: Wins immediate unblock for CI/automation and keeps defaults familiar; sacrifices some simplicity by adding more visible workflow inputs and naming decisions.
  • Rabbit holes: Input naming inconsistency across workflows; forgetting empty-string compatibility for any retry semantics.

Option B — Add a new automation-focused workflow variant

  • Sketch: Keep existing bundled workflows unchanged and publish separate automation-oriented variants that expose verdict inputs for script-driven runs.
  • Appetite: medium
  • Trade-offs: Wins cleaner separation between interactive and automated UX; sacrifices discoverability and maintenance by duplicating/parallel-tracking workflows.
  • Rabbit holes: Variant drift, user confusion about which workflow to choose, duplicated docs.

Option C — Do nothing (status quo)

  • Sketch: Keep current bundled/catalog workflows as-is and continue relying on local workflow copies where automation needs gate verdict injection.
  • Appetite: small
  • Trade-offs: Wins zero short-term change risk; sacrifices operator productivity and increases downstream maintenance/drift.
  • Rabbit holes: Ongoing repeated support burden and continued custom-fork churn.

Recommendation

Recommend Option A because it directly addresses the documented blocker with the smallest change while preserving current default gate behavior. It best matches the goals of unblocking non-interactive workflows and reducing avoidable user forking.

Out of Scope (for the recommended option)

  • Any redesign of gate step behavior beyond exposing optional verdict inputs.
  • Broad workflow architecture refactors.
  • Runtime stdin edge-case fixes (including the reported Windows NUL behavior) unless tracked separately.

Assumptions to Validate

  • Existing users will not be disrupted when verdict inputs remain unset.
  • A consistent, low-friction input naming pattern can be adopted across bundled workflows.
  • Documentation updates can clearly explain non-interactive verdict passing without increasing ambiguity around gate options.

Generated by 💡 Assess a Feature Request by Installing and Running Spec Kit for #5389 · copilot · gpt53codex · 52.5 AIC · ⌖ 0.752 AIC · ⊞ 26.7K · ◷

github-actions[bot] avatar Nov 11 '26 19:11 github-actions[bot]

Feature assessment — gate-verdict-inputs · Stage 5/5: Decision — verdict go

Decision: Gate verdict inputs for bundled workflows

  • Slug: gate-verdict-inputs
  • Decided: 2026-11-11T19:36:10Z
  • Verdict: go
  • Artifacts reviewed: intake.md | research.md | problem.md | concept.md

Scorecard

Criterion Rating Justification
Problem validity strong The blocker is concrete: bundled workflows pause at gates in non-TTY runs without externally passable verdict inputs.
Evidence strength adequate Repository docs and workflow files corroborate behavior and current configuration; quantitative prevalence data is limited.
Value vs. inaction strong Unblocking resume automation and reducing workflow-fork drift has clear operational value over status quo.
Feasibility / appetite strong A small-scope option exists that preserves default behavior while enabling scripted verdict injection.
Strategic fit strong Aligns with Spec Kit’s workflow automation and reusable bundled workflow goals.
Risk posture adequate Main risks (input naming consistency, docs clarity, scope boundary with separate stdin bug) are known and manageable.

Verdict & Rationale

Verdict: go. The scorecard shows a valid, high-impact workflow usability gap with adequate evidence and a small, credible concept that keeps current behavior intact when inputs are empty. Known risks are bounded and do not outweigh the value of enabling non-interactive gate progression in bundled workflows.

If needs-clarification

  • Not applicable for this verdict.

If go — Handoff to /speckit-specify

  • Problem: Bundled speckit and bugfix workflows cannot always progress gates in non-interactive runs because gate verdict inputs are not declared.
  • Chosen approach: Add optional verdict inputs to relevant existing gates with behavior-preserving empty defaults.
  • In scope / out of scope: In scope is exposing verdict-input wiring for bundled/catalog gates and any directly coupled docs updates; out of scope is gate-semantic redesign and unrelated stdin runtime bugs.
  • Success metrics: Non-TTY workflow resume --input <verdict_input>=approve passes targeted gates; omitted/empty inputs keep current prompt/pause behavior.
  • Carried-forward open questions: Final naming convention for verdict inputs; whether gate option/on_reject documentation clarifications ship in the same change.

Generated by 💡 Assess a Feature Request by Installing and Running Spec Kit for #5389 · copilot · gpt53codex · 52.5 AIC · ⌖ 0.752 AIC · ⊞ 26.7K · ◷

github-actions[bot] avatar Nov 11 '26 19:11 github-actions[bot]

Implemented in https://github.com/github/spec-kit/pull/5392, now merged into main. The speckit specification and plan review gates and the bugfix assessment review gate expose optional verdict inputs for non-interactive resume; empty or omitted values preserve existing behavior. The PR description now links this issue. This is merged but not yet included in a published release. The separately noted Windows NUL stdin behavior was not changed.

AI disclosure: Posted on behalf of @mnriem by GitHub Copilot using GPT-6.1 Sol (gpt-6.1-sol), autonomous execution of the authorized cleanup; AI-generated completion explanation. Reasoning-effort settings were not exposed.

mnriem avatar Nov 12 '26 13:11 mnriem