AI PROMPT LIBRARY

Bug Report Prompts.

Prompt templates for improving, structuring, and triaging bug reports — turning rough notes into developer-ready defect descriptions with clear reproduction steps, severity reasoning, and log summaries. Each prompt is a starting draft. Fill in the {{VARIABLES}}, review the output, and keep human ownership of the final result.

4
prompts

Review every output. AI-generated code, test cases, and bug reports require human verification before use. Never paste secrets, credentials, or personal data into any AI tool.

Improve a Bug Report for Developers

Transform raw bug notes, logs, and observations into a well-structured bug report with a precise title, clear reproduction steps, expected vs actual behaviour, severity/priority reasoning, and an evidence checklist.

beginner
Manual QA, Automation QA, SDET, DeveloperWorks with: Claude, ChatGPT, Gemini, Copilot, Cursor, Local LLMs
bug-reportdefect-managementdeveloper-communicationseverity
prompt template
You are a senior QA engineer who writes bug reports that developers can act on immediately. Improve the raw notes below into a professional bug report.

IMPORTANT: Do not invent any facts, error messages, step details, or behaviour descriptions not present in the notes below. If information is missing, mark that field as "[NEEDS CLARIFICATION]" rather than guessing.

Raw bug notes:
{{RAW_NOTES}}

Environment:
{{ENVIRONMENT}}

Logs or error messages (paste relevant excerpts only — no credentials, tokens, or PII):
{{LOGS}}

Output the improved bug report in this exact format:

**Title:** [One sentence: component + what went wrong + observable impact — max 100 characters]

**Environment:** [OS, browser/app version, relevant feature flags]

**Severity:** [Critical / High / Medium / Low] — [one sentence explaining why this severity is appropriate based on user impact and frequency]

**Priority:** [P1 / P2 / P3 / P4] — [one sentence explaining the business urgency]

**Steps to Reproduce:**
1. [Precise, numbered steps — each step is one action]

**Expected Result:**
[What should happen, based on stated requirements or product behaviour]

**Actual Result:**
[What actually happened — exact error message if available]

**Evidence Checklist:**
- [ ] Screenshot or screen recording attached
- [ ] Browser/device console log attached (sanitised — no credentials or PII)
- [ ] Network request/response captured (if relevant)
- [ ] Steps confirmed reproducible by a second person

**Additional Context:**
[Relevant logs, frequency of occurrence, regression notes — sanitised]

**[NEEDS CLARIFICATION] items:**
[List every field left blank or uncertain that a developer will ask about]

Clarify and Tighten Reproduction Steps

Take vague or incomplete reproduction steps and rewrite them as precise, ordered, environment-independent steps — and flag missing prerequisites or ambiguous instructions.

beginner
Manual QA, Automation QA, SDET, DeveloperWorks with: Claude, ChatGPT, Gemini, Copilot, Cursor, Local LLMs
bug-reportreproduction-stepsdefect-managementclarity
prompt template
You are a senior QA engineer. Your task is to rewrite the reproduction steps below so they are precise, ordered, and reproducible by a developer who has never seen the issue before.

IMPORTANT: Do not add steps, preconditions, or details not present in the original. If something is ambiguous or missing, flag it explicitly as "[NEEDS INFO]" rather than guessing.

Original reproduction steps:
{{ORIGINAL_STEPS}}

Environment context:
{{ENVIRONMENT}}

Known preconditions (if any):
{{PRECONDITIONS}}

Instructions:
- Rewrite as a numbered list. Each step is exactly one action: "Click [element name]", "Enter '[value]' in the [field name] field", "Navigate to [URL or screen name]".
- Add a Preconditions section before the steps for any required state that must be true before step 1 (logged-in user, specific data in the database, feature flag enabled, etc.).
- Identify and list all ambiguous steps with a "[NEEDS INFO]" label and a question explaining what information is missing.
- If the steps describe an intermittent issue, add a "Reproducibility" line: "Confirmed X% of attempts" or "Intermittent — not yet reliably reproducible".
- Do not simplify or combine steps — one action per step.

Output:
1. Rewritten Preconditions section.
2. Rewritten numbered Steps.
3. [NEEDS INFO] items — one per ambiguity.
4. Reproducibility note.

Summarize Logs for a Bug Report

Extract the most relevant signals from a wall of log output — error lines, stack traces, timing anomalies — and produce a concise summary for a bug report. Does not invent root causes.

intermediate
Manual QA, Automation QA, SDET, DeveloperWorks with: Claude, ChatGPT, Gemini
logserror-analysisbug-reportdebugging
prompt template
You are a senior QA engineer helping to analyse log output for a bug report. Your task is to summarise the most relevant parts of the log — not to diagnose the root cause.

IMPORTANT SAFETY RULES:
1. Do not include any values that look like passwords, API keys, tokens, email addresses, or personal names in your output.
2. Replace any sensitive-looking values with [REDACTED].
3. Do not invent a root cause — only describe what you observe in the log.
4. If you are uncertain whether a line is relevant, include it in a "Possibly relevant" section rather than discarding it.

Log output (paste here — ensure you have already removed secrets before submitting to any AI tool):
{{LOG_OUTPUT}}

Bug context (brief description of what went wrong):
{{BUG_CONTEXT}}

Instructions:
- Identify and extract: error lines, exception messages, stack traces (first 5–10 frames), timing anomalies (request took X ms), repeated retry patterns, and the last successful operation before the failure.
- Present as a structured summary with sections: "Key Errors", "Stack Trace (truncated)", "Timing / Performance signals", "Last successful operation before failure", "Possibly relevant".
- After the summary, add a "Questions for the developer" section: 2–4 questions a developer would need answered to diagnose the root cause, based only on what the log shows.
- Do not suggest a fix — that is the developer's job.

Output:
1. The structured log summary with [REDACTED] applied.
2. Questions for the developer.

Estimate Bug Severity and Priority

Given a bug description, affected users, and business context, produce a reasoned severity and priority estimate with explicit justification — for teams without a formal severity matrix.

beginner
Manual QA, Automation QA, QA Lead, QA ManagerWorks with: Claude, ChatGPT, Gemini, Copilot, Cursor, Local LLMs
severityprioritybug-triagedefect-management
prompt template
You are an experienced QA lead helping to triage a bug. Provide a reasoned severity and priority estimate based on the information below.

IMPORTANT: This is a starting-point estimate for team discussion — not a final decision. Clearly state what information is missing that would change the estimate.

Bug description:
{{BUG_DESCRIPTION}}

Affected functionality: {{AFFECTED_FUNCTIONALITY}}
Affected user segment (approximate percentage or description): {{AFFECTED_USERS}}
Frequency / reproducibility: {{FREQUENCY}}
Is there a workaround? {{WORKAROUND}}
Current environment (production / staging / dev): {{ENVIRONMENT}}
Business context (upcoming release, customer-facing feature, internal tool, etc.): {{BUSINESS_CONTEXT}}

Using this severity scale:
- Critical: System unusable, data loss, security breach, or no workaround for most users
- High: Major feature broken, workaround exists but is painful, significant % of users affected
- Medium: Feature partially degraded, workaround available, small % of users or edge case
- Low: Minor cosmetic/UX issue, no functional impact

Using this priority scale:
- P1: Fix immediately — blocks release or is actively impacting production users
- P2: Fix in current sprint — significant impact but does not block the release
- P3: Fix in next sprint — moderate impact, scheduled work
- P4: Fix when capacity allows — low impact, backlog

Output:
**Severity:** [Critical / High / Medium / Low]
**Reasoning:** [2–3 sentences explaining the severity based on user impact, data risk, and workaround status]

**Priority:** [P1 / P2 / P3 / P4]
**Reasoning:** [2–3 sentences explaining business urgency and timing]

**Key assumptions in this estimate:**
[List any assumptions you made because information was missing — these are the things that would change the estimate]

**What would escalate this to Critical/P1:**
[Specific conditions that would justify raising the estimate]