🧩systemPrompt Option
Also known as system_prompt, claude_code preset, Claude Agent SDK systemPrompt
The option that sets what the agent is told before any task.
Think of it like
It is like a job card a new helper reads on day one.
Example
Leo's agent kept skipping the test run. He switches to the claude_code preset and appends one line asking it to run the tests.
Why it matters
The default is thin. With no prompt set, the agent acts less like Claude Code than you think.
Definition
Example code
typescript
systemPrompt: {
type: "preset",
preset: "claude_code",
append: "Always run the tests.",
}Common mistake
Key takeaways
- 1Minimal by default. Tool calls only.
- 2claude_code preset. The full prompt.
- 3append adds to it. Keeps the rest.