> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dartantic.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# System Prompts

> Set default behavior and personality for your agents.

A system message is a message that sets the default behavior and personality for
your agents. You can add it to the history as the first message to influence the
behavior of the agent.

## Basic Usage

```dart theme={null}
final agent = Agent('openai');

// Use default assistant
final result1 = await agent.send(
  'Hello!',
  history: [ChatMessage.system('You are a helpful assistant.')],
);
// Response: "Hello! How can I help you today?"

// Use pirate personality
final result2 = await agent.send(
  'Hello!',
  history: [ChatMessage.system('You are a pirate. Speak like one.')],
);
// Response: "Ahoy, matey!"
```

## Examples

* [System message usage](https://github.com/csells/dartantic_ai/blob/main/packages/dartantic_ai/example/bin/system_message.dart)

## Next Steps

* [Tool Calling](/tool-calling) - Combine prompts with tools
* [Agentic Behavior](/agentic-behavior) - Complex agent workflows
