AI engineering

Stage 2 · Lesson 3 of 9

System prompts

Prompting and model APIs

The holds the instructions that apply to the whole conversation. Some providers call it the developer message. It sets the role, the rules, the tone, the and what the assistant must refuse.

The user message holds the specific request and its data. Keeping the two apart makes the model weigh your rules above what users type. It also lets you change the product's behaviour in one place.

A good system prompt explains why each rule exists, because models follow reasons better than bare commands.

Common traptreating it as a security boundary: users and injected documents (documents with planted instructions) can still talk a model out of its instructions, so enforce anything critical in code.

A question to check yourself, an AI practice session and 1 cheat sheet entry come with the full roadmap. Unlock

Resources for this stage

Start with· follow one of these

Practise

  • Run open models locally to test prompts and sampling settings at zero API cost

Keep handy

Also worth your time

Mark this stage as not done?