WebAI Studio
Back to Demos

Branching Conversations

Text Input

Fork one conversation into two futures with session.clone() — both branches inherit the context, then diverge side by side.

Why On-Device?

Cloning a session copies its context without re-processing a single token — exploring multiple continuations is instant and free when the model is local.

Interactive Demo

Prompt API: Loading...
Shared Context
Run the base prompt first, then fork it.
The Optimist
This branch's continuation appears here.
The Skeptic
This branch's continuation appears here.

Implementation Code

demo.js