Periscope
Browser context bridge for AI agents
Periscope gives your AI agents eyes on the browser. It captures what users see — page content, text selections, navigation patterns, form interactions — and streams that context to agents in real time. Agents that consume Periscope context can assist users with full awareness of what they're currently working on, without requiring the user to copy-paste or explain their screen.
Think of it like Apple Continuity for AI: your browsing activity seamlessly flows to agents across the platform, so they can pick up exactly where you are.
How It Works
Periscope operates as a three-layer pipeline:
- The browser extension observes browsing activity and captures structured context (page metadata, text selections, navigation events, form interactions, media elements)
- The Periscope service receives context via REST or WebSocket, applies privacy filtering, stores it with user isolation, and indexes it for search
- AI agents and applications consume context through the REST API (polling, search, history) or WebSocket (real-time streaming with channel subscriptions)
Privacy filtering happens at two layers — the extension filters before data leaves the browser, and the service filters again before serving to agents. Sensitive data like passwords, API keys, and PII is automatically redacted.
What Periscope Captures
Periscope models browser activity through 7 context types and 10 event payload types:
| Capability | What It Captures | Use Case |
|---|---|---|
| Page context | URL, title, meta tags, Open Graph, content | Agent knows what page you're on |
| Text selections | Selected text, position, surrounding context | Agent can discuss highlighted content |
| Code selections | Code, language, line range, file path, repo | Agent provides code review and assistance |
| Navigation | URL changes, transition types, referrers | Agent understands browsing patterns |
| Tab activity | Tab switches, window changes | Agent tracks focus and multitasking |
| Form interactions | Field names, types, validation state | Agent assists with form completion |
| Media | Playback state, titles, services | Agent aware of media consumption |
Choose Your Path
Building an AI Agent?
Start with the Agent Integration Guide to learn how agents consume browser context. Then try the Context-Aware Chatbot Tutorial for a complete working example.
Setting Up the Extension?
Follow the Extension Setup Guide to install the browser extension and configure privacy rules for your domains.
Integrating the SDK?
Jump to the SDKs page for TypeScript and Rust client libraries, or the Getting Started guide for your first API call.
Understanding the Architecture?
Read the Concepts section to understand the data model, event system, privacy model, sync protocol, and real-time streaming architecture.
Documentation
Concepts
Understand how Periscope works under the hood.
- Browser Context Model — The BrowserContext data structure, 7 context types, and the capture-to-consumption lifecycle
- Event System — The PeriscopeEvent envelope, BasePayload pattern, and all 10 event payload types
- Privacy Model — Four privacy levels, two-layer filtering pipeline, PII redaction, and restricted domains
- Sync Protocol — SyncMessage structure, 4 payload variants, batch sync, and connection state management
- Real-Time Streaming — WebSocket channels, auth handshake, heartbeat mechanism, and multi-device propagation
Guides
Accomplish specific goals with step-by-step instructions.
- Agent Integration — How AI agents consume and use browser context
- Extension Setup — Install and configure the browser extension
- Multi-Device Sync — Synchronize context across multiple browsers and devices
Tutorials
Build complete working applications from scratch.
- Context-Aware Chatbot — Build a chatbot that knows what you're browsing
- Research Assistant — Build an agent that summarizes research sessions
- Code Review Helper — Build an agent that reviews code from GitHub PRs
Reference
Complete API and type documentation.
- REST API — Context sync, retrieval, search, and management endpoints
- WebSocket API — Real-time streaming protocol and message types
- Event Types — Field-level docs for all 10 event payload types
- Sync Protocol Types — SyncMessage, SyncResponse, and related type reference
Support
- SDKs — TypeScript (
@lovelace-ai/periscope-client) and Rust (periscope-client) client libraries - Privacy & Security — Privacy levels, data retention, filtering configuration
- Troubleshooting — Common issues and solutions
Platform Integration
Periscope integrates with other Lovelace platform services:
- Agents Cloud — Agents consume browser context to understand what you're working on and provide contextual assistance
- Memory Platform — Browser context can be persisted as agent memory for long-term recall
- Lovelace Assistant — Ada uses Periscope to provide browser-aware assistance across all surfaces
- Lovelace CLI — The CLI can read browser context for development-focused agent workflows
Quick Links
| Resource | URL |
|---|---|
| REST API (production) | https://periscope.uselovelace.com/api/v1/context |
| WebSocket (production) | wss://periscope.uselovelace.com/ws |
| OpenAPI spec | https://periscope.uselovelace.com/openapi.json |
| TypeScript SDK | @lovelace-ai/periscope-client |
| Rust SDK | periscope-client crate |
Get started: Install the extension and make your first API call in under 5 minutes.