Skip to content

feat: add QRSPI workflow for complex creative challenges#282

Merged
mrsimpson merged 6 commits into
mainfrom
feat/qrspi-infra-workflow
May 26, 2026
Merged

feat: add QRSPI workflow for complex creative challenges#282
mrsimpson merged 6 commits into
mainfrom
feat/qrspi-infra-workflow

Conversation

@mrsimpson
Copy link
Copy Markdown
Collaborator

Summary

This PR introduces the QRSPI workflow — a 7-state state machine designed for creative, complex challenges requiring deep alignment before execution. It also updates the JSON schema to include three missing fields used by existing workflows.

What's New

QRSPI Workflow (resources/workflows/qrspi.yaml)

QRSPI stands for Questions → Research → Design → Structure → Plan → Implement → Commit

Unlike EPCC (which targets medium-complexity features), QRSPI emphasizes:

  • Deep front-loaded alignment — 4 read-only phases before any code is written
  • Explicit user-approval gate at design → structure (no auto-transition; requires proceed_to_phase tool trigger design_approved)
  • Vertical slices — structure phase mandates breaking features into end-to-end testable slices (1–5 slices)
  • Review perspectives at key transitions:
    • design → structure: product owner review
    • plan → implement: architect + security expert review
    • implement → commit: senior developer + performance engineer review
  • Loop-back to designstructure, plan, and implement can all transition back to design via need_design_changes when the high-level approach proves unworkable
  • Abandon feature — supported from all states, resetting to questions

Schema Fix (resources/state-machine-schema.json)

Added three fields that were missing from the schema but widely used by existing workflows:

  • allowed_file_patterns at the state level
  • review_perspectives at the transition level
  • domain at the metadata level

Testing

  • Workflow YAML structure validated against updated schema
  • Pattern-matched against EPCC and TDD workflows for consistency
  • No runtime code changes — only declarative workflow + schema additions

Checklist

  • QRSPI workflow created with 7 states and 19 transitions
  • Schema updated with missing fields
  • No breaking changes to existing workflows

mrsimpson added 6 commits May 26, 2026 12:07
…in to schema

The state-machine-schema.json was missing three fields widely used by existing workflows:

- allowed_file_patterns (state level)

- review_perspectives (transition level)

- domain (metadata level)
QRSPI (Questions, Research, Design, Structure, Plan, Implement) is a 7-state workflow inspired by the QRSPI methodology.

Unlike EPCC (medium-complexity features), QRSPI targets creative, complex challenges requiring deep alignment before execution.

Key features:

- 4 read-only alignment phases (questions, research, design, structure)

- Explicit user-approval gate at design→structure transition

- Vertical slice requirement in structure phase

- Review perspectives: product owner (design), architect+security (plan), senior dev+performance (implement)

- Loop-back transitions from downstream phases to design when approach proves unworkable
…eparation

Rewrote all phase instructions from verbose STEP-by-STEP checklists to concise principle statements.

Each phase now has a single **Principle** line + goals + explicit 'Do not' constraints.

- questions: 'Clarify intent before exploring solutions' — do not research/design/plan/code

- research: 'Gather facts before forming opinions' — do not propose solutions/design/code

- design: 'Align on WHAT and WHY before detailed HOW' — do not plan implementation/code

- structure: 'Decompose into end-to-end testable units' — do not plan tasks/code

- plan: 'Define detailed HOW per slice' — do not change design/code

- implement: 'Execute plan one slice at a time' — adapt tactics, loop back only if fundamentally flawed

- commit: 'Leave codebase cleaner than found' — do not add features

File: 373 → 245 lines (-34%). All 7 states, 3 review gates, 19 transitions preserved.
…riven style

Commit phase now has Cleanup / Documentation / Validation sections

instead of being over-condensed to a single paragraph.

Other 6 phases remain concise principle-driven.
@mrsimpson mrsimpson merged commit 0a10229 into main May 26, 2026
3 checks passed
@mrsimpson mrsimpson deleted the feat/qrspi-infra-workflow branch May 26, 2026 18:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant