Inspiration

Most agent-enabled websites treat the agent as an invisible automation layer: it clicks through an interface while the human waits for a result. We wanted to explore something more native to the web—an experience intentionally designed around the different strengths of a person and an agent.

The Last Signal is a cooperative escape room for one human and one browser agent. The player is trapped aboard a failing orbital communications station with twelve minutes to restore its systems and release an evacuation airlock. The human interprets the environment, makes judgment calls, and controls physical authorization points. The agent inspects and operates station machinery using structured WebMCP tools.

Why this use case is a strong fit for WebMCP

Escape rooms are built from stateful objects, constrained actions, hidden dependencies, and consequences. Those concepts map naturally to WebMCP tools. Instead of scraping a visual control panel or guessing which DOM element represents a relay, the agent can discover an inspect_power_grid tool, read its JSON Schema, test a proposed configuration, and then call route_power with validated relay identifiers.

The page's available capabilities change with the state of the game. Restoring power reveals communications tools. Decoding the transmission reveals vault tools. Opening the vault reveals the final evacuation tool. This makes WebMCP discovery part of the game mechanic rather than a thin API wrapper around buttons.

The final puzzle demonstrates the human-in-the-loop model directly: engage_emergency_release cannot succeed until the human activates a physical override in the visible interface. That override lasts ten seconds and is checked against live page state. The agent has structured actuation, but the person retains meaningful control.

How it creates a better user experience

Every agent action updates the same interface the player is watching. When the agent routes power, panels illuminate. When it analyzes a frequency, the decoded fragment appears in the receiver. When it combines inventory items, the new authorization token appears in the player's inventory. A shared chronological mission log attributes every action to the human, agent, or station.

This gives the player situational awareness and makes agent behavior legible. The agent receives precise, recoverable error messages instead of silently failing against a visual interface. The player can understand what happened, why it happened, and what capabilities became available next.

The experience also progressively enhances. In a WebMCP-capable client, the agent operates structured tools. In an ordinary browser, the complete game remains playable through equivalent manual controls, making the project easy to evaluate and accessible outside experimental environments.

What people and agents can now do together

The Last Signal creates a shared interactive world rather than dividing the experience into "chat" and "website." The human and agent can inspect the same evidence, manipulate the same state, recover from each other's mistakes, and perform a synchronized final action.

Previously, recreating this experience would require brittle screen-coordinate automation, custom browser integrations, or a separate MCP server disconnected from the current visual page. The agent would need to infer the meaning of relays, signal fragments, inventory objects, and locked controls from presentation markup. WebMCP lets the website declare those capabilities and their valid inputs directly while keeping execution visible in the page.

Neither participant can deliver the intended finale alone. The agent needs the human's time-limited physical authorization; the human benefits from the agent's structured inspection and rapid operation of linked systems. That complementary relationship is the core of the project.

How WebMCP was implemented

The application registers 16 imperative WebMCP tools with document.modelContext.registerTool(). Every tool has a focused description, a constrained JSON Schema, structured success and error results, and annotations identifying read-only versus mutating behavior.

Tools and human controls call the same command layer. Each command validates preconditions, updates the central game state, records an attributed timeline entry, rerenders the visible room, and returns structured context to the agent. This prevents the manual and agent experiences from diverging.

Tool lifetimes are state-dependent. Each registration receives an AbortSignal; when the mission resets or a capability is not yet available, its controller is aborted. Communications, vault, and evacuation tools are registered only after their prerequisite systems have been unlocked. The deployed site also sends Origin-Agent-Cluster: ?1 and Permissions-Policy: tools=(self) headers.

Built With

Share this project:

Updates

Submission history