Explain system prompt vs user message vs assistant turn.medium
Answer
System prompt: sets persistent context, persona, constraints — not part of conversational turn, processed first.
Explanation
System prompt: sets persistent context, persona, constraints — not part of conversational turn, processed first. User message: human input for this turn. Assistant turn: model response. Full history (system + alternating user/assistant) is passed each call — the API is stateless. In a document extraction pipeline: system prompt defines extraction schema and rules; user message contains the document chunk.
Follow-upWhen would you choose one approach over the other?