***

title: update_instructions
slug: /reference/python/agents/livewire/agent/update-instructions
description: Update the agent's system prompt mid-session.
max-toc-depth: 3
---------------------

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

Update the agent's system prompt mid-session. The new instructions take effect
immediately for subsequent LLM turns.

## **Parameters**

<ParamField path="instructions" type="str" required={true} toc={true}>
  The new system prompt text.
</ParamField>

## **Returns**

`None`

## **Example**

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

@function_tool
def escalate() -> str:
    """Escalate to a senior agent."""
    return "Escalating now."

server = AgentServer()

@server.rtc_session()
async def entrypoint(ctx: JobContext):
    await ctx.connect()
    agent = Agent(
        instructions="You are a junior support agent. Help with basic questions.",
        tools=[escalate],
    )
    session = AgentSession()
    await agent.update_instructions("You are now a senior support agent. Handle complex issues.")
    await session.start(agent, room=ctx.room)

run_app(server)
```