Repository navigation
Closed
Labels
enhancementNew feature or requestplannedImplementation plan approvedready-for-reviewReady for code reviewrefactorCode refactoringstateState tracking and management
Milestone
Description
Summary
Each workflow skill needs to update .sequant/state.json when phases start, complete, or fail. This issue tracks adding state update calls to all skills.
Skills to Update
Core Workflow Skills
-
/spec- Update on start →in_progress, on complete →completed/failed -
/exec- Update on start →in_progress, on complete →completed/failed -
/test- Update on start →in_progress, on complete →completed/failed -
/qa- Update on start →in_progress, on complete →completed/failed -
/loop- Update iteration count, phase status
Conditional Skills
-
/security-review- Update when run -
/testgen- Update when run
Orchestrator
-
sequant run- Already manages phase flow, add state updates at transitions
Meta Skills
-
/solve- Initialize issue state when starting work -
/fullsolve- Initialize issue state, update through phases -
/merger- Update tomergedstatus on successful merge
Implementation Pattern
import { updatePhaseStatus, updateIssueStatus } from '../lib/state';
// At skill start
await updatePhaseStatus(issueNumber, 'exec', 'in_progress');
// At skill end (success)
await updatePhaseStatus(issueNumber, 'exec', 'completed');
// At skill end (failure)
await updatePhaseStatus(issueNumber, 'exec', 'failed');Considerations
- Skills can run standalone OR via orchestrator
- When orchestrated (
SEQUANT_ORCHESTRATORenv var set), orchestrator handles state - When standalone, skill handles its own state
- Avoid duplicate updates
Acceptance Criteria
- All listed skills update state appropriately
- No duplicate updates when run via orchestrator
- State reflects reality after any skill execution
- Failed skills set phase to
failed, not left asin_progress
Dependencies
- Add persistent state tracking for workflow phases #115 - State tracking utilities must exist first
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestplannedImplementation plan approvedready-for-reviewReady for code reviewrefactorCode refactoringstateState tracking and management
Activity
admarble commentedon Jan 19, 2026
Worktree Setup
Feature worktree already created from
feature/dashboardbranch:This is part of the dashboard feature integration - all dashboard work (#114, #116, #117, #118, #119, #120) branches from
feature/dashboardrather thanmain.Note:
sequant rundoesn't support custom base branches yet (see #122), so this worktree was created manually.admarble commentedon Jan 20, 2026
📋 Implementation Plan - State Integration for Workflow Skills
Acceptance Criteria Checklist
AC-1: All listed skills update state appropriately
.sequant/state.jsonAC-2: No duplicate updates when run via orchestrator
sequant run, verify no skill-side state writesSEQUANT_ORCHESTRATOR=sequant-run→ When skill runs → Then skill makes no state callsAC-3: State reflects reality after any skill execution
AC-4: Failed skills set phase to
failed, not left asin_progressfailedwith error messageVerification Methods Summary
npm run test:integrationAssumptions to Validate
gh issue viewSEQUANT_ORCHESTRATORenv varImplementation Plan
Phase 1: Create State Update CLI Helper
Create
scripts/state-update.tsto enable SKILL.md files to update state:Phase 2: Core Workflow Skills (Parallel)
Update skill documentation with state tracking instructions:
/spec- AddstartPhase('spec')/completePhase('spec', ...)/exec- AddstartPhase('exec')/completePhase('exec', ...)/test- AddstartPhase('test')/completePhase('test', ...)/qa- AddstartPhase('qa')/completePhase('qa', ...)Phase 3: Loop and Orchestrator Skills (Sequential)
/loop- Add iteration count updates/fullsolve- Ensure SEQUANT_ORCHESTRATOR is set, manages phase flow/solve- Add issue initializationPhase 4: Conditional Skills (Parallel)
/security-review- Add state hook for security phase/testgen- Add state hook (optional - generator skill)/verify- Add state hook for verification phasePhase 5: Merge Skill
/merger- Update tomergedstatus on successful mergePhase 6: Integration Testing
Skills NOT Requiring State Updates
/assess- Read-only diagnostic/clean- Maintenance, no workflow phase/docs- Post-merge documentation/reflect- Meta-analysis/improve- Discovery/issue creation/release- Post-merge automationConflict Risk Analysis
In-flight work: #117 (state bootstrapping)
Overlapping files:
src/lib/workflow/state-utils.tsAssessment: Low risk - complementary changes
Approach: Proceed, rebase if #117 merges first
Dependencies
✅ #115 - State tracking utilities (CLOSED/merged)
Recommended Workflow
Phases: exec → test → qa
Quality Loop: enabled
Generated by
/spec 119feat(#119): integrate state updates into all workflow skills
admarble commentedon Jan 20, 2026
Implementation Complete
AC Coverage
scripts/state/update.ts)Files Changed
New files:
scripts/state/update.ts- CLI helper for state updates (218 lines)Modified skills:
.claude/skills/spec/SKILL.md- Added State Tracking section.claude/skills/exec/SKILL.md- Added State Tracking section.claude/skills/test/SKILL.md- Added State Tracking section.claude/skills/qa/SKILL.md- Added State Tracking section with status update.claude/skills/loop/SKILL.md- Added State Tracking section with iteration tracking.claude/skills/fullsolve/SKILL.md- Added orchestrator state management instructions.claude/skills/solve/SKILL.md- Added issue initialization instructions.claude/skills/security-review/SKILL.md- Added State Tracking section.claude/skills/testgen/SKILL.md- Added State Tracking section.claude/skills/verify/SKILL.md- Added State Tracking section.claude/skills/merger/SKILL.md- Added State Tracking section with merged statusSchema/Dashboard updates:
src/lib/workflow/state-schema.ts- Addedverifyandmergerphasesdashboard/server.ts- Added labels for new phasesTest Results
PR
PR: #135
Generated with Claude Code
admarble commentedon Jan 20, 2026
QA Review for Issue #119
AC Coverage
scripts/state/update.ts), all 11 skills have State Tracking sectionsSEQUANT_ORCHESTRATORis set (line 34-37)Coverage: 4/4 AC items fully met
Quality Metrics
Code Review
Strengths:
ensureIssueExists()prevents errors on untracked issuesverifyandmergerIssues:
Suggestions:
scripts/state/update.tsCLI in future iterationjsdiffdependency vulnerability (npm audit fix --force)Self-Evaluation
Verdict: READY_FOR_MERGE
All acceptance criteria are met. The implementation is well-designed with proper orchestrator awareness, comprehensive state operations, and graceful error handling. The 2 test failures are pre-existing (doctor.test.ts version warning) and unrelated to this change.
Documentation
Next Steps
Documentation: Before merging, run
/docs 119to generate feature documentation if needed.QA completed by Claude Code
docs: add #119 to CHANGELOG unreleased section
feat(#119): integrate state updates into all workflow skills (#135)