Five Context Components
With each LLM call, the context consists of five parts:
- System prompt;
- Tool definitions;
- User messages;
- Model responses (reasoning + content + tool_calls);
- Tool execution results.
The first two are a static prefix, unchanged throughout the dialogue; the last three are a dynamic trajectory.
Ablation shows the indispensability of each:
- without tool definitions the agent cannot act;
- without tool results it loops;
- without reasoning decisions contradict each other.
Related: Agent Cycle in Code, Chat Template, Context Engineering