How I Prompt
TL;DR Highlight
Asking where the model gets each piece of information made agent prompts work; 99% of Amp is AI-written.
Who Should Read
A backend developer who gives coding agents short instructions, gets off-target results, and wants better prompting habits.
Core Mechanics
- One question drives everything
- When writing a prompt, ask how the model is supposed to know what you mean.
- Information comes only from training data or the context window (everything sent to the model).
- The context window holds the system prompt, tool definitions, conversation, tool results and your prompt.
- A model won't ask what you mean
- With just "fix the upload bug", the model won't ask which bug.
- It says "you're absolutely right" and fixes whatever it assumes the bug is.
- Picture a senior engineer kidnapped and handed a single note.
- Big features got all the information
- The daemon mode prompt pointed to three folders, three files and docs.
- It also stated constraints like no checkouts, no work trees and managing process lifetime.
- This information lives in neither the training data nor the codebase, so it went into the prompt.
- Changes point at sources
- Two weeks later the change prompt told the agent to read the relevant files and docs.
- A screenshot of a long Slack discussion with teammates carried the design context.
- The end of the prompt only spelled out the desired behavior.
- One-two punch: find first, then ask
- The first prompt makes the agent find the asset so it lands in context.
- The second prompt asks for variations.
- You don't have to put everything in the first prompt.
- Use the good implementation as the standard
- For broken web queuing, he opened with "the CLI is the gold standard, investigate it".
- He said he cared about the mechanism: queue, steer, unsteer, dequeue.
- Then he asked to make the web version work the same way.
- Auto-generate debug prompts
- Amp's dev sidebar produces markdown with IDs, data dumps, doc links and debug scripts.
- The only hand-written part was a one-line question about why something wasn't booting.
- He pastes it to an agent with read-only prod access.
Community Reactions
- Screenshots help unevenly depending on the work
- One commenter doing autonomous-vehicle road geometry says the AI can't see disconnected or self-intersecting polylines in screenshots.
- It had to dump coordinates to believe the bug existed and often claimed fixes that weren't.
- They say GPT-6 Astra is much better but still occasionally struggles.
- The asset search relies on codebase structure
- A commenter argues the same search could burn tokens in a codebase with hashed filenames and thousands of images.
- They say the author leans on familiarity with his org and that token costs can vary widely.
- Concrete counterexamples make rules stick
- One commenter found that attaching a counterexample makes the agent follow a rule literally, while a bare principle is followed loosely.
- "Be honest" failed, while "compare on canonical form because a single newline byte changed the hash before" worked.
- Newer models changed prompting
- One commenter said older models required step-by-step manual orchestration.
- They find newer models infer more and prompt subagents themselves, so workflows collapsed into instructions.
- Another said this prompting strategy probably wouldn't work without Fable.
- Run brain dumps through plan mode first
- One commenter runs similar brain-dump prompts through Codex plan mode first to align the AI.
- Weigh effort against results
- One commenter said they wouldn't craft spec-level prompts if sloppy ones give the same result.
How to Apply
- Put three kinds of sources in every prompt
- At the top of today's prompt, list at least three relevant folders, files or docs.
- Below, list constraints that aren't in the code, one per line.
- Check each item against "where would the model get this?" before sending.
- Split find and ask into two prompts
- First, ask the agent to find the relevant files.
- Once they're in context, send the change request.
- Use this only when you don't know where the target lives.
- Fix the broken side against a good reference
- If one implementation works, open with "this is the standard, investigate its mechanism".
- Then ask to make the broken one behave the same.
- Point at files for what good looks like instead of just saying it's broken.
- Add a copy-debug-context button
- Add a debug view that copies IDs, log links and data dumps as markdown.
- Paste it with your one-line question to the agent.
- Keep the agent's prod access read-only.
Try It
# Paste into a coding agent like Claude Code or Amp (the talk's method turned into a prompt)
I want to {{one-line task description}}. Before changing code, check the information below first.
[Sources]
- Relevant folders: {{folder1}}, {{folder2}}
- Relevant files: {{file1}}, {{file2}}
- Relevant docs: {{doc path}}
- Reference implementation that works well: {{e.g., CLI queuing logic file}}
[Constraints]
- {{constraint not in code 1}}
- {{constraint not in code 2}}
[Desired behavior]
{{behavior description from my head}}
Instructions:
1. Before changing code, read the sources above and summarize the current behavior you understand and any missing information.
2. If something I described can't be known from training data or the codebase, ask instead of guessing.
3. Then implement.
Next step: if the result is wrong, find which information was missing and add it to the next prompt.Terminology
Related Papers
Why Do LLMs Help with Scientific Misconduct Requests and What to Do About It?: Increasing the Trustworthiness of AI for Science
Adding an intention-analysis system prompt raised refusal of misconduct requests from 58% to 87%.
How Specification Explicitness Shapes Failure in LLM-Generated Code
Spelling out invariants, edge cases and constraints cut hidden-test failures in LLM code by 47.2%.
Same Task, Different Statement: When and How Reformulation Helps LLM Problem Solving
Rewriting problem statements to fit their type raises LLM accuracy, but blind rewriting hurts.
Show HN: STE80 Humanizer – de-AI text by writing 80% of the way to ASD-STE100
A skill strips 26 AI tells and rewrites text in short ASD-STE100-style sentences
Character-Name Concentration in LLM Fiction: Measuring Displacement and Mitigating Repetition
Drafting name candidates and filtering by frequency cut LLM character-name repetition by 95%
LLM Voice
Martin Fowler: LLM-drafted prose keeps an uncanny tone even after human editing.
The Instruction Tax on Factual Recall: Base Models Can Beat Their Instruction-Tuned Counterparts
Few-shot completion with repeated sampling on a base model beat chat: F1 0.684 vs 0.568
AI is a tool and using it well takes skill
A rebuttal to Hickey: LLMs are tools, and skill in directing and checking them decides the outcome