Add spec-extraction-workflow: bootstrap repos with semantic baseline#119
Merged
Alan-Jowett merged 4 commits intomicrosoft:mainfrom Mar 30, 2026
Merged
Conversation
Add an interactive orchestration template that bootstraps any repository with structured requirements, design, and validation specifications. Workflow phases: 1. Repository scan (agent uses tools to read code, docs, tests) 2. Draft extraction (requirements + design + validation with confidence) 3. Human clarification loop (iterate until specs are crisp) 4. Consistency audit (adversarial, D1-D7 classification) 5. Human approval (loop back if needed) 6. Create deliverable (PR with spec files) Key design decisions: - Domain-agnostic: configurable persona for any engineering domain - Agent-driven scanning: uses tools to read the repo, not user-pasted - User-specified output paths: no opinionated filename defaults - Confidence marking: every extracted item tagged HIGH/MEDIUM/LOW - Reuses all existing protocols (requirements-from-implementation, requirements-elicitation, traceability-audit, etc.) - No new protocols, formats, or personas needed This is the bootstrap complement to engineering-workflow: spec-extraction (bootstrap) -> engineering-workflow (evolve) Closes microsoft#117 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new interactive PromptKit orchestration template to bootstrap an existing repository with an initial “semantic baseline” (requirements, design, validation) extracted from implementation and refined via human-in-the-loop review, then audited for consistency before producing PR-ready spec files.
Changes:
- Added
spec-extraction-workflowinteractive template with phased repo scanning, extraction, clarification, audit, and deliverable creation. - Registered the new template in
manifest.yaml(persona configurable, multi-artifact output, drift taxonomy).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| templates/spec-extraction-workflow.md | New interactive workflow template defining a 6-phase code-to-spec extraction + clarification + audit loop. |
| manifest.yaml | Adds the new template entry so bootstrap/assembly can discover and run it. |
… quality checklist - Standardize confidence labels to High/Medium/Low (matches investigation-report format convention) - Inline section skeletons for requirements-doc, design-doc, and validation-plan formats since only multi-artifact is assembled - Enumerate investigation-report's 9 required sections with mapping for Phase 4 audit output and verdict placement - Add output_audit param for persisting the audit report - Add Quality Checklist section (12 verification items) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Add output_audit to Inputs display section - Replace [UNCERTAIN]/[AMBIGUOUS] with [UNKNOWN: ...]/[ASSUMPTION] to match anti-hallucination protocol conventions - Align requirements-doc skeleton to 8-section structure with separate Constraints, Dependencies, Assumptions, Risks sections - Align design-doc skeleton to 9-section structure (Context & Goals, Non-Goals, Requirements Summary, Architecture, Detailed Design, Security/Ops, Tradeoffs, Open Questions, Revision History) - Align validation-plan skeleton to 10-section structure (Overview, Scope, Test Strategy, Risk Prioritization, Test Cases, Traceability, Pass/Fail Criteria, Coverage, Environment, Revision History) - Add 'None identified' rule for empty sections Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ctures - requirements-doc: match 8-section structure (Overview, Scope, Definitions and Glossary, Requirements, Dependencies, Assumptions, Risks, Revision History) - design-doc: match 9-section structure (Overview, Requirements Summary, Architecture, Detailed Design, Tradeoff Analysis, Security Considerations, Operational Considerations, Open Questions, Revision History) - validation-plan: match 8-section structure with correct ordering (Overview, Scope of Validation, Test Strategy, Requirements Traceability Matrix, Test Cases, Risk-Based Test Prioritization, Pass/Fail Criteria, Revision History) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a spec-extraction-workflow -- an interactive orchestration template that bootstraps any repository with structured requirements, design, and validation specifications.
Closes #117
The Bootstrap Complement
This is the first half of a two-workflow model:
Together they form a complete lifecycle for any engineering domain.
Workflow Phases
Phase 1: Repository Scan (agent reads code, docs, tests with tools) Phase 2: Draft Extraction (requirements + design + validation, confidence-tagged) Phase 3: Human Clarification Loop (iterate until specs are crisp) Phase 4: Consistency Audit (adversarial, D1-D7) Phase 5: Human Approval (loop back if needed) Phase 6: Create Deliverable (PR with spec files)Entry point:
read and execute templates/spec-extraction-workflow.mdNew Components
Just 1 template -- everything else is reused:
requirements-from-implementationprotocolrequirements-elicitationprotocoltraceability-auditprotocoladversarial-falsificationprotocolrequirements-docformatdesign-docformatvalidation-planformatspecification-drifttaxonomyKey Design Decisions
Validation
Both validators pass cleanly.