Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion docs/sessions/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,20 @@ local testing, ADK also offers cloud-based and database service options.
archive* potentially spanning across conversations. Managed by a
`MemoryService`.

## Rewinding a Session

You can rewind a session to a previous state using the `runner.rewind_async` method. This is useful for debugging or re-running parts of a conversation.

**Example:**
```python
await runner.rewind_async(
user_id="test_user",
session_id="test_session",
rewind_before_invocation_id="<invocation_id>"
)
```
For a complete example, see the [rewind_session sample](https://github.com/google/adk-python/tree/main/contributing/samples/rewind_session).

## What's Next?

In the following sections, we'll dive deeper into each of these components:
Expand All @@ -82,4 +96,4 @@ In the following sections, we'll dive deeper into each of these components:
context.

Understanding these concepts is fundamental to building agents that can engage
in complex, stateful, and context-aware conversations.
in complex, stateful, and context-aware conversations.