Prompt Engineering Guide

You don't need to memorise tricks to get better answers from an LLM. You need a repeatable structure. This guide shows the one TPEE uses — fifteen sections, one quality score — with a worked example you can copy.

By Jacques Botte, founder of Toptronic®. Last updated 12 September 2026.

Why free-typed prompts fail

Most people type a paragraph into ChatGPT and hope. The model is doing its best with an incomplete brief, so it guesses — and a guess about what you wanted is a wasted answer. The three failure modes are the same everywhere:

None of this is the model being dumb. It's the brief being incomplete. A structured prompt fixes all three at once.

The 15-section method

TPEE splits every prompt into fifteen sections. You don't have to fill all of them every time — a short question may only need Persona, Instructions and Tone — but each one you fill removes another way for the model to guess wrong:

  1. Persona — who the model is (a senior Rust developer, a patient teacher).
  2. Instructions — the task, stated plainly.
  3. Context — the background that makes the task make sense.
  4. Technical Specifications — hard constraints (language version, limits, formats).
  5. Format — how the answer should be laid out (Markdown, JSON, bullet list).
  6. Audience — who will read the answer, so the model pitches it right.
  7. Tone — formal, friendly, terse.
  8. Data — the raw facts, references or source material.
  9. Examples — one or two examples of a good answer.
  10. Graphics — whether you want diagrams, tables or charts.
  11. MCP Servers — external tools the model may call.
  12. Verification of Results & Outcome — how you will check the result, and what good and excellent look like.
  13. Agents — sub-agents or roles for multi-step work.

WHY TPEE IS BASED ON SCIENCE

A worked example

Before (what people actually type):

"write me a python script that reads a csv and does some analysis"

After (the same request, structured):

Persona: You are a senior Python data engineer.
Instructions: Write a Python script that reads a CSV file and reports summary statistics for each numeric column.
Context: The file is exported weekly from our sales system and may contain empty cells.
Technical Specifications: Python 3.11, standard library only, no third-party packages.
Format: Output as a Markdown table of column name, count, mean, min, max.
Audience: A non-technical manager who will read the summary.
Tone: Concise, no jargon in the final table.
Examples: If a column has missing values, show the count of missing values in parentheses.

The structured version will produce a correct, complete script on the first try. The free-typed version will probably need two or three follow-ups — each one costing tokens and time. That difference is the whole point.

Why structure saves money

Every time you re-run a vague prompt because the answer missed the mark, you pay again. On a large-context model a single retry can cost hundreds of thousands of tokens. Shortening and clarifying the prompt before you send it is the cheapest optimisation there is — and the 15-section structure plus a 0–100 score does that for you. TPEE itself never calls a model; the savings are in how you prompt.

TPEE automates this checklist — from $49, one-time, no subscription.

What the 0–100 score actually measures

Every prompt in TPEE is scored out of 100 before you send it. Five categories, twenty points each, added together. The score is computed in the app, on your machine, from the text you typed — nothing is sent anywhere and no model is called. Here is the whole rubric, so you can check the number rather than trust it.

  1. Length — 20 points. Estimated tokens (characters divided by four) as a share of the chosen model's context window. Under 0.05% scores 4; 0.05–0.5% scores 8; 0.5–1% scores 12; 1–5% scores 18; 5–15% scores the full 20; 15–30% drops to 16; 30–50% to 10; 50–80% to 6; 80–100% to 3; a prompt longer than the window scores 0. The sweet spot is a detailed prompt that still leaves the model room to answer.
  2. Sections filled — 20 points. Persona, Instructions and Context are worth 3 points each, Examples 2, and each of the remaining nine sections 1 point, capped at 20. The three core sections alone score 9 of 20.
  3. Examples — 20 points. A base by size (under 50 characters 4, 50–199 8, 200–499 12, 500–999 14, 1000+ 16) plus up to 4 more for structure: numbered items, bullet lines and repeats of the word “example” are counted, so three worked examples score higher than one paragraph that merely mentions examples.
  4. Structure — 20 points. Headings, blank-line separation and lists earn general points, then a format-specific check scores the style the chosen model prefers: XML tags for Claude-style models, Markdown for GPT-style, with separate rules for spec-style, system/user and reasoning models. A Markdown prompt sent to an XML-preferring model loses points it did not have to lose.
  5. IDE features — 20 points. MCP Servers, Verification and Agents score 3, 2 and 2 for any target, then the features the chosen IDE actually uses score up to 15 more: file mentions and rule files for Cursor, instruction and workspace files for Copilot-style tools, Given/When/Then for spec-driven tools, CLAUDE.md and terminal use for CLI agents, XML artifacts for chat-style tools, system and role framing for API system messages.

What the score is not. It is a heuristic over the prompt's own text. It cannot know whether your facts are right, whether the model will follow the instructions, or whether the answer will be useful — no score can. What it does measure is the class of prompt that most often fails: too short to be specific, too long for the window, no examples, the wrong format for the model, and IDE features the tool will ignore. Fix those five and the prompt that leaves TPEE is the one you would have written with an hour more patience.

Those bands and point values are the ones in the shipped app, and each category is capped at twenty so the total cannot exceed 100. See the plans or read the real context limits the length score is measured against.