Building Agent Interfaces: Lessons from Chrome DevTools (MCP) for Agents — Michael Hablich, Google
By AI Engineer
Key Concepts
- MCP (Model Context Protocol): A standard for connecting AI agents to external tools and data sources.
- Agent Interfaces: Designing software tools specifically for AI agents rather than human users.
- Tokens per Successful Outcome (TPSO): A metric for measuring the "fuel efficiency" of an agent interface.
- Semantic Summaries: Converting raw, high-volume data (like JSON trace files) into concise, model-readable markdown.
- Self-Healing/Error Recovery: Designing tools that provide actionable error messages to allow agents to resolve issues autonomously.
- Lethal Tri-factor: A security concept regarding the risks of agents having access to local environments, internet access, and sensitive data.
1. Engineering Lessons for Agent Interfaces
Michael Hablich, Product Manager for Chrome DevTools, emphasizes that agents are a distinct user segment with unique cognitive bottlenecks. Unlike humans, who rely on visual complexity, agents require structured, semantic data.
- Data Handling: The team initially failed by feeding agents raw, multi-megabyte JSON trace files, which exhausted context windows. They shifted to providing semantic summaries in markdown, focusing on key performance metrics (LCP, INP, CLS) to guide the agent to the relevant "sentence" rather than the whole "book."
- Efficiency Metric: The team uses Tokens per Successful Outcome to measure efficiency. Hablich warns against global comparisons, noting that token usage varies significantly by task complexity (e.g., simple web scraping vs. complex responsive layout debugging).
2. Strategies for Optimization
The Chrome DevTools team addresses "token burn" and agent performance through three primary strategies:
- Tool Categorization: Hiding niche tools (e.g., Chrome extension debugging) behind command-line parameters to keep the default context menu clean.
- Slim Mode: A restricted mode exposing only essential tools (select, navigate, evaluate) to minimize context window usage, though this involves a trade-off where agents may require more "turns" to complete complex tasks.
- CLI Integration: Allowing agents to chain commands (e.g.,
grepfor an accessibility ID, then pipe it into aclickcommand) to perform post-processing locally, bypassing the need to send large datasets to the model.
3. Error Recovery and Resilience
To prevent agents from getting stuck, the team implemented:
- Actionable Error Messages: Modifying error outputs to include specific instructions that allow the agent to self-heal.
- Proactive Detours: Hard-coding logic to steer agents toward specific tools (e.g., preferring a performance trace tool over a Lighthouse audit) to counteract potential model biases.
- Diagnostic Playbooks: Providing "skills" that help agents troubleshoot their own setup issues, increasing the overall resilience of the agent harness.
4. Discoverability and Tool Design
The team moved from a monolithic debug_webpage tool to 25 specialized tools. This created a new challenge: how does the agent know which tool to use?
- The Schema as UI: Citing research that 97% of MCP tool descriptions have "quality smells," Hablich argues that the schema is the agent's user interface.
- Best Practices: Descriptions must clearly define the purpose and activation criteria. For example, explicitly mentioning "Core Web Vitals" in a tool description helps the agent associate that tool with page-load optimization tasks.
5. Security and Trust Boundaries
Hablich stresses that trust should never be compromised for convenience. He categorizes agent environments into three tiers:
- Tier 1 (Local Dev): Human-in-the-loop; requires explicit, time-bound consent for every action.
- Tier 2 (CI/CD): Controlled, isolated environments using containers and separate Chrome profiles.
- Tier 3 (Full Internet Access): "YOLO mode"; requires strict domain allow-lists and prompt-injection mitigations.
He specifically warns against "remembering choices" (auto-connect) in local environments, as it creates a security vulnerability where an agent could act without human oversight.
Synthesis and Conclusion
The transition from human-centric to agent-centric design requires a fundamental shift in how we build interfaces. The main takeaways are:
- Measure what matters: Use "Tokens per Successful Outcome" to track efficiency, but ensure effectiveness is the primary goal.
- Design for autonomy: Build tools that provide clear, actionable error feedback to enable self-healing.
- Optimize for the model: Treat tool descriptions as high-fidelity UI elements.
- Prioritize security: Maintain strict trust boundaries, especially in local development environments, to prevent the "lethal tri-factor" of security risks.
As Hablich concludes, "Agents are our next users. Let's help them help us."
Chat with this Video
AI-PoweredLoad the transcript when you're ready to chat so the initial page stays lighter.
Related Videos

ego lite: I gave Claude Code & Codex a browser to run web automation — here's what happened
AICodeKing

How to build an AI Agent and MCP Server (step-by-step)
Google Cloud Tech

Emulate device capabilities with Chrome DevTools for agents
Chrome for Developers

Beyond Components: Designing Generative UI for MCP Apps — Ruben Casas, Postman
AI Engineer

I Turned Any Website Into a Permanent AI Tool in 10 Minutes 🤯 (FREE BrowserAct Skill Forge)
ManuAGI - AutoGPT Tutorials

Understanding and Using AI Skills
John Savill's Technical Training

WebMCP - Why is awesome & How to use it
AI Jason