> This page is for Server SDKs.

> Fetch clean Markdown by appending `.md` to any page URL under https://signalwire.com/docs or requesting it with the HTTP header `Accept: text/markdown`. The root index at https://signalwire.com/docs/llms.txt lists the available documentation indexes.

# generate_reply

> Trigger the agent to generate a reply.

Trigger the agent to generate a reply. On SignalWire the prompt handles
generation automatically; when `instructions` is provided, it is queued as
additional text to speak.

## **Parameters**

**`instructions`** `str | None` — default: None

Optional instructions to include in the reply.

---

## **Returns**

`None`

## **Example**

```python {11}
from signalwire.livewire import Agent, AgentSession, AgentServer, JobContext, run_app

server = AgentServer()

@server.rtc_session()
async def entrypoint(ctx: JobContext):
    await ctx.connect()
    agent = Agent(instructions="You are a helpful assistant.")
    session = AgentSession()
    await session.start(agent, room=ctx.room)
    session.generate_reply(instructions="Please introduce yourself to the caller.")

run_app(server)
```