***

title: prompt_add_section
slug: /reference/python/agents/agent-base/prompt-add-section
description: Add a new section to the agent's structured prompt.
max-toc-depth: 3
---------------------

For a complete index of all SignalWire documentation pages, fetch https://signalwire.com/docs/llms.txt

[ref-agentbase]: /docs/server-sdks/reference/python/agents/agent-base

Add a new section to the prompt. Sections give the AI structured instructions that
are easier to follow than a single block of text. Each section has a title and
optional body text, bullet points, and subsections.

<Warning>
  POM sections cannot be mixed with `set_prompt_text()` in the same agent. Use one
  approach or the other.
</Warning>

## **Parameters**

<ParamField path="title" type="str" required={true} toc={true}>
  Section heading displayed to the AI.
</ParamField>

<ParamField path="body" type="str" default="" toc={true}>
  Section body text.
</ParamField>

<ParamField path="bullets" type="Optional[list[str]]" toc={true}>
  List of bullet point strings.
</ParamField>

<ParamField path="numbered" type="bool" default="False" toc={true}>
  Whether the section itself should be numbered.
</ParamField>

<ParamField path="numbered_bullets" type="bool" default="False" toc={true}>
  Whether bullet points should be numbered instead of bulleted.
</ParamField>

<ParamField path="subsections" type="Optional[list[dict[str, Any]]]" toc={true}>
  List of subsection dictionaries, each with `title`, `body`, and optional `bullets`.
</ParamField>

## **Returns**

[`AgentBase`][ref-agentbase] -- Returns self for method chaining.

## **Example**

```python {4,7}
from signalwire import AgentBase

agent = AgentBase(name="support", route="/support")
agent.prompt_add_section("Role",
    body="You are a customer support agent for Acme Corp.")

agent.prompt_add_section("Guidelines", bullets=[
    "Always greet the caller by name if available",
    "Never share internal pricing details",
    "Escalate to a human if the caller asks"
])
agent.serve()
```