MCP Apps
MCP Apps是基于MCP(Model Context Protocol)协议的一种扩展机制,允许AI工具在响应中返回交互式用户界面(UI)组件,而非仅输出纯文本。其核心特征在于将AI能力与可交互的前端界面结合,使用户能够在对话流程中直接操作界面元素,从而提升人机交互的灵活性与功能丰富度。
Timeline (last 90 days)
MCP's extension mechanisms include Tasks (supporting long-running tasks) and Apps (allowing interactive UI to be displayed directly in the conversation).
All Facts (8)
MCP Apps使用沙盒化的iframe来渲染第三方UI代码,通过HTML5的sandbox属性限制嵌入内容的权限
95%UnverifiedMCP Apps设计了四层安全防护机制:iframe沙盒隔离、预渲染审查、可审计的消息通道、用户授权确认
90%UnverifiedMCP Apps的UI端SDK为@anthropic/mcp-ext,核心方法包括onToolResult、callServerTool和updateModelContext
90%UnverifiedMCP Apps的MIME类型最终定为text/html; profile=mcp-app,采用RFC 6906的Profile参数机制
90%UnverifiedMCP Apps将Human-in-the-Loop从线性检查点模式升级为持续循环模式,用户的每次UI交互都成为Agent决策的输入信号
85%Unverified开发者通过在MCP工具定义中添加meta.ui.resourceUri字段指向HTML地址,即可将普通工具变为MCP App
60%UnverifiedMCP Apps的UI和宿主通过PostMessage和JSON-RPC进行双向通信
60%UnverifiedMCP Apps allows AI tools to return interactive user interfaces rather than only plain text or JSON.
60%