The Browser Stops Being Just a Client
Rebuild the browser AI architecture from first principles, then define the chapter-driven laboratory and AI-enabled site we will construct throughout the book.
Read chapter →
Build browser-native AI from the capability boundary upward: local models, observability, WebMCP tools, agent security, and a user-owned browser policy engine.
For most of the history of web applications, the browser has occupied a clear position in the architecture.
It displays an interface.
It executes application code.
It stores local state.
It communicates with servers that perform the expensive work.
AI initially fitted neatly into that arrangement. A web application collected context, sent it across the network to a model running in a data centre, received a response, and displayed the result.
That architecture is changing.
Chrome’s built-in AI work allows pages and extensions to request AI capabilities backed by models managed by the browser. At the same time, WebMCP gives websites a way to expose structured tools to browser agents.
Put those developments together:
model inside browser
↓
context inside browser
↓
tools inside browser
↓
agent inside browser
This book studies that transition from first principles.
The durable question is not which model happens to ship in one version of Chrome. It is:
What happens when the browser stops being merely an interface to AI and becomes an AI runtime itself?
This project goes beyond explaining APIs.
Throughout the book we will build one system through two reader-facing stages.
Stage One is the Browser AI Laboratory: a full-page experience in which every chapter becomes a live experiment with capability detection, real execution when supported, captured-trace replay when it is not, and an inspectable evidence trail.
Stage Two is the AI-enabled site: the books and wider website become structured, retrievable context with typed operations, interchangeable AI runtimes and policies controlled by the user.
Browser AI Observatory is the evidence layer underneath both stages. Its DevTools extension begins as a capability probe and streaming prompt console, then grows into an application monitor, trace viewer, profiler, evaluation harness, WebMCP agent inspector and personal browser policy engine.
The extension will help answer questions that a normal chat interface hides:
The product is not saved for the final chapter. Chapter 1 establishes the laboratory shell. Every later chapter adds a runnable mechanism, while the Observatory records the evidence required to trust it. The canonical implementation lives under experiments/browser-ai-from-first-principles/ in the book repository.
flowchart TD
R[Research question] --> E[Experiment]
E --> T[Observatory trace]
T --> W[Book chapter]
W --> F[Extension feature]
F --> R
The book becomes the design record for the software.
The software becomes the experimental instrument for the book.
We will add one mechanism at a time.
capability detection
↓
model acquisition
↓
session and streaming
↓
observability
↓
evaluation
↓
structured tools
↓
permissions and policy
↓
agent runtime
At every step we will ask:
The aim is not to memorize experimental flags or one release’s model name. Those will change. The aim is to understand the architecture that remains when the implementation underneath the API changes.
This outline is a working architecture. Experiments may force chapters to split, merge or move. If the evidence changes the plan, the plan should change.
Browser AI Observatory will grow through the same parts.
| Book stage | Extension capability |
|---|---|
| Part I | Full-page laboratory, capability probe, model-download monitor, streaming trace and application bridge |
| Part II | Task API console and side-by-side comparisons |
| Part III | Session inspector, context tracking and performance profiles |
| Part IV | Fixture runner, output validation, baseline comparison and fallback trace |
| Part V | WebMCP tool explorer, call trace and security warnings |
| Part VI | Permission gate, agent timeline, personal policy engine and AI-origin content filter |
The extension will maintain an explicit evidence boundary.
It can directly observe operations it owns. It can receive application events through an opt-in SDK. It can inspect browser surfaces exposed by supported DevTools APIs. It will not pretend that application-reported events are browser-attested or that private browser internals are public instrumentation.
That limitation makes the tool more credible, not less.
Browser AI APIs and WebMCP are evolving. Some capabilities may be stable, some may require an origin trial, and others may be restricted to experimental Chrome channels or the Built-in AI Early Preview Program at the time a chapter is written.
Every implementation chapter will therefore distinguish:
The book will not silently turn an EPP announcement into a universal availability claim.
The experimental build is valuable precisely because it lets us test whether an application survives changes behind the same capability boundary. It is evidence, not permanence.
A book normally explains software.
This project uses writing, implementation and experimentation as one loop:
research
↓
experiment
↓
chapter
↓
software
↓
real use
↓
new evidence
└──────────→ research
Eventually the same browser-native AI mechanisms described here can run inside technical books and documentation: explain a selection, challenge a claim, expose prerequisites, generate an experiment, navigate related concepts and offer structured operations to an agent.
The immediate product is a live browser laboratory backed by an AI monitor and debugger. It grows into an AI-enabled site and personal browser policy engine.
The larger goal is to discover what happens when written knowledge becomes operational software.
Rebuild the browser AI architecture from first principles, then define the chapter-driven laboratory and AI-enabled site we will construct throughout the book.
Read chapter →Turn Chrome's built-in AI APIs into an observable state machine: inspect capability exposure, availability, model acquisition, session readiness, execution and failure in the chapter itself.
Read chapter →Build and run the smallest useful Browser AI Observatory: probe the Prompt API, create a session, stream a response, derive measurements from events, export evidence, and preserve the instrument boundary.
Read chapter →Turn the Prompt API console into an application-aware debugger with an executable, opt-in instrumentation bridge, versioned events, redaction, correlation, persistence and explicit evidence limits.
Read chapter →Build and run a seven-interface Browser AI switchboard: share lifecycle instrumentation while preserving each API's identity, options, operation and output contract.
Read chapter →Configure, run and evaluate a browser-managed Summarizer contract across type, length, format, preference, grounding and omission while keeping automatic checks separate from human judgment.
Read chapter →Run Writer, Rewriter and Proofreader as distinct authority contracts, preserving each operation's permitted delta, options, output shape and evaluation rather than grading generic prose.
Read chapter →Run a staged Language Detector and Translator laboratory that preserves ranked uncertainty, applies visible confidence and margin thresholds, abstains explicitly, and inspects pair-specific availability before translation.
Read chapter →Run a session-lineage laboratory that creates one Prompt API resource, establishes shared history, clones the measured state, diverges two branches, compares usage and ends both explicitly.
Read chapter →Treat browser AI context as a measurable budget, detect pressure before failure, compact history without erasing authority or task state, and test overflow honestly.
Read chapter →Decompose browser AI latency into capability, acquisition, session, first-output and completion phases, then benchmark cold and warm paths without mistaking callbacks for downloads.
Read chapter →Engineer against a browser-managed capability whose model, eligibility, assets and accepted configuration can change, while preserving evidence, compatibility and graceful recovery.
Read chapter →Separate runtime success from structural validity, semantic correctness and feature success, then place behavioral evaluation beside the browser AI trace.
Read chapter →Turn browser AI examples into representative feature evaluations with slices, baselines, repetitions, regression gates and reviewable evidence.
Read chapter →Design explicit degradation across local browser workers, deterministic alternatives and remote fallbacks without hiding capability changes or data movement.
Read chapter →Constrain, parse and validate model-produced JSON without confusing syntactic structure with semantic correctness or executable authority.
Read chapter →Replace fragile visual browser automation with explicit, typed capabilities while preserving user authority and observable effects.
Read chapter →Expose a typed read-only book operation through WebMCP, validate its arguments, bound its results and inspect the complete call lifecycle.
Read chapter →Evaluate browser-agent tool discovery, selection, argument construction, execution and result use as separate behavioral stages.
Read chapter →Defend browser agents when page content, tool metadata and tool results can influence models that possess executable capabilities.
Read chapter →Design approvals around concrete effects, bind authorization to validated arguments and preserve a complete record of consequential browser-agent actions.
Read chapter →Turn browser-native AI, interchangeable runtimes and observable decisions into a user-owned policy layer for the web experience.
Read chapter →Build a provenance-first, uncertainty-preserving and reversible browser filter for content with evidence of AI origin.
Read chapter →Complete the browser AI architecture as a portable, inspectable and reversible layer of user control over models, tools and rendered experience.
Read chapter →