How It Works

How Prompt Engineering Actually Works

The mechanics of getting useful answers from AI: context, constraints, examples, and the patterns that work — without the theatre.

10 min read June 2026 Token by Token

You've seen the term. Here's what it actually means

There's a moment that happens in almost every business I've spoken to. Someone discovers ChatGPT, starts using it for emails and proposals, and quickly hits a wall. The AI writes something almost right — but not quite. It misses a detail. It uses the wrong tone. It ignores half the instructions. So they do what anyone would do: they try again, tweaking the words, adding more detail, shouting in ALL CAPS. Sometimes it gets better. Often it gets worse.

And then they see someone online talk about "prompt engineering" like it's a dark art — a secret language that unlocks the AI's true potential. It sounds technical. It sounds like something you need a course for.

You don't. Prompt engineering is just the skill of asking for what you want in a way the AI can actually deliver. It's not magic. It's structured communication with a very fast, very literal assistant that has no common sense and no memory of your life.

This article is about how to get good at it — and when to stop trying.

"A prompt is not a command. It's a carefully structured request that gives the model enough context to predict something useful rather than something plausible-sounding. The difference between a good prompt and a bad one is usually clarity, not cleverness."

— The working definition I use with clients

What prompt engineering actually is

Let's strip away the mystique. A large language model — the technology behind ChatGPT, Claude, and the others — is a prediction engine. It has read an enormous amount of human text and learned patterns: what words tend to follow other words, what structures appear in different contexts, what responses look like in various situations.

When you send it a prompt, you're not "programming" it. You're giving it a starting point and asking it to continue in a way that would be plausible given everything it has seen. The model doesn't know your business. It doesn't know your client. It doesn't know that "ASAP" to you means "by Thursday" and not "whenever you get to it."

Prompt engineering is the practice of structuring your request so the model's prediction lands where you want it to. Think of it like giving directions to someone who's never been to your city. They have a general sense of geography — they've seen maps — but they don't know which turn is yours unless you describe it clearly. If you say "take the highway and then turn near the shops," they'll end up somewhere approximate. If you say "take the M1 north, exit at Robina, turn left at the second set of lights past the Caltex," they'll get there.

The model is the same. Vague prompts produce vague results. Specific prompts produce specific results. The skill is learning what "specific" means to a machine with no shared context.

The anatomy of a good prompt

A good prompt isn't one clever trick. It's a combination of several elements, each doing a specific job. Here's the structure I use with clients, and the one I teach to teams who want to get consistent results from AI without burning hours on trial and error.

Context: where are we?

The model has no idea who you are, what you do, or why you're asking. You need to give it enough background to answer usefully. This is the element most people skip — they jump straight to the task and wonder why the output feels generic.

Weak: "Write an email to the client."

Better: "I run a small electrical contracting business in Brisbane with three staff. A commercial client asked for a quote three weeks ago. We sent it. They haven't responded to our follow-up email from last week. Write a polite, professional email checking in without being pushy. We want to keep the relationship warm because they've referred two other clients to us previously."

The second version gives the model a role, a location, a team size, a relationship history, a timeframe, a tone, and a strategic goal. That's not over-engineering — that's the minimum information needed for a useful prediction. The model now knows this isn't a cold lead. It knows warmth matters. It knows not to be pushy.

Task: what do you want?

Be explicit about the output you need. The model can't read your mind. If you want bullet points, say "bullet points." If you want a table, say "in a table." If you want a first draft that you'll heavily edit, say "rough first draft." If you want something you can send with minimal changes, say "ready to send after a quick review."

Weak: "Tell me about cash flow."

Better: "Summarise the key drivers of small-business cash flow in three bullet points. Then list two common warning signs. Keep it under 150 words. Write for a tradesperson who understands their trade but finds finance intimidating."

Constraints: what should it avoid?

Models are eager to please. They'll confidently include information you didn't ask for, use jargon you wanted avoided, or adopt a tone that doesn't match your brand. Constraints close those doors.

Common constraints I use:

That last one is more important than it sounds. AI models have read a lot of generic business writing, and they will reproduce it unless you explicitly tell them not to.

Examples: show, don't just tell

This is where prompt engineering gets genuinely powerful. If you show the model what "good" looks like, it will pattern-match against your example rather than against generic internet text. This is the single biggest upgrade most people can make to their prompting.

Example for a mortgage broker:

"Here is how I usually write follow-up emails to clients:

Hi [Name],

Just checking in on the home loan application we discussed on [date]. No pressure at all — I know these decisions take time and there's a lot to think about. If you have any questions about the rates or need me to explain any part of the paperwork, just give me a shout.

Cheers,
[My name]

Now write a similar follow-up for a client who received their pre-approval two weeks ago and hasn't sent through the requested documents."

This is called few-shot prompting — giving the model examples of the desired output before asking for something new. It works because the model is fundamentally a pattern-matching engine, and you're giving it the right pattern instead of making it guess.

Output format: how should it look?

If you need structured output, describe the structure. JSON, markdown tables, numbered lists, email format — the model can handle all of them if you ask clearly. This is especially useful when you're feeding AI output into another system, or when you want consistency across multiple responses.

Example: "Respond in this format:

Formatting instructions are cheap — they add almost no tokens — but they dramatically improve usability. Always worth including.

Common prompt patterns that actually work

Over the last few years, researchers and practitioners have identified patterns that reliably improve results. Here are the ones that matter for business use, with real examples.

Zero-shot vs few-shot

Zero-shot means giving the model a task with no examples. It works well for straightforward requests where the desired output is obvious from the instruction.

Few-shot means including one or more examples of the desired output in the prompt. It works better for tasks with a specific style, format, or nuance. The trade-off is that examples consume tokens — and tokens cost money.

For most business use, I recommend starting with zero-shot and moving to few-shot only when the output isn't quite right. Don't waste tokens on examples the model doesn't need. A zero-shot prompt for "summarise this report" is usually fine. A few-shot prompt for "write in my voice" is usually necessary.

Role prompting

Telling the model to adopt a persona can improve results for specialised tasks. "Act as an experienced mortgage broker writing to a first-home buyer" tends to produce more relevant output than "write about mortgages" because the model activates the patterns it learned from mortgage-related text.

But don't overdo it. "Act as a world-famous Nobel Prize-winning economist who also does stand-up comedy" is more likely to produce theatrical nonsense than useful advice. Keep the role close to the actual task. "Act as an experienced accountant explaining GST to a new cafe owner" works. "Act as a wise sage from a fantasy novel" does not.

Chain-of-thought

For complex reasoning tasks — comparing quotes, analysing data, making recommendations — asking the model to "think step by step" often produces better results. It forces the model to lay out its reasoning before giving a conclusion, which tends to surface errors and produce more defensible outputs.

Example: "Before giving your recommendation, explain your reasoning step by step. Consider price, warranty terms, delivery timeframe, and the supplier's reputation. Then provide the final answer in a single sentence."

This doesn't make the model "smarter." It changes the prediction task from "what's the most likely conclusion?" to "what's the most likely step-by-step reasoning followed by a conclusion?" The second task tends to produce more structured, less error-prone results because the model has to build the argument explicitly.

What goes wrong: the reality check

Here's where I earn my credibility by being honest about failure modes. Prompt engineering doesn't always work, and understanding why saves you from chasing your tail.

The AI ignores your instructions

This happens constantly. You ask for "three bullet points" and get five paragraphs. You say "don't mention price" and the second sentence is about pricing. You ask for "short" and get 400 words. You say "use Australian English" and it writes "neighbour" correctly but still uses "zee" instead of "zed" in an acronym.

Why: The model is predicting the most likely continuation, not executing your instructions like a computer program. If its training data contains lots of long responses to similar prompts, it will produce a long response regardless of your constraint. Its weights favour patterns over instructions.

What to do: Repeat critical constraints. Put them at the beginning AND the end of the prompt. Use formatting to make them harder to ignore. Be specific: "exactly three bullet points" is harder to ignore than "a few bullet points." And accept that perfect compliance is rare — plan for review and correction. The AI is an assistant, not an employee.

Over-engineering the prompt

There's a temptation to keep adding layers: more context, more constraints, more examples, more formatting instructions. At a certain point — usually around 500–800 words of prompt — the model starts to lose track of earlier instructions. It focuses on the most recent text and forgets what you asked for at the top.

This is the recency bias of attention mechanisms. The model doesn't have infinite focus. A prompt that tries to cover every edge case often performs worse than a simpler prompt that covers the 80% case and accepts human review for the rest.

Rule of thumb: If your prompt is longer than the response you want, you're probably over-engineering. I've seen people write 600-word prompts to generate a three-sentence email. That's not prompt engineering — that's writing the email by proxy, with extra steps.

Hallucinations from bad prompts

A hallucination is when the AI confidently makes something up. Bad prompts make this worse. If you ask vague questions about specific facts — "What are the tax rules for my business?" — the model will invent specifics rather than admit it doesn't know your situation. It'll tell you about deductions you can't claim and thresholds that don't apply to your structure.

What to do: Ground the prompt in documents or known facts. Use RAG (retrieval-augmented generation) to pull real information into the prompt before asking the question. Or frame the question broadly: "What are common considerations for small business tax in Australia?" rather than "What are MY tax obligations?"

I once saw an accountant use AI to generate client advice without grounding it in the actual legislation. The model invented a depreciation rule that hadn't existed for three years. The accountant caught it — but only because they knew to check. If they'd blindly sent it, the client would have claimed the wrong amount and faced an audit.

The "jailbreak" distraction

You'll see articles about "secret prompts that unlock the AI's full power." These are almost universally nonsense. The model doesn't have hidden capabilities that only clever phrasing can access. What it has is a statistical distribution of plausible text, and some phrasings push it toward different parts of that distribution.

For business use, ignore jailbreak culture entirely. Focus on clarity, examples, and constraints. That's where the real gains are. The people selling "1000 secret prompts" are selling entertainment, not education.

What it actually costs

Prompt engineering has a cost in time and money. Here's the honest breakdown from someone who tracks this for clients.

Time: A well-crafted prompt takes 5–20 minutes to write and test. A sloppy prompt takes 30 seconds but produces output that needs 10 minutes of editing. Over a week of regular use, good prompts save hours. An accountant I work with spent 15 minutes building a prompt template for engagement letter review. It now saves her roughly 45 minutes per client — and she reviews 8–10 clients a week. That's 6–7 hours saved for 15 minutes of upfront work.

Tokens: Every word in your prompt costs money. A 500-word prompt on a mid-tier model might cost $0.01–$0.05 per request. If you're running 100 requests a day, that's $1–$5 in prompt costs alone. Add the response tokens and you might be at $3–$10 a day. For a high-volume operation, this adds up to $100–$300 a month just in prompt and response tokens.

Few-shot trade-off: Including examples in your prompt can double or triple the token cost. For high-volume use, this matters. For occasional use, the improved quality is worth it. I typically recommend few-shot for outputs that need a specific voice or format, and zero-shot for everything else.

The hidden cost: Time spent arguing with the AI. A bad prompt generates a bad response, which leads to another prompt, which leads to another response, which leads to frustration. A good prompt gets it mostly right the first time. The difference is 30 seconds of thought versus 10 minutes of frustrated iteration.

For a mortgage broker using AI to draft client emails, investing 20 minutes upfront to create a reusable prompt template saves roughly 2–3 hours a week. For an accountant generating report summaries, a well-structured prompt saves 15 minutes per report. At 10 reports a week, that's 2.5 hours. For a tradesperson writing quotes, a solid prompt saves 10 minutes per quote — and if you send five quotes a week, that's nearly an hour.

What it actually takes: a practical toolkit

You don't need a course. You don't need to learn Python. You need a notebook and some discipline. Here's what I tell clients who want to get better at prompting.

Keep a prompt library. Every time you write a prompt that works well, save it. Note what worked and what didn't. Over time, you'll build a collection of reliable templates for your recurring tasks. I keep mine in a simple text file organised by task type: emails, summaries, analysis, drafting. When I need a prompt, I copy a working one and adapt it. This prevents starting from scratch every time.

Test variations systematically. Change one thing at a time. If you change the context, the task, and the format all at once, you won't know what made the difference. Prompt engineering is more science than art — control your variables. Try the context first. Then add constraints. Then add examples. Measure the output quality at each step.

Review outputs honestly. When the AI gets something wrong, ask: was the prompt unclear? Was the task ambiguous? Did I give it false assumptions? Most "AI failures" are actually communication failures. The model didn't fail — it did exactly what your prompt predicted it should do. Fix the prompt.

Know when to stop. If you've rewritten the prompt three times and it's still not right, the task might be too nuanced for AI, or you might need to break it into smaller steps. Not everything should be automated. Some tasks require judgment, context, or empathy that a prediction engine can't replicate.

When to stop optimising

This is the most important section, and the one most articles skip.

Prompt engineering has diminishing returns. A prompt that goes from "bad" to "pretty good" is transformative. A prompt that goes from "pretty good" to "slightly better" might take an hour of tweaking and save you 30 seconds of editing. That's not a good trade.

My rule: if the output is 80% right and takes less than 2 minutes to fix manually, stop optimising the prompt. Your time is worth more than marginal gains. I see people spend 45 minutes perfecting a prompt that generates a weekly report summary. They could have written the summary manually in 20 minutes. The prompt only pays off if you use it 20 times — and by then, the model has probably changed anyway.

The other time to stop is when the task requires genuine judgment, empathy, or domain expertise that the model can't replicate. AI can draft a condolence message, but it can't mean it. AI can compare quotes, but it can't understand the relationship behind the decision. AI can summarise a meeting, but it can't know which passing comment was actually the critical signal. Know the boundary. Use the AI for the parts it's good at. Handle the rest yourself.

What to do next

If you've read this far, you probably have one specific task in mind that the AI almost does but doesn't quite get right. Maybe it's the tone of your client emails. Maybe it's the format of your weekly summaries. Maybe it's the way it keeps adding paragraphs when you wanted bullet points.

Here's what I'd do:

  1. Write down the task as you'd explain it to a new staff member — not to a computer. Use natural language. Don't worry about "prompt engineering syntax."
  2. Add context: who you are, who the reader is, what the situation is, what the relationship looks like.
  3. Add constraints: tone, length, format, things to avoid, assumptions to make.
  4. Include one example of the desired output if you have one. If not, describe what "good" looks like in detail.
  5. Send it, review the result, and adjust ONE thing at a time. Don't change everything at once.
  6. Save the final prompt in your library. You'll use it again.

That's it. No courses. No certificates. No "secret frameworks." Just clear communication with a very fast, very literal assistant that has read most of the internet and will confidently guess if you don't tell it otherwise.

The best prompt engineers I know aren't technical wizards. They're just people who are unusually clear about what they want.

Want someone to review your prompts and workflow?

I help tradespeople, mortgage brokers, accountants, and professional services firms get reliable, consistent output from AI. If your prompts are 70% right and you want 90%, or if you're spending more time tweaking prompts than using the results, get in touch for a free, no-pressure assessment.