Models and prompts
Model, with Reasoning and Thinking settings, and the System and Developer prompts.
A definition names the models an agent uses, with the settings it calls them with, and the prompts it gives them.
Model
A model the agent uses, with the settings it’s called with.
Settings are an allowlist, so a client’s headers, keys or other options
can’t end up in a definition. Leave a setting out (None) unless it’s
set; library defaults that are set should appear as set.
Example:
python
ga.Model("openai", "gpt-4.1", temperature=0, max_tokens=1024)
ga.Model("anthropic", "claude-sonnet-5", thinking=ga.Thinking("enabled", 2048))Attributes:
- provider (
str) – Who serves the model, such as"openai"or"anthropic". - model (
str) – The model’s name, as the provider’s API takes it.
Reasoning
Reasoning settings, as OpenAI’s reasoning models take them.
Attributes:
- effort (
str | None) – How hard the model reasons, such as"medium". - summary (
str | None) – Whether and how it summarises its reasoning.
Thinking
Extended-thinking settings, as Anthropic’s models take them.
Attributes:
- type (
str) –"enabled","disabled"or"adaptive". - budget_tokens (
int | None) – The most tokens the model may think with.
System
A system prompt: the agent’s instructions.
Example:
python
ga.System("You plan the steps needed to resolve a ticket.")
ga.System(Path("prompts/planner.md")) # read now, as UTF-8Developer
A developer prompt: instructions in the developer role.
Example:
python
ga.Developer(Path("prompts/house-style.md"))