Skip to content

[Phase 5.4] PRD stress-test web UI: trigger and streaming progress #561

@frankbria

Description

@frankbria

Goal

Add a [Stress Test] button to the PRD page that triggers the stress-test pipeline and streams progress back to the browser.

Background

The CLI has cf prd stress-test for recursive decomposition — it surfaces ambiguities the agent cannot resolve without human input. Web-only users never see this step, skipping the most valuable part of the THINK phase.

Scope

  • [Stress Test] button on the PRD page, enabled only when a PRD exists
  • Clicking opens a modal or side panel with a streaming progress view (SSE or WebSocket)
  • Backend: expose POST /api/v2/prd/stress-test that runs the existing cf prd stress-test core logic and streams intermediate results (decomposition steps)
  • Loading/streaming state: show "Analyzing PRD..." with a spinner and incremental output lines as they arrive
  • On completion: transition to results view (separate issue [Phase 5.4] PRD stress-test web UI: results view and PRD refinement #562)
  • Error state: show error message with retry button

Out of scope

Acceptance criteria

  • [Stress Test] button is visible on the PRD page
  • Clicking the button starts the stress-test and shows streaming output
  • Backend endpoint calls core stress-test logic
  • Error state handled gracefully
  • npm test and uv run pytest pass

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestphase-5Phase 5: Advanced Features & Polish

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions