System prompt

Standing instructions given to a model before the conversation starts, setting its role, rules and tone.

concept

A system prompt is a block of instructions placed ahead of everything a user types. It tells the model who it is meant to be in this setting, what it should and should not do, and how it should answer.

Apps built on language models almost always use one. It is why the same underlying model can act as a cheerful tutor in one app and a terse coding helper in another.

The system prompt is still just text in the model’s context window. It shapes behaviour strongly, but it is not a hard lock, which is why apps also need other safeguards.

Example

A recipe app’s system prompt might say: “You help people cook at home. Keep answers short, use metric units, and always mention common allergens.”

Related