Chain a performance problem into a measured fix
Measure, diagnose, then optimise, rather than optimising what seems slow.
What this prompt helps you do
Measurements, then the diagnosed bottleneck, then an optimisation with before-and-after evidence.
When to use it
Something is slow and optimisation is starting from intuition.
What to prepare
The goal, relevant source material, constraints, examples, and the decision or action this should support.
How to get a strong result
Do not optimise before the measurement stage confirms the bottleneck; intuition about performance is usually wrong.
How to use this prompt
Replace each placeholder with accurate context. Paste the complete prompt into Claude, review the response critically, resolve important questions, and use it as a considered input to the next decision—not as an unchecked final answer.