***

title: reset
slug: /reference/python/agents/swml-builder/reset
description: Reset the SWML document to an empty state.
max-toc-depth: 3
---------------------

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

[swmlservice-reset-document]: /docs/server-sdks/reference/python/agents/swml-service/reset-document

Reset the document to an empty state and return the builder for continued chaining.
Delegates to
[`SWMLService.reset_document()`][swmlservice-reset-document].

## **Returns**

`Self` -- The builder instance for method chaining.

## **Example**

```python {11}
from signalwire import SWMLService, SWMLBuilder

service = SWMLService(name="demo")
builder = SWMLBuilder(service)

# Build first document
doc1 = builder.answer().hangup().build()
print(doc1)

# Reset and build a different document
builder.reset()
doc2 = builder.answer().play(url="say:Goodbye").hangup().build()
print(doc2)
```