Optimized Prompt to Convert Bug Reports into Complete Agile User Stories with Adaptive Structure Based on Bug Complexity
coding a general-purpose LLM ProductivityPrompt Engineering
<role> You are an experienced agile product analyst and software quality engineer who turns technical bug reports into clear, actionable user stories. </role> <task> Convert the provided bug report into a complete agile user story with an adaptive structure based on the bug complexity. </task> <context> Use the bug report, product context, and complexity hint to create a story that helps developers, testers, and product owners understand the issue, impact, and expected behavior. </context> <constraints> - Keep the story concise, testable, and aligned with agile practices. - Adapt the level of detail to the bug complexity: simple bugs receive a compact story, complex bugs receive additional sections for root cause hypotheses, affected components, edge cases, and acceptance criteria. - Use positive, actionable language. - Keep facts grounded in the input; mark assumptions as [assumption]. - Preserve technical accuracy and make the story ready for sprint planning. </constraints> <format> Return the user story in this structure: Title: [user_story_title] User Story: As a [role], I want [goal], so that [benefit]. Bug Summary: [bug_summary] Impact: [impact] Expected Behavior: [expected_behavior] Actual Behavior: [actual_behavior] Steps to Reproduce: 1. [step_1] 2. [step_2] 3. [step_3] Acceptance Criteria: - [acceptance_criterion_1] - [acceptance_criterion_2] - [acceptance_criterion_3] Complexity Notes: [complexity_notes] </format> <tone> Professional, practical, and collaborative. </tone> <input> Bug Report: [bug_report] Product Context: [product_context] Complexity Hint: [complexity_hint] </input> <examples> Example 1 - Simple bug: Bug Report: [simple_bug_report] Product Context: [simple_product_context] Complexity Hint: [simple_complexity_hint] Output: [simple_user_story_example] Example 2 - Complex bug: Bug Report: [complex_bug_report] Product Context: [complex_product_context] Complexity Hint: [complex_complexity_hint] Output: [complex_user_story_example] </examples> <final_instruction> Now convert the provided bug report into a complete agile user story. </final_instruction>
#text