Coders In Hoods
  • Courses
  • Roles
  • Blog
  • Setup

Coders In Hoods AI Academy

Every course is free. Sign in to start, and your progress, quiz scores and bookmarks follow you.

AI Academy

  • Courses
  • Paths
  • Setup guides
  • How we teach

Role roadmaps

  • AI Engineer
  • Forward Deployed Engineer
  • Machine Learning Engineer
  • All roles

Coders In Hoods

  • The agency
  • Coaching for teams
  • Blog
  • LinkedIn
  • X (Twitter)

Contact

codersinhoods@gmail.com

© Coders In Hoods · since 2019

Course overview

Prompt and Context Optimisation

Free · sign in to start and track progress

1 · Designing prompts systematically

  • 1Prompting current Claude models

    Exercise answers

    • Answer: Rewrite the searches summariser and measure it
    • Answer: Effort versus prose instructions
  • 2Choosing few-shot examples
  • 3Eval-driven prompt iteration

2 · Optimising and operating prompts

  • 4Automatic prompt optimisation
  • 5Optimising tools, instructions and skills
  • 6Prompt registries and online tests
  • 7Model migration and regression suites
CapstoneOptimise and ship the questions drafterReference implementation

Module 1 · Designing prompts systematically · Lesson 1

Prompting current Claude models

How current Claude models read a system prompt, how to structure one for a production step, and which habits from older models (shouting, scripted reasoning, prefill, sampling knobs) to delete, with a report summariser rewritten end to end.

65 min 1 video 3 exercises 7-question quiz Answers
Setup for the exercises:Install Claude CodePython with uv

By the end of this lesson you can

  • Structure a production system prompt into role, context with reasons, task, inputs and output contract, and place long documents correctly
  • Explain why emphasis, "think step by step", prefill and sampling parameters are obsolete or harmful on current Claude models, and name the API feature that replaces each
  • Distinguish context the model cannot know from instructions it already follows, and apply that test to delete prompt lines safely
  • Choose effort and thinking settings as configuration rather than prose, and explain why prompt bulk is a behaviour problem before it is a cost problem

On this page

  • How a current model reads your prompt
  • The anatomy of a production prompt
  • What current models no longer need
  • Worked example: rewriting the summariser
  • Effort, thinking and the prompt
  • Misconceptions and limits
  • Connections
  • Summary
  • Sources & further reading
  • Quiz

In this lesson

  1. 01How a current model reads your prompt
  2. 02The anatomy of a production prompt
  3. 03What current models no longer need
  4. 04Worked example: rewriting the summariser
  5. 05Effort, thinking and the prompt
  6. 06Misconceptions and limits
  7. 07Connections
  8. 08Summary

Sources & further reading

  • The Prompt Report: A Systematic Survey of Prompt Engineering TechniquesPaper · Schulhoff et al. · 2024A taxonomy of 58 text prompting techniques with a shared vocabulary. Skim sections 2 and 6 to see how many named techniques are now built into models or APIs.
  • Quantifying Language Models' Sensitivity to Spurious Features in Prompt DesignPaper · Sclar, Choi, Tsvetkov and Suhr · 2023Shows that meaning-preserving formatting changes can swing accuracy by large margins on few-shot tasks. The reason to measure rather than trust a formatting habit (ICLR 2024).
  • Large Language Models Can Be Easily Distracted by Irrelevant ContextPaper · Shi et al. · Google · 2023Evidence that irrelevant text in a prompt lowers accuracy. Why padding and stale instructions are not harmless (ICML 2023).
  • Prompting best practicesDocs · AnthropicThe reference for current Claude models. Read "General principles", "Long context prompting", "Migrating away from prefilled responses" and "Migration considerations".
  • Prompting Claude Sonnet 5.5Docs · AnthropicModel-specific behaviour and tested prompt snippets for effort, scope, JSON on reasoning tasks and tool use. A model of how vendor guidance is now written per model.
Free · sign in to start

Sign in to keep reading.

Free, no card. We use your account to save progress, quiz scores, bookmarks and occasionally send updates from our team.

  • 8 more sections
  • 3 hands-on exercises
  • A 7-question quiz
  • Progress, quiz scores and bookmarks