Today we’re launching
The key shift: sessions become channels
In a connection-oriented setup, the “session” effectively lives inside the streaming pipe. When the pipe breaks, continuity becomes a headache.
With AI Transport, the session is created once and represented as a durable channel. Agents and clients can join independently. Refresh becomes reattach and hydrate. Device switching becomes another subscriber joining the same session. Multi-device behaviour becomes fan-out rather than custom routing. Agents and humans become truly connected over a transport designed for AI bi-directional low latency conversations.
Concrete examples
Multi-device copilots: A user starts a long-running answer on desktop, switches to mobile mid-response, and the session continues without restarting. Steering and approvals apply to the same session regardless of device.
Getting started (low friction)
You can get a basic session running in minutes:
js
import Ably from 'ably';
// Initialize Ably Realtime client
const realtime = new Ably.Realtime({ key: 'API_KEY' });
// Create a channel for publishing streamed AI responses
const channel = realtime.channels.get('my-channel');
// Publish initial message and capture the serial for appending tokens
const { serials: [msgSerial] } = await channel.publish('response', { data: '' });
// Example: stream returns events like { type: 'token', text: 'Hello' }
for await (const event of stream) {
// Append each token as it arrives
if (event.type === 'token') {
channel.appendMessage(msgSerial, event.text);
}
}
SOCIAL SHARE CARD GENERATOR