Prompt Engineering · Masterclass · Prompt methods & quality

Few-Shot Examples for Maths Prompts: A Masterclass on Selection, Order and Effect

Steer the style, structure and level of your maths outputs with a few carefully chosen examples, and measure whether they really help or whether the model is just copying surface features.

  • Workshops & trainings since 2014
  • jocapps GmbH · Freiburg, Germany
  • The team behind Mathe-VollLogo
Format
Masterclass
Duration
Half day (3.5 hours)
Delivery
Live online · On-site (in-house) · Hybrid
Group size
4–10 participants
Level
Advanced
Language
German or English

Tools: Claude · ChatGPT · Anthropic API · OpenAI API · promptfoo

Few-shot prompting means giving the model a handful of examples to follow. In maths applications this is both powerful and treacherous: well-chosen examples produce consistent hints and fitting distractors, while poorly chosen ones lead the model to copy numbers, sentence patterns or even mistakes from the template. This masterclass shows how to choose few-shot examples for maths prompts by coverage, variety and difficulty, use contrast pairs of good and bad examples, design order and formatting deliberately and load examples dynamically to match the task. You test every variant against a small eval set.

Who the few-shot masterclass is for

Experienced prompt developers, content teams and learning design specialists in edtech, publishing and university projects who run prompts for hints, feedback, distractors or marking in production. Confidence with system prompts is assumed.

What you'll walk away with

  • Choose examples for coverage of exercise types, variety of numbers and the right level of difficulty
  • Use contrast pairs of successful and failed outputs without the model adopting the mistakes
  • Design the order, separation and formatting of examples deliberately and compare their effect
  • Have examples selected dynamically from a maintained collection by topic and level
  • Decide with a small eval set whether examples help or whether clear rules without examples work better

Typical scenarios

  1. A hint prompt keeps reusing the numbers from its examples; after switching to examples with varied values and exercise types, the pattern appears far less often in the eval set.
  2. For multiple-choice items on fractions, a prompt generates distractors that each reflect one typical misconception, because every example names the underlying error explicitly.
  3. A feedback prompt for student solutions loads two suitable examples from a maintained collection depending on the topic, instead of always sending the same fixed examples.

Does this fit your team?

Pick a few dates that suit you. The request is non-binding, and the agenda is tailored in a short call beforehand.

Request dates

What the few-shot masterclass covers

  1. What examples doHow models pick up patterns from examples, from format and tone to unintended numbers and errors.
  2. Selection and varietyCoverage, variation of values, difficulty, edge cases and how many examples make sense.
  3. Contrast and formattingGood and bad examples side by side, clear separation with markers, ordering and explanations.
  4. Dynamic example selectionExample collections with metadata, selection by topic and level, and limits on context size.
  5. Measuring the effectRun variants against an eval set, weigh cost against benefit and record the decisions.

Before the few-shot masterclass: prerequisites

  • Experience with system prompts and at least one maths prompt in production
  • Access to a model API or a chat assistant with project or system prompt features
  • Some real inputs and outputs of your prompt as starting material

Materials you keep

  • A guide to selecting, ordering and maintaining few-shot examples in maths prompts
  • A revised example collection for one of your prompts
  • A small eval set comparing the variants you tested

How it works

  1. Request with preferred datesTick the date proposals that suit you or name a period of your own.
  2. Short callWe talk about your goals, prior knowledge and the tools your team already uses.
  3. Agenda for your teamYou receive a plan tailored to your group, with exercises that match your subject and material.
  4. Course and materialsThe course runs online, on-site or hybrid, and you keep the materials afterwards.

Why train with us

  • jocapps GmbH has offered workshops and trainings since 2014. The topics have moved with the technology; today the focus is on agentic coding and prompt engineering.
  • Hands-on rather than slides: you practise on realistic examples from maths and STEM, or on your own tasks, code or prompts if you wish.
  • Online, on-site or hybrid, held in German or English.
  • jocapps GmbH is certified to ISO 27001 (information security) and ISO 9001 (quality management).

Questions about the few-shot masterclass

How many examples are ideal?

There is no universal number. A few well-chosen examples are often enough, and sometimes clear rules without examples work better. The key is to compare variants on your own eval set while keeping an eye on context length and cost.

May examples contain mistakes?

Yes, as clearly labelled negative examples, for instance hints that give too much away. What matters is the labelling and an explanation, so that the model does not imitate the mistakes. In the masterclass we test when contrast pairs help and when they tend to hurt.

Does few-shot prompting replace fine-tuning?

For many tasks in educational applications it does, because examples are quick to change and easy to check. Fine-tuning can pay off when very large numbers of uniform outputs are needed and examples would overload the context. We weigh this up using your own use cases.

Is the masterclass held online or on-site, and in which language?

Both are possible: live online, at your premises (in-house) or hybrid. The course is held in German or English; you choose when you send the request.

Can the content be tailored to our team?

Yes. The agenda, examples and emphasis are agreed in the call beforehand, based on your team's prior knowledge, subjects and tools. On request we work with your own exercises, data or code.