--- description: Reject a workflow gate and request changes allowed-tools: Read, Write, Bash --- # Reject Workflow Gate Reject gate with reason: "$ARGUMENTS" ## Usage ``` /workflow:reject design "Need more API endpoints for authentication" /workflow:reject implementation "Login form missing validation" ``` ## Steps ### 1. Parse Arguments Extract: - `gate`: First word (design | implementation) - `reason`: Remaining text in quotes If invalid format: ``` ❌ Usage: /workflow:reject "reason" Examples: /workflow:reject design "Need user profile page" /workflow:reject implementation "Missing error handling" ``` ### 2. Check Workflow State ```bash python3 skills/guardrail-orchestrator/scripts/workflow_manager.py exists ``` If no active workflow: ``` ❌ No active workflow found. ``` ### 3. Verify Current Phase **For design rejection**: - Current phase must be `AWAITING_DESIGN_APPROVAL` **For implementation rejection**: - Current phase must be `AWAITING_IMPL_APPROVAL` ### 4. Execute Rejection ```bash python3 skills/guardrail-orchestrator/scripts/workflow_manager.py reject "" ``` ### 5. Transition to Revision Phase **If design rejected**: ```bash python3 skills/guardrail-orchestrator/scripts/workflow_manager.py transition DESIGN_REJECTED python3 skills/guardrail-orchestrator/scripts/workflow_manager.py transition DESIGNING ``` **If implementation rejected**: ```bash python3 skills/guardrail-orchestrator/scripts/workflow_manager.py transition IMPL_REJECTED python3 skills/guardrail-orchestrator/scripts/workflow_manager.py transition IMPLEMENTING ``` ### 6. Report **Design Rejected**: ``` ╔══════════════════════════════════════════════════════════════╗ ║ ❌ DESIGN REJECTED ║ ╠══════════════════════════════════════════════════════════════╣ ║ Reason: ║ ║ ║ ║ The workflow has returned to the DESIGNING phase. ║ ║ Revision count: X ║ ║ ║ ║ Next steps: ║ ║ /workflow:design --revise Revise the design ║ ║ /workflow:resume Auto-revise and continue ║ ╚══════════════════════════════════════════════════════════════╝ ``` **Implementation Rejected**: ``` ╔══════════════════════════════════════════════════════════════╗ ║ ❌ IMPLEMENTATION REJECTED ║ ╠══════════════════════════════════════════════════════════════╣ ║ Reason: ║ ║ ║ ║ The workflow has returned to the IMPLEMENTING phase. ║ ║ Revision count: X ║ ║ ║ ║ Tasks requiring fixes will be marked as 'pending'. ║ ║ ║ ║ Next steps: ║ ║ /workflow:frontend --next Fix frontend tasks ║ ║ /workflow:backend --next Fix backend tasks ║ ║ /workflow:resume Auto-fix and continue ║ ╚══════════════════════════════════════════════════════════════╝ ``` ### 7. Update Related Tasks (Implementation Rejection) If implementation was rejected, identify tasks related to the rejection reason and mark them as pending: ```bash python3 skills/guardrail-orchestrator/scripts/workflow_manager.py task pending ```