Channels
Session Bridge Openclaw
Cross-channel session context bridging plugin for OpenClaw. Load conversation context between webchat, Telegram, Discord, and more via Gemini AI summarization.
Configuration Example
{
"plugins": {
"entries": {
"session-bridge": {
"enabled": true,
"config": {
"geminiModel": "gemini-3-pro-preview",
"maxTranscriptChars": 200000
}
}
}
}
}
README
# Session Bridge for OpenClaw
Cross-channel session context bridging for [OpenClaw](https://github.com/openclaw/openclaw). Load conversation context from any session into any channel β webchat, Telegram, Discord, WhatsApp, etc.
## What It Does
When you're working on a project in webchat and want to continue on Telegram (or vice versa), Session Bridge lets you:
1. **List** all your sessions across channels with auto-generated names
2. **Load** a session's full context into your current chat via Gemini AI summarization
3. **Name** sessions with custom titles for easy reference
4. **Browse** historical/archived sessions
## How It Works
```
/session list β See all active sessions with names
/session list --all β Include historical/archived sessions
/session load <# or name> β Load session context into current chat
/session name <title> β Name the current session
/session rename <# or name> <title> β Rename any session
/session help β Show commands
```
### Example
```
You (on Telegram): /session list
π Active Sessions:
1. π¬ session "Electron Window Manager Build", webchat, 3m ago
2. β° cron "Proton Mail Bridge Sync", 1d ago (52 runs)
3. π¬ session "Side Project", telegram, 2h ago
You (on Telegram): /session load 1
β
Session "Electron Window Manager Build" loaded!
Context has been injected into your current session...
```
Now the AI assistant in your Telegram chat has full context from your webchat conversation and can continue seamlessly.
## How Context Transfer Works
1. Reads the session's JSONL transcript
2. Sends it to **Gemini 3 Pro Preview** for extensive summarization
3. Summary is formatted as structured JSON with: topic, decisions, technical details, current status, open items, preferences, key files, and people
4. Summary is injected into the current session via OpenClaw's system event mechanism
5. The AI assistant sees the summary and can continue the work naturally
## Installation
### From source
```bash
# Clone the repo
git clone https://github.com/clockworksquirrel/session-bridge-openclaw.git
# Copy to OpenClaw extensions
cp -r session-bridge-openclaw ~/.openclaw/extensions/session-bridge
```
### Manual
Copy the files to `~/.openclaw/extensions/session-bridge/`:
```
~/.openclaw/extensions/session-bridge/
βββ index.ts
βββ openclaw.plugin.json
βββ package.json
```
### Enable in config
Add to your `~/.openclaw/openclaw.json`:
```json
{
"plugins": {
"entries": {
"session-bridge": {
"enabled": true,
"config": {
"geminiModel": "gemini-3-pro-preview",
"maxTranscriptChars": 200000
}
}
}
}
}
```
Then restart the gateway:
```bash
openclaw gateway restart
```
## Configuration
| Key | Default | Description |
|-----|---------|-------------|
| `geminiModel` | `gemini-3-pro-preview` | Gemini model for summarization and naming |
| `geminiApiKey` | *(auto-detected)* | Gemini API key. Auto-resolves from: plugin config β `GEMINI_API_KEY` env β macOS Keychain |
| `maxTranscriptChars` | `200000` | Max transcript characters sent to Gemini |
### Gemini API Key Resolution
The plugin looks for the Gemini API key in this order:
1. Plugin config: `plugins.entries.session-bridge.config.geminiApiKey`
2. Environment variable: `GEMINI_API_KEY`
3. macOS Keychain: `security find-generic-password -s "gemini" -a "api-key" -w`
## Requirements
- [OpenClaw](https://github.com/openclaw/openclaw) (2026.2.x or later)
- A [Google Gemini API key](https://aistudio.google.com/apikey)
## Session Types
The list view shows emoji tags for different session types:
| Emoji | Type | Description |
|-------|------|-------------|
| π¬ | session | Regular chat session (DM, webchat) |
| π¬ | dm | Direct message session |
| β° | cron | Cron job session (collapsed with run count) |
| πͺ | hook | Webhook session |
| π€ | subagent | Sub-agent session |
| π₯ | group | Group chat session |
| π’ | channel | Channel/room session |
| π§΅ | thread/topic | Thread or topic session |
| β‘ | slash | Slash command session |
| π | archived | Historical session (--all flag) |
## License
MIT
## Credits
Built by Vera π for Josh.
channels
Comments
Sign in to leave a comment