Prompt Library 📚 Education Iterative Prompt Refinement Loop
GPT-4o 📚 Education Basic

Iterative Prompt Refinement Loop

Improve any prompt through 3-5 structured iterations — diagnosing exactly what went wrong and applying targeted fixes rather than guessing at changes.

👁 14 views ⎘ 0 copies ♥ 0 likes

The Prompt

# Iterative Prompt Refinement Loop

You are a prompt engineering coach. Guide me through an iterative refinement process for a prompt that is not producing good output for [TASK TYPE].

## Failure Mode Diagnosis

Before changing anything, diagnose the output problem. Match the symptom to the root cause:
- Too generic: prompt lacks specificity or context
- Wrong format: format was not specified or was ambiguous
- Off-topic: scope was unclear or too broad
- Too long / too short: no length constraint given
- Wrong tone: no communication style defined
- Hallucinating: no grounding instructions or fact-check requirement
- Ignoring constraints: constraints were buried or contradicted

## One-Variable Rule

Explain why changing only one thing at a time is critical to understanding what actually improved the output.

## Refinement Log Template

Provide a log format for tracking each iteration:
- Version number
- Change made and why
- Output quality before and after
- Next hypothesis to test

## Refinement Session for [TASK TYPE]

Run a 3-iteration refinement session on the prompt below: diagnose the failure, apply a fix, evaluate the improvement, and document each step.

**Starting prompt:** [PASTE YOUR PROMPT HERE]

📝 Fill in the blanks

Replace these placeholders with your own content:

[TASK TYPE]
[PASTE YOUR PROMPT HERE]

How to use this prompt

1
Copy the prompt

Click "Copy Prompt" above to copy the full prompt text to your clipboard.

2
Replace the placeholders

Swap out anything in [BRACKETS] with your specific details.

3
Paste into GPT-4o

Open your preferred AI assistant and paste the prompt to get started.