# midscene - Doramagic AI Context Pack

> 定位：安装前体验与判断资产。它帮助宿主 AI 有一个好的开始，但不代表已经安装、执行或验证目标项目。

## 充分原则

- **充分原则，不是压缩原则**：AI Context Pack 应该充分到让宿主 AI 在开工前理解项目价值、能力边界、使用入口、风险和证据来源；它可以分层组织，但不以最短摘要为目标。
- **压缩策略**：只压缩噪声和重复内容，不压缩会影响判断和开工质量的上下文。

## 给宿主 AI 的使用方式

你正在读取 Doramagic 为 midscene 编译的 AI Context Pack。请把它当作开工前上下文：帮助用户理解适合谁、能做什么、如何开始、哪些必须安装后验证、风险在哪里。不要声称你已经安装、运行或执行了目标项目。

## Claim 消费规则

- **事实来源**：Repo Evidence + Claim/Evidence Graph；Human Wiki 只提供显著性、术语和叙事结构。
- **事实最低状态**：`supported`
- `supported`：可以作为项目事实使用，但回答中必须引用 claim_id 和证据路径。
- `weak`：只能作为低置信度线索，必须要求用户继续核实。
- `inferred`：只能用于风险提示或待确认问题，不能包装成项目事实。
- `unverified`：不得作为事实使用，应明确说证据不足。
- `contradicted`：必须展示冲突来源，不得替用户强行选择一个版本。

## 它最适合谁

- **正在使用 Claude/Codex/Cursor/Gemini 等宿主 AI 的开发者**：README 或插件配置提到多个宿主 AI。 证据：`README.md` Claim：`clm_0002` supported 0.86

## 它能做什么

- **命令行启动或安装流程**（需要安装后验证）：项目文档中存在可执行命令，真实使用需要在本地或宿主环境中运行这些命令。 证据：`CONTRIBUTING.md`, `apps/site/docs/en/consume-report-file.md`, `apps/site/docs/en/faq.md`, `scripts/publish-chrome-extension.sh` Claim：`clm_0001` supported 0.86

## 怎么开始

- `npx @midscene/web report-tool --action split --htmlPath ./midscene_run/report/puppeteer-2026/index.html --outputDir ./output-data` 证据：`apps/site/docs/en/consume-report-file.md` Claim：`clm_0003` supported 0.86
- `npx @midscene/web report-tool --action to-markdown --htmlPath ./midscene_run/report/puppeteer-2026/index.html --outputDir ./output-markdown` 证据：`apps/site/docs/en/consume-report-file.md` Claim：`clm_0004` supported 0.86
- `npx @midscene/web report-tool --action merge-html \` 证据：`apps/site/docs/en/consume-report-file.md` Claim：`clm_0005` supported 0.86
- `npm install @midscene/web@latest` 证据：`apps/site/docs/en/faq.md` Claim：`clm_0006` supported 0.86
- `npm install @midscene/ios@latest` 证据：`apps/site/docs/en/faq.md` Claim：`clm_0007` supported 0.86
- `npm install @midscene/cli@latest` 证据：`apps/site/docs/en/faq.md` Claim：`clm_0008` supported 0.86
- `npx nx build @midscene/web` 证据：`CONTRIBUTING.md` Claim：`clm_0009` supported 0.86
- `npx nx test @midscene/web` 证据：`CONTRIBUTING.md` Claim：`clm_0010` supported 0.86
- `npx nx test:ai @midscene/web` 证据：`CONTRIBUTING.md` Claim：`clm_0011` supported 0.86
- `npx nx e2e @midscene/web` 证据：`CONTRIBUTING.md` Claim：`clm_0012` supported 0.86

## 继续前判断卡

- **当前建议**：先做角色匹配试用
- **为什么**：这个项目更像角色库，核心风险是选错角色或把角色文案当执行能力；先用 Prompt Preview 试角色匹配，再决定是否沙盒导入。

### 30 秒判断

- **现在怎么做**：先做角色匹配试用
- **最小安全下一步**：先用 Prompt Preview 试角色匹配；满意后再隔离导入
- **先别相信**：角色质量和任务匹配不能直接相信。
- **继续会触碰**：角色选择偏差、命令执行、宿主 AI 配置

### 现在可以相信

- **适合人群线索：正在使用 Claude/Codex/Cursor/Gemini 等宿主 AI 的开发者**（supported）：有 supported claim 或项目证据支撑，但仍不等于真实安装效果。 证据：`README.md` Claim：`clm_0002` supported 0.86
- **能力存在：命令行启动或安装流程**（supported）：可以相信项目包含这类能力线索；是否适合你的具体任务仍要试用或安装后验证。 证据：`CONTRIBUTING.md`, `apps/site/docs/en/consume-report-file.md`, `apps/site/docs/en/faq.md`, `scripts/publish-chrome-extension.sh` Claim：`clm_0001` supported 0.86
- **存在 Quick Start / 安装命令线索**（supported）：可以相信项目文档出现过启动或安装入口；不要因此直接在主力环境运行。 证据：`apps/site/docs/en/consume-report-file.md` Claim：`clm_0003` supported 0.86

### 现在还不能相信

- **角色质量和任务匹配不能直接相信。**（unverified）：角色库证明有很多角色，不证明每个角色都适合你的具体任务，也不证明角色能产生高质量结果。
- **不能把角色文案当成真实执行能力。**（unverified）：安装前只能判断角色描述和任务画像是否匹配，不能证明它能在宿主 AI 里完成任务。
- **真实输出质量不能在安装前相信。**（unverified）：Prompt Preview 只能展示引导方式，不能证明真实项目中的结果质量。
- **宿主 AI 版本兼容性不能在安装前相信。**（unverified）：Claude、Cursor、Codex、Gemini 等宿主加载规则和版本差异必须在真实环境验证。
- **不会污染现有宿主 AI 行为，不能直接相信。**（inferred）：Skill、plugin、AGENTS/CLAUDE/GEMINI 指令可能改变宿主 AI 的默认行为。 证据：`AGENTS.md`
- **可安全回滚不能默认相信。**（unverified）：除非项目明确提供卸载和恢复说明，否则必须先在隔离环境验证。
- **真实安装后是否与用户当前宿主 AI 版本兼容？**（unverified）：兼容性只能通过实际宿主环境验证。
- **项目输出质量是否满足用户具体任务？**（unverified）：安装前预览只能展示流程和边界，不能替代真实评测。

### 继续会触碰什么

- **角色选择偏差**：用户对任务应该由哪个专家角色处理的判断。 原因：选错角色会让 AI 从错误专业视角回答，浪费时间或误导决策。
- **命令执行**：包管理器、网络下载、本地插件目录、项目配置或用户主目录。 原因：运行第一条命令就可能产生环境改动；必须先判断是否值得跑。 证据：`CONTRIBUTING.md`, `apps/site/docs/en/consume-report-file.md`, `apps/site/docs/en/faq.md`, `scripts/publish-chrome-extension.sh`
- **宿主 AI 配置**：Claude/Codex/Cursor/Gemini/OpenCode 等宿主的 plugin、Skill 或规则加载配置。 原因：宿主配置会改变 AI 后续工作方式，可能和用户已有规则冲突。 证据：`AGENTS.md`
- **本地环境或项目文件**：安装结果、插件缓存、项目配置或本地依赖目录。 原因：安装前无法证明写入范围和回滚方式，需要隔离验证。 证据：`CONTRIBUTING.md`, `apps/site/docs/en/consume-report-file.md`, `apps/site/docs/en/faq.md`, `scripts/publish-chrome-extension.sh`
- **宿主 AI 上下文**：AI Context Pack、Prompt Preview、Skill 路由、风险规则和项目事实。 原因：导入上下文会影响宿主 AI 后续判断，必须避免把未验证项包装成事实。

### 最小安全下一步

- **先跑 Prompt Preview**：先用交互式试用验证任务画像和角色匹配，不要先导入整套角色库。（适用：任何项目都适用，尤其是输出质量未知时。）
- **只在隔离目录或测试账号试装**：避免安装命令污染主力宿主 AI、真实项目或用户主目录。（适用：存在命令执行、插件配置或本地写入线索时。）
- **先备份宿主 AI 配置**：Skill、plugin、规则文件可能改变 Claude/Cursor/Codex 的默认行为。（适用：存在插件 manifest、Skill 或宿主规则入口时。）
- **安装后只验证一个最小任务**：先验证加载、兼容、输出质量和回滚，再决定是否深用。（适用：准备从试用进入真实工作流时。）

### 退出方式

- **保留安装前状态**：记录原始宿主配置和项目状态，后续才能判断是否可恢复。
- **准备移除宿主 plugin / Skill / 规则入口**：如果试装后行为异常，可以把宿主 AI 恢复到试装前状态。
- **保留原始角色选择记录**：如果输出偏题，可以回到任务画像阶段重新选择角色，而不是继续沿着错误角色推进。
- **记录安装命令和写入路径**：没有明确卸载说明时，至少要知道哪些目录或配置需要手动清理。
- **如果没有回滚路径，不进入主力环境**：不可回滚是继续前阻断项，不应靠信任或运气继续。

## 哪些只能预览

- 解释项目适合谁和能做什么
- 基于项目文档演示典型对话流程
- 帮助用户判断是否值得安装或继续研究

## 哪些必须安装后验证

- 真实安装 Skill、插件或 CLI
- 执行脚本、修改本地文件或访问外部服务
- 验证真实输出质量、性能和兼容性

## 边界与风险判断卡

- **把安装前预览误认为真实运行**：用户可能高估项目已经完成的配置、权限和兼容性验证。 处理方式：明确区分 prompt_preview_can_do 与 runtime_required。 Claim：`clm_0014` inferred 0.45
- **命令执行会修改本地环境**：安装命令可能写入用户主目录、宿主插件目录或项目配置。 处理方式：先在隔离环境或测试账号中运行。 证据：`CONTRIBUTING.md`, `apps/site/docs/en/consume-report-file.md`, `apps/site/docs/en/faq.md`, `scripts/publish-chrome-extension.sh` Claim：`clm_0015` supported 0.86
- **待确认**：真实安装后是否与用户当前宿主 AI 版本兼容？。原因：兼容性只能通过实际宿主环境验证。
- **待确认**：项目输出质量是否满足用户具体任务？。原因：安装前预览只能展示流程和边界，不能替代真实评测。
- **待确认**：安装命令是否需要网络、权限或全局写入？。原因：这影响企业环境和个人环境的安装风险。

## 开工前工作上下文

### 加载顺序

- 先读取 how_to_use.host_ai_instruction，建立安装前判断资产的边界。
- 读取 claim_graph_summary，确认事实来自 Claim/Evidence Graph，而不是 Human Wiki 叙事。
- 再读取 intended_users、capabilities 和 quick_start_candidates，判断用户是否匹配。
- 需要执行具体任务时，优先查 role_skill_index，再查 evidence_index。
- 遇到真实安装、文件修改、网络访问、性能或兼容性问题时，转入 risk_card 和 boundaries.runtime_required。

### 任务路由

- **命令行启动或安装流程**：先说明这是安装后验证能力，再给出安装前检查清单。 边界：必须真实安装或运行后验证。 证据：`CONTRIBUTING.md`, `apps/site/docs/en/consume-report-file.md`, `apps/site/docs/en/faq.md`, `scripts/publish-chrome-extension.sh` Claim：`clm_0001` supported 0.86

### 上下文规模

- 文件总数：1682
- 重要文件覆盖：40/1682
- 证据索引条目：80
- 角色 / Skill 条目：35

### 证据不足时的处理

- **missing_evidence**：说明证据不足，要求用户提供目标文件、README 段落或安装后验证记录；不要补全事实。
- **out_of_scope_request**：说明该任务超出当前 AI Context Pack 证据范围，并建议用户先查看 Human Manual 或真实安装后验证。
- **runtime_request**：给出安装前检查清单和命令来源，但不要替用户执行命令或声称已执行。
- **source_conflict**：同时展示冲突来源，标记为待核实，不要强行选择一个版本。

## Prompt Recipes

### 适配判断

- 目标：判断这个项目是否适合用户当前任务。
- 预期输出：适配结论、关键理由、证据引用、安装前可预览内容、必须安装后验证内容、下一步建议。

```text
请基于 midscene 的 AI Context Pack，先问我 3 个必要问题，然后判断它是否适合我的任务。回答必须包含：适合谁、能做什么、不能做什么、是否值得安装、证据来自哪里。所有项目事实必须引用 evidence_refs、source_paths 或 claim_id。
```

### 安装前体验

- 目标：让用户在安装前感受核心工作流，同时避免把预览包装成真实能力或营销承诺。
- 预期输出：一段带边界标签的体验剧本、安装后验证清单和谨慎建议；不含真实运行承诺或强营销表述。

```text
请把 midscene 当作安装前体验资产，而不是已安装工具或真实运行环境。

请严格输出四段：
1. 先问我 3 个必要问题。
2. 给出一段“体验剧本”：用 [安装前可预览]、[必须安装后验证]、[证据不足] 三种标签展示它可能如何引导工作流。
3. 给出安装后验证清单：列出哪些能力只有真实安装、真实宿主加载、真实项目运行后才能确认。
4. 给出谨慎建议：只能说“值得继续研究/试装”“先补充信息后再判断”或“不建议继续”，不得替项目背书。

硬性边界：
- 不要声称已经安装、运行、执行测试、修改文件或产生真实结果。
- 不要写“自动适配”“确保通过”“完美适配”“强烈建议安装”等承诺性表达。
- 如果描述安装后的工作方式，必须使用“如果安装成功且宿主正确加载 Skill，它可能会……”这种条件句。
- 体验剧本只能写成“示例台词/假设流程”：使用“可能会询问/可能会建议/可能会展示”，不要写“已写入、已生成、已通过、正在运行、正在生成”。
- Prompt Preview 不负责给安装命令；如用户准备试装，只能提示先阅读 Quick Start 和 Risk Card，并在隔离环境验证。
- 所有项目事实必须来自 supported claim、evidence_refs 或 source_paths；inferred/unverified 只能作风险或待确认项。

```

### 角色 / Skill 选择

- 目标：从项目里的角色或 Skill 中挑选最匹配的资产。
- 预期输出：候选角色或 Skill 列表，每项包含适用场景、证据路径、风险边界和是否需要安装后验证。

```text
请读取 role_skill_index，根据我的目标任务推荐 3-5 个最相关的角色或 Skill。每个推荐都要说明适用场景、可能输出、风险边界和 evidence_refs。
```

### 风险预检

- 目标：安装或引入前识别环境、权限、规则冲突和质量风险。
- 预期输出：环境、权限、依赖、许可、宿主冲突、质量风险和未知项的检查清单。

```text
请基于 risk_card、boundaries 和 quick_start_candidates，给我一份安装前风险预检清单。不要替我执行命令，只说明我应该检查什么、为什么检查、失败会有什么影响。
```

### 宿主 AI 开工指令

- 目标：把项目上下文转成一次对话开始前的宿主 AI 指令。
- 预期输出：一段边界明确、证据引用明确、适合复制给宿主 AI 的开工前指令。

```text
请基于 midscene 的 AI Context Pack，生成一段我可以粘贴给宿主 AI 的开工前指令。这段指令必须遵守 not_runtime=true，不能声称项目已经安装、运行或产生真实结果。
```

## 角色 / Skill 索引

- 共索引 35 个角色 / Skill / 项目文档条目。

- **📣 Midscene Skills is here!**（project_doc）：Official Website : https://midscenejs.com/ 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`README.md`
- **Midscene Android Playground**（project_doc）：Playground tool for Android cli @midscene/android. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/android-playground/README.md`
- **Midscene Chrome Extension**（project_doc）： 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/chrome-extension/README.md`
- **Midscene Playground**（project_doc）：Playground is the fastest way to try Midscene without writing code. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/playground/README.md`
- **Midscene MCP**（project_doc）：docs: https://midscenejs.com/mcp.html 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/android-mcp/README.md`
- **@midscene/android-playground**（project_doc）： 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/android-playground/README.md`
- **@midscene/android**（project_doc）：Android automation library for Midscene, providing AI-powered testing and automation capabilities for Android devices. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/android/README.md`
- **@midscene/cli**（project_doc）：CLI tool for running Midscene automation scripts in YAML format. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/cli/README.md`
- **@midscene/computer-playground**（project_doc）：Midscene Computer Playground - PC desktop automation playground for Windows, macOS, and Linux. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/computer-playground/README.md`
- **@midscene/computer**（project_doc）：Midscene.js Computer Desktop Automation - AI-powered desktop automation for: 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/computer/README.md`
- **Documentation**（project_doc）：Automate browser actions, extract data, and perform assertions using AI. It offers JavaScript SDK, Chrome extension, and support for scripting in YAML. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/core/README.md`
- **@midscene/ios-mcp**（project_doc）：docs: https://midscenejs.com/mcp.html 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/ios-mcp/README.md`
- **@midscene/ios**（project_doc）：iOS automation library for Midscene, providing AI-powered testing and automation capabilities for iOS simulators and devices. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/ios/README.md`
- **Midscene MCP**（project_doc）：docs: https://midscenejs.com/mcp.html 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/mcp/README.md`
- **@midscene/playground-app**（project_doc）：Reusable React shell for Midscene playground applications. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/playground-app/README.md`
- **@midscene/recorder**（project_doc）： 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/recorder/README.md`
- **Documentation**（project_doc）：An AI-powered automation SDK can control the page, perform assertions, and extract data in JSON format using natural language. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/shared/README.md`
- **Documentation**（project_doc）：An AI-powered automation SDK can control the page, perform assertions, and extract data in JSON format using natural language. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/visualizer/README.md`
- **Midscene MCP**（project_doc）：docs: https://midscenejs.com/mcp.html 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/web-bridge-mcp/README.md`
- **@midscene/web**（project_doc）：Automate UI actions, extract data, and perform assertions using AI for web browsers. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`packages/web-integration/README.md`
- **AGENTS.md**（project_doc）：Canonical instructions for coding agents in this repository. CLAUDE.md should point here instead of duplicating rules. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`AGENTS.md`
- **Agents**（project_doc）：This is the documentation for the Midscene an SDK for AI automation 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/agents.md`
- **Midscene Contribution Guide**（project_doc）：Thanks for showing interest in contributing to Midscene. Before starting your contribution, please take a moment to read the following guidelines. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`CONTRIBUTING.md`
- **Awesome Midscene**（project_doc）：A curated list of community projects that extend Midscene.js capabilities across different platforms and programming languages. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/en/awesome-midscene.md`
- **Introducing Instant Actions and Deep Think**（project_doc）：Introducing Instant Actions and Deep Think 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/en/blog-introducing-instant-actions-and-deep-think.md`
- **Consume Report Files**（project_doc）：Midscene HTML report files capture the full execution history of a single Agent, making them useful for replay and debugging. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/en/consume-report-file.md`
- **Data privacy**（project_doc）：⁠Midscene.js is an open-source project GitHub: Midscene https://github.com/web-infra-dev/midscene/ under the MIT license. You can see all the codes in the public repository. 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/en/data-privacy.md`
- **FAQ**（project_doc）：The following platform-specific FAQs are maintained in their respective documentation: 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/en/faq.md`
- **Use JavaScript to optimize the AI automation code**（project_doc）：Use JavaScript to optimize the AI automation code 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/en/use-javascript-to-optimize-ai-automation-code.md`
- **Awesome Midscene**（project_doc）：基于 Midscene.js 开发的社区项目精选列表，涵盖不同平台和编程语言的扩展功能。 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/zh/awesome-midscene.md`
- **即时操作和深度思考**（project_doc）：从 Midscene v0.14.0 开始，我们引入了两个新功能：即时操作（Instant Actions）和深度思考（Deep Think）。 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/zh/blog-introducing-instant-actions-and-deep-think.md`
- **解析报告文件**（project_doc）：Midscene 的 HTML 报告文件记录了单个 Agent 运行过程中的完整信息，用以回放和调试。 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/zh/consume-report-file.md`
- **数据隐私**（project_doc）：Midscene.js 是一个开源项目（GitHub: Midscene https://github.com/web-infra-dev/midscene/ ，遵循 MIT 许可证。你可以在公开仓库中查看到所有代码。 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/zh/data-privacy.md`
- **常见问题 FAQ**（project_doc）：- Web 浏览器 - Playwright ./integrate-with-playwright faq - Web 浏览器 - Puppeteer ./integrate-with-puppeteer faq - Web 浏览器 - Chrome 插件 ./quick-experience faq - Web 浏览器 - 桥接模式 ./bridge-mode faq - Android ./android-getting-started 常见问题 - iOS ./ios-getting-started 常见问题 - HarmonyOS ./harmony-getting-started 常见问题 - PC 桌面 ./computer-getting-started 常见问题 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/zh/faq.md`
- **使用 JavaScript 优化 AI 自动化代码**（project_doc）：许多开发者喜欢使用 aiAct 或 ai 来执行自动化任务，甚至将所有长段落复杂逻辑描述在一个自然语言指令中。这是很"智能"的做法，但在实际使用中可能遇到无法稳定复现、速度偏慢的问题。 激活提示：当用户需要理解项目结构、安装方式或边界时参考。 证据：`apps/site/docs/zh/use-javascript-to-optimize-ai-automation-code.md`

## 证据索引

- 共索引 80 条证据。

- **📣 Midscene Skills is here!**（documentation）：Official Website : https://midscenejs.com/ 证据：`README.md`
- **Midscene Android Playground**（documentation）：Playground tool for Android cli @midscene/android. 证据：`apps/android-playground/README.md`
- **Midscene Chrome Extension**（documentation）：Midscene Chrome Extension See . 证据：`apps/chrome-extension/README.md`
- **Midscene Playground**（documentation）：Playground is the fastest way to try Midscene without writing code. 证据：`apps/playground/README.md`
- **Midscene MCP**（documentation）：docs: https://midscenejs.com/mcp.html 证据：`packages/android-mcp/README.md`
- **@midscene/android-playground**（documentation）：@midscene/android-playground See . 证据：`packages/android-playground/README.md`
- **@midscene/android**（documentation）：Android automation library for Midscene, providing AI-powered testing and automation capabilities for Android devices. 证据：`packages/android/README.md`
- **@midscene/cli**（documentation）：CLI tool for running Midscene automation scripts in YAML format. 证据：`packages/cli/README.md`
- **@midscene/computer-playground**（documentation）：Midscene Computer Playground - PC desktop automation playground for Windows, macOS, and Linux. 证据：`packages/computer-playground/README.md`
- **@midscene/computer**（documentation）：Midscene.js Computer Desktop Automation - AI-powered desktop automation for: 证据：`packages/computer/README.md`
- **Documentation**（documentation）：Automate browser actions, extract data, and perform assertions using AI. It offers JavaScript SDK, Chrome extension, and support for scripting in YAML. 证据：`packages/core/README.md`
- **@midscene/ios-mcp**（documentation）：docs: https://midscenejs.com/mcp.html 证据：`packages/ios-mcp/README.md`
- **@midscene/ios**（documentation）：iOS automation library for Midscene, providing AI-powered testing and automation capabilities for iOS simulators and devices. 证据：`packages/ios/README.md`
- **Midscene MCP**（documentation）：docs: https://midscenejs.com/mcp.html 证据：`packages/mcp/README.md`
- **@midscene/playground-app**（documentation）：Reusable React shell for Midscene playground applications. 证据：`packages/playground-app/README.md`
- **@midscene/recorder**（documentation）：@midscene/recorder See . 证据：`packages/recorder/README.md`
- **Documentation**（documentation）：An AI-powered automation SDK can control the page, perform assertions, and extract data in JSON format using natural language. 证据：`packages/shared/README.md`
- **Documentation**（documentation）：An AI-powered automation SDK can control the page, perform assertions, and extract data in JSON format using natural language. 证据：`packages/visualizer/README.md`
- **Midscene MCP**（documentation）：docs: https://midscenejs.com/mcp.html 证据：`packages/web-bridge-mcp/README.md`
- **@midscene/web**（documentation）：Automate UI actions, extract data, and perform assertions using AI for web browsers. 证据：`packages/web-integration/README.md`
- **Package**（package_manifest）：{ "name": "midscene", "private": true, "version": "1.9.7", "scripts": { "dev": "node scripts/dev-prepare.js && nx run-many --target=build:watch --exclude=android-playground,chrome-extension,@midscene/report,doc --verbose --parallel=6", "build": "nx run-many --target=build --exclude=doc --verbose", "build:packages": "pnpm -r --filter './packages/ ' --if-present run build", "build:skip-cache": "npm run clean && nx run-many --target=build --exclude=doc --verbose --skip-nx-cache", "type-check:tests": "node scripts/type-check-tests.mjs", "test": "nx run-many --target=test --verbose", "test:coverage": "nx run-many --target=test --verbose -- --coverage", "test:ai": "nx run-many --target=test:ai --… 证据：`package.json`
- **Package**（package_manifest）：{ "name": "android-playground", "private": true, "version": "1.0.0", "type": "module", "scripts": { "build": "rsbuild build", "dev": "rsbuild dev --open", "preview": "rsbuild preview" }, "dependencies": { "@midscene/playground-app": "workspace: ", "@midscene/shared": "workspace: ", "react": "18.3.1", "react-dom": "18.3.1" }, "devDependencies": { "@rsbuild/core": "^1.6.15", "@rsbuild/plugin-less": "^1.5.0", "@rsbuild/plugin-node-polyfill": "1.4.2", "@rsbuild/plugin-react": "^1.4.1", "@rsbuild/plugin-svgr": "^1.2.2", "@types/react": "^18.3.1", "@types/react-dom": "^18.3.1", "less": "^4.2.0", "typescript": "^5.8.3" } } 证据：`apps/android-playground/package.json`
- **Package**（package_manifest）：{ "name": "chrome-extension", "private": true, "version": "1.0.0", "type": "module", "scripts": { "build": "rsbuild build && npm run pack-extension", "dev": "rimraf dist && concurrently -k -n build,run \"rsbuild dev\" \"node scripts/wait-for-build.js && web-ext run --config web-ext-config.cjs --source-dir dist --target chromium\"", "dev:simple": "rsbuild dev --open", "preview": "rsbuild preview", "pack-extension": "node scripts/pack-extension.js", "test": "vitest run" }, "dependencies": { "@ant-design/icons": "^5.3.1", "@midscene/core": "workspace: ", "@midscene/playground": "workspace: ", "@midscene/recorder": "workspace: ", "@midscene/report": "workspace: ", "@midscene/shared": "workspace… 证据：`apps/chrome-extension/package.json`
- **Package**（package_manifest）：{ "name": "computer-playground", "private": true, "version": "1.0.0", "type": "module", "scripts": { "build": "rsbuild build", "dev": "rsbuild dev --open", "preview": "rsbuild preview" }, "dependencies": { "@midscene/playground-app": "workspace: ", "@midscene/shared": "workspace: ", "react": "18.3.1", "react-dom": "18.3.1" }, "devDependencies": { "@rsbuild/core": "^1.6.15", "@rsbuild/plugin-less": "^1.5.0", "@rsbuild/plugin-node-polyfill": "1.4.2", "@rsbuild/plugin-react": "^1.4.1", "@rsbuild/plugin-svgr": "^1.2.2", "@types/react": "^18.3.1", "@types/react-dom": "^18.3.1", "less": "^4.2.0", "typescript": "^5.8.3" } } 证据：`apps/computer-playground/package.json`
- **Package**（package_manifest）：{ "name": "playground", "private": true, "version": "1.0.0", "type": "module", "scripts": { "build": "rsbuild build", "dev": "rsbuild dev --open", "preview": "rsbuild preview", "demo:server": "tsx demo/server.ts", "demo": "concurrently \"npm run demo:server\" \"npm run dev\"" }, "dependencies": { "@midscene/playground-app": "workspace: ", "@midscene/playground": "workspace: ", "@midscene/shared": "workspace: ", "react": "18.3.1", "react-dom": "18.3.1" }, "devDependencies": { "@midscene/web": "workspace: ", "@rsbuild/core": "^1.6.15", "@rsbuild/plugin-less": "^1.5.0", "@rsbuild/plugin-node-polyfill": "1.4.2", "@rsbuild/plugin-react": "^1.4.1", "@rsbuild/plugin-svgr": "^1.2.2", "@types/react"… 证据：`apps/playground/package.json`
- **Package**（package_manifest）：{ "name": "recorder-form", "version": "1.0.0", "private": true, "type": "module", "scripts": { "build": "rsbuild build", "dev": "rsbuild dev --open", "preview": "rsbuild preview" }, "dependencies": { "@midscene/recorder": "workspace: ", "antd": "^5.21.6", "dayjs": "^1.11.11", "react": "18.3.1", "react-dom": "18.3.1" }, "devDependencies": { "@midscene/shared": "workspace: ", "@rsbuild/core": "^1.6.15", "@rsbuild/plugin-node-polyfill": "1.4.2", "@rsbuild/plugin-react": "^1.4.1", "@types/react": "^18.3.1", "@types/react-dom": "^18.3.1", "rsbuild-plugin-workspace-dev": "0.0.1", "typescript": "^5.8.3" } } 证据：`apps/recorder-form/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/report", "version": "1.0.0", "private": true, "scripts": { "dev": "rsbuild dev", "build": "rsbuild build", "dev:rsdoctor": "RSDOCTOR=true rsbuild dev", "build:rsdoctor": "RSDOCTOR=true rsbuild build", "preview": "rsbuild preview", "test": "vitest --run", "test:watch": "vitest", "generate-demo": "node scripts/generate-demo-report.mjs", "e2e": "node scripts/generate-demo-report.mjs && node ../../packages/cli/bin/midscene ./e2e/" }, "dependencies": { "@ant-design/icons": "^5.3.1", "@midscene/core": "workspace: ", "@midscene/playground": "workspace: ", "@midscene/shared": "workspace: ", "@midscene/visualizer": "workspace: ", "@midscene/web": "workspace: ", "@rsbuild/core":… 证据：`apps/report/package.json`
- **Package**（package_manifest）：{ "name": "doc", "version": "1.0.0", "private": true, "type": "module", "scripts": { "dev": "rspress dev", "build": "rspress build && ./config deploy.sh", "preview": "rspress preview" }, "engines": { "pnpm": " =9.3.0", "node": " =18.19.0" }, "packageManager": "pnpm@9.3.0", "dependencies": { "lucide-react": "0.553.0", "querystring": "0.2.1", "react": "18.3.1", "react-dom": "18.3.1" }, "devDependencies": { "@rspress/core": "2.0.8", "@rspress/plugin-client-redirects": "2.0.8", "@rspress/plugin-llms": "2.0.8", "@rspress/plugin-sitemap": "2.0.8", "@tailwindcss/postcss": "4.1.11", "@types/node": "^18.0.0", "autoprefixer": "10.4.22", "postcss": "8.5.6", "tailwindcss": "4.1.11" } } 证据：`apps/site/package.json`
- **Package**（package_manifest）：{ "name": "studio", "private": true, "version": "0.1.0", "type": "module", "scripts": { "build": "rsbuild build && node scripts/sync-static-assets.mjs", "dev": "pnpm run dev:deps && concurrently -k -n deps,build,app \"nx run-many --target=dev --projects=@midscene/visualizer,@midscene/playground-app,@midscene/android-playground,@midscene/computer,@midscene/computer-playground,@midscene/playground,@midscene/web,@midscene/recorder --parallel --exclude-task-dependencies\" \"rsbuild dev\" \"node scripts/wait-for-electron-build.mjs && node scripts/launch-electron-dev.mjs\"", "dev:deps": "nx run @midscene/visualizer:build --outputStyle=stream && nx run-many --target=build --projects=@midscene/play… 证据：`apps/studio/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/android-mcp", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/android-mcp" }, "description": "Midscene MCP Server for Android automation", "bin": "dist/index.js", "files": "dist" , "scripts": { "build": "rslib build", "dev": "npm run build:watch", "build:watch": "rslib build --watch --no-clean", "mcp-playground": "npx @modelcontextprotocol/inspector node ./dist/index.js", "test": "vitest run", "inspect": "node scripts/inspect.mjs" }, "devDependencies": { "@midscene/android": "workspace: ", "@midscene/core": "workspace: ", "@midscene/report": "workspace: ", "@midscene/shared": "workspace: "… 证据：`packages/android-mcp/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/android-playground", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/android-playground" }, "description": "Android playground for Midscene", "main": "./dist/lib/index.js", "types": "./dist/types/index.d.ts", "module": "./dist/es/index.mjs", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./package.json": "./package.json" }, "files": "dist", "static", "bin", "README.md" , "bin": { "midscene-android-playground": "./bin/android-playground", "@midscene/android-playground": "./bin/android-playground" }, "scripts": {… 证据：`packages/android-playground/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/android", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/android" }, "description": "Android automation library for Midscene", "keywords": "Android UI automation", "Android AI testing", "Android automation library", "Android automation tool", "Android use" , "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "types": "./dist/types/index.d.ts", "bin": { "midscene-android": "./bin/midscene-android" }, "files": "bin", "dist", "README.md" , "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./mcp-server":… 证据：`packages/android/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/cli", "description": "An AI-powered automation SDK can control the page, perform assertions, and extract data in JSON format using natural language. See https://midscenejs.com/ for details.", "version": "1.9.7", "repository": "https://github.com/web-infra-dev/midscene", "homepage": "https://midscenejs.com/", "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "bin": { "midscene": "./bin/midscene" }, "files": "dist", "README.md", "bin" , "scripts": { "dev": "npm run build:watch", "build": "rslib build", "build:watch": "rslib build --watch --no-clean", "test": "vitest --run", "test:ai": "AITEST=true vitest --run", "test:ai:temp": "AITEST=true BRIDGE MODE=true… 证据：`packages/cli/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/computer-linux", "version": "1.9.7", "description": "Midscene.js Computer Desktop Automation for Linux", "license": "MIT", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/computer-linux" }, "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "types": "./dist/types/index.d.ts", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./package.json": "./package.json" }, "scripts": { "build": "rslib build", "dev": "rslib build --watch" }, "nx": { "targets": { "build": { "dependsOn": { "projects": "@midscene/computer", "target": "bu… 证据：`packages/computer-linux/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/computer-mac", "version": "1.9.7", "description": "Midscene.js Computer Desktop Automation for macOS", "license": "MIT", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/computer-mac" }, "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "types": "./dist/types/index.d.ts", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./package.json": "./package.json" }, "scripts": { "build": "rslib build", "dev": "rslib build --watch" }, "nx": { "targets": { "build": { "dependsOn": { "projects": "@midscene/computer", "target": "build"… 证据：`packages/computer-mac/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/computer-mcp", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/computer-mcp" }, "description": "Midscene MCP Server for Computer desktop automation", "bin": "dist/index.js", "files": "dist" , "scripts": { "build": "rslib build", "dev": "npm run build:watch", "build:watch": "rslib build --watch --no-clean", "mcp-playground": "npx @modelcontextprotocol/inspector node ./dist/index.js", "test": "vitest run" }, "devDependencies": { "@midscene/computer": "workspace: ", "@midscene/core": "workspace: ", "@midscene/report": "workspace: ", "@midscene/shared": "workspace: ", "@modelcontextprotocol/in… 证据：`packages/computer-mcp/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/computer-playground", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/computer-playground" }, "description": "Computer playground for Midscene - PC desktop automation", "main": "./dist/lib/index.js", "types": "./dist/types/index.d.ts", "module": "./dist/es/index.mjs", "files": "dist", "static", "bin", "README.md" , "bin": { "midscene-computer-playground": "./bin/computer-playground", "@midscene/computer-playground": "./bin/computer-playground" }, "scripts": { "dev": "npm run build:watch", "dev:server": "npm run build && ./bin/computer-playground", "test": "vitest --run", "build": "rslib bu… 证据：`packages/computer-playground/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/computer-win", "version": "1.9.7", "description": "Midscene.js Computer Desktop Automation for Windows", "license": "MIT", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/computer-win" }, "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "types": "./dist/types/index.d.ts", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./package.json": "./package.json" }, "scripts": { "build": "rslib build", "dev": "rslib build --watch" }, "nx": { "targets": { "build": { "dependsOn": { "projects": "@midscene/computer", "target": "buil… 证据：`packages/computer-win/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/computer", "version": "1.9.7", "description": "Midscene.js Computer Desktop Automation", "license": "MIT", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/computer" }, "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "types": "./dist/types/index.d.ts", "bin": { "midscene-computer": "./bin/midscene-computer" }, "files": "bin", "dist", "native", "scripts", "README.md" , "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./mcp-server": { "types": "./dist/types/mcp-server.d.ts", "import": "./dist/es/mcp-server.mjs", "require… 证据：`packages/computer/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/core", "description": "Automate browser actions, extract data, and perform assertions using AI. It offers JavaScript SDK, Chrome extension, and support for scripting in YAML. See https://midscenejs.com/ for details.", "version": "1.9.7", "repository": "https://github.com/web-infra-dev/midscene", "homepage": "https://midscenejs.com/", "main": "./dist/lib/index.js", "types": "./dist/types/index.d.ts", "module": "./dist/es/index.mjs", "files": "dist", "README.md" , "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./utils": { "types": "./dist/types/utils.d.ts", "import": "./dist/es/utils.mjs", "req… 证据：`packages/core/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/harmony-mcp", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/harmony-mcp" }, "description": "Midscene MCP Server for HarmonyOS automation", "bin": "dist/index.js", "files": "dist" , "scripts": { "build": "rslib build", "dev": "npm run build:watch", "build:watch": "rslib build --watch --no-clean", "mcp-playground": "npx @modelcontextprotocol/inspector node ./dist/index.js" }, "dependencies": { "@silvia-odwyer/photon": "0.3.3", "@silvia-odwyer/photon-node": "0.3.3", "sharp": "^0.34.3" }, "devDependencies": { "@midscene/harmony": "workspace: ", "@midscene/core": "workspace: ", "@midscene/rep… 证据：`packages/harmony-mcp/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/harmony-playground", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/harmony-playground" }, "description": "HarmonyOS playground for Midscene", "main": "./dist/lib/index.js", "types": "./dist/types/index.d.ts", "module": "./dist/es/index.mjs", "files": "dist", "bin", "README.md" , "bin": { "midscene-harmony-playground": "./bin/harmony-playground", "@midscene/harmony-playground": "./bin/harmony-playground" }, "scripts": { "dev": "npm run build:watch", "dev:server": "npm run build && ./bin/harmony-playground", "build": "rslib build", "build:watch": "rslib build --watch --no-clean" }, "depend… 证据：`packages/harmony-playground/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/harmony", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/harmony" }, "description": "HarmonyOS automation library for Midscene", "keywords": "HarmonyOS UI automation", "HarmonyOS AI testing", "HarmonyOS automation library", "HarmonyOS automation tool", "HarmonyOS NEXT" , "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "types": "./dist/types/index.d.ts", "bin": { "midscene-harmony": "./bin/midscene-harmony" }, "files": "bin", "dist", "static" , "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./mcp… 证据：`packages/harmony/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/ios-mcp", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/ios-mcp" }, "description": "Midscene MCP Server for iOS automation", "bin": "dist/index.js", "files": "dist" , "scripts": { "build": "rslib build", "dev": "npm run build:watch", "build:watch": "rslib build --watch --no-clean", "mcp-playground": "npx @modelcontextprotocol/inspector node ./dist/index.js", "test": "vitest run", "inspect": "node scripts/inspect.mjs" }, "devDependencies": { "@midscene/core": "workspace: ", "@midscene/ios": "workspace: ", "@midscene/report": "workspace: ", "@midscene/shared": "workspace: ", "@modelcontext… 证据：`packages/ios-mcp/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/ios-playground", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/ios-playground" }, "description": "iOS playground for Midscene", "main": "./dist/lib/index.js", "types": "./dist/types/index.d.ts", "module": "./dist/es/index.mjs", "files": "dist", "bin", "README.md" , "bin": { "midscene-ios-playground": "./bin/ios-playground", "@midscene/ios-playground": "./bin/ios-playground" }, "scripts": { "dev": "npm run build:watch", "dev:server": "npm run build && ./bin/ios-playground", "build": "rslib build", "build:watch": "rslib build --watch --no-clean" }, "dependencies": { "@midscene/ios": "works… 证据：`packages/ios-playground/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/ios", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/ios" }, "description": "iOS automation library for Midscene", "keywords": "iOS UI automation", "iOS AI testing", "iOS automation library", "iOS automation tool", "iOS testing", "simulator automation" , "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "types": "./dist/types/index.d.ts", "files": "dist", "static", "bin", "README.md" , "bin": { "midscene-ios": "./bin/midscene-ios" }, "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./src/bin": { "ty… 证据：`packages/ios/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/mcp", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/mcp" }, "description": "Deprecated - Use @midscene/web-bridge-mcp, @midscene/android-mcp, or @midscene/ios-mcp", "bin": "dist/index.js", "files": "dist" , "scripts": { "build": "rslib build", "dev": "npm run build:watch", "build:watch": "rslib build --watch --no-clean", "mcp-playground": "npx @modelcontextprotocol/inspector node ./dist/index.js", "inspect": "node scripts/inspect.mjs" }, "dependencies": {}, "devDependencies": { "@midscene/android": "workspace: ", "@midscene/core": "workspace: ", "@midscene/report": "workspace: ", "@midsc… 证据：`packages/mcp/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/playground-app", "version": "1.9.7", "description": "Reusable React shell for Midscene playground applications", "repository": "https://github.com/web-infra-dev/midscene", "homepage": "https://midscenejs.com/", "types": "./dist/types/index.d.ts", "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" } }, "files": "dist", "README.md" , "scripts": { "dev": "npm run build:watch", "build": "rslib build", "build:watch": "rslib build --watch --no-clean", "test": "vitest --run", "test:watch": "vitest" }, "peerDependencies": { "react": "^18.0.0", "… 证据：`packages/playground-app/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/playground", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/playground" }, "description": "Midscene playground utilities for web integration", "author": "midscene team", "license": "MIT", "main": "./dist/lib/index.js", "types": "./dist/types/index.d.ts", "module": "./dist/es/index.mjs", "browser": "./dist/es/index.browser.mjs", "exports": { ".": { "types": "./dist/types/index.d.ts", "browser": "./dist/es/index.browser.mjs", "require": "./dist/lib/index.js", "import": "./dist/es/index.mjs", "default": "./dist/es/index.mjs" } }, "files": "dist", "static" , "scripts": { "build": "rslib build… 证据：`packages/playground/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/recorder", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/recorder" }, "type": "module", "exports": { ".": { "types": "./dist/types/src/index.d.ts", "import": "./dist/index.js" } }, "types": "./dist/types/src/index.d.ts", "files": "dist" , "scripts": { "build": "rslib build", "dev": "npm run build:watch", "build:watch": "rslib build --watch --no-clean" }, "devDependencies": { "@rsbuild/plugin-react": "^1.4.1", "@rslib/core": "^0.18.3", "@types/react": "^18.3.1", "react": "18.3.1", "typescript": "^5.8.3" }, "dependencies": { "@ant-design/icons": "^5.3.1", "antd": "^5.21.6", "dayjs": "^1.11… 证据：`packages/recorder/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/shared", "version": "1.9.7", "repository": "https://github.com/web-infra-dev/midscene", "homepage": "https://midscenejs.com/", "types": "./dist/types/index.d.ts", "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./constants": { "types": "./dist/types/constants/index.d.ts", "import": "./dist/es/constants/index.mjs", "require": "./dist/lib/constants/index.js" }, "./extractor": { "types": "./dist/types/extractor/index.d.ts", "import": "./dist/es/extractor/index.mjs", "require": "./dist/lib/extractor/index.js" }, "./img": { "types": ".… 证据：`packages/shared/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/visualizer", "version": "1.9.7", "repository": "https://github.com/web-infra-dev/midscene", "homepage": "https://midscenejs.com/", "types": "./dist/types/index.d.ts", "main": "./dist/lib/index.js", "module": "./dist/es/index.mjs", "exports": { ".": { "types": "./dist/types/index.d.ts", "import": "./dist/es/index.mjs", "require": "./dist/lib/index.js" }, "./history-selector": { "types": "./dist/types/component/history-selector/index.d.ts", "import": "./dist/es/component/history-selector/index.mjs", "require": "./dist/lib/component/history-selector/index.js" } }, "typesVersions": { " ": { ".": "./dist/types/index.d.ts" , "history-selector": "./dist/types/component/history… 证据：`packages/visualizer/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/web-bridge-mcp", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/web-bridge-mcp" }, "description": "Midscene MCP Server for Web automation Bridge mode ", "bin": "dist/index.js", "files": "dist" , "scripts": { "build": "rslib build", "dev": "npm run build:watch", "build:watch": "rslib build --watch --no-clean", "mcp-playground": "npx @modelcontextprotocol/inspector node ./dist/index.js", "test": "vitest run", "inspect": "node scripts/inspect.mjs" }, "devDependencies": { "@midscene/core": "workspace: ", "@midscene/report": "workspace: ", "@midscene/shared": "workspace: ", "@midscene/web": "w… 证据：`packages/web-bridge-mcp/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/web", "description": "Automate browser actions, extract data, and perform assertions using AI. It offers JavaScript SDK, Chrome extension, and support for scripting in YAML. See https://midscenejs.com/ for details.", "keywords": "AI UI automation", "AI testing", "Computer use", "Browser use", "Android use" , "version": "1.9.7", "repository": "https://github.com/web-infra-dev/midscene", "homepage": "https://midscenejs.com/", "main": "./dist/lib/index.js", "types": "./dist/types/index.d.ts", "module": "./dist/es/index.mjs", "exports": { ".": { "types": "./dist/types/index.d.ts", "require": "./dist/lib/index.js", "import": "./dist/es/index.mjs" }, "./bridge-mode": { "types… 证据：`packages/web-integration/package.json`
- **Package**（package_manifest）：{ "name": "@midscene/webdriver", "version": "1.9.7", "repository": { "type": "git", "url": "https://github.com/web-infra-dev/midscene.git", "directory": "packages/webdriver" }, "description": "WebDriver protocol implementation for Midscene automation", "main": "dist/lib/index.js", "module": "dist/es/index.mjs", "types": "dist/types/index.d.ts", "scripts": { "dev": "npm run build:watch", "build": "rslib build", "build:watch": "rslib build --watch --no-clean", "test": "vitest --run", "lint": "biome check .", "lint:fix": "biome check . --write" }, "dependencies": { "@midscene/shared": "workspace: ", "node-fetch": "^3.3.2" }, "devDependencies": { "@rslib/core": "^0.18.3", "@types/node": "^18.0.… 证据：`packages/webdriver/package.json`
- **License**（source_file）：Copyright c 2024-present Bytedance, Inc. and its affiliates. 证据：`packages/cli/LICENSE`
- **License**（source_file）：Copyright c 2024-present Bytedance, Inc. and its affiliates. 证据：`packages/core/LICENSE`
- **AGENTS.md**（documentation）：Canonical instructions for coding agents in this repository. CLAUDE.md should point here instead of duplicating rules. 证据：`AGENTS.md`
- **Agents**（documentation）：This is the documentation for the Midscene an SDK for AI automation 证据：`apps/site/agents.md`
- **Midscene Contribution Guide**（documentation）：Thanks for showing interest in contributing to Midscene. Before starting your contribution, please take a moment to read the following guidelines. 证据：`CONTRIBUTING.md`
- 其余 20 条证据见 `AI_CONTEXT_PACK.json` 或 `EVIDENCE_INDEX.json`。

## 宿主 AI 必须遵守的规则

- **把本资产当作开工前上下文，而不是运行环境。**：AI Context Pack 只包含证据化项目理解，不包含目标项目的可执行状态。 证据：`README.md`, `apps/android-playground/README.md`, `apps/chrome-extension/README.md`
- **回答用户时区分可预览内容与必须安装后才能验证的内容。**：安装前体验的消费者价值来自降低误装和误判，而不是伪装成真实运行。 证据：`README.md`, `apps/android-playground/README.md`, `apps/chrome-extension/README.md`

## 用户开工前应该回答的问题

- 你准备在哪个宿主 AI 或本地环境中使用它？
- 你只是想先体验工作流，还是准备真实安装？
- 你最在意的是安装成本、输出质量、还是和现有规则的冲突？

## 验收标准

- 所有能力声明都能回指到 evidence_refs 中的文件路径。
- AI_CONTEXT_PACK.md 没有把预览包装成真实运行。
- 用户能在 3 分钟内看懂适合谁、能做什么、如何开始和风险边界。

---

## Doramagic Context Augmentation

下面内容用于强化 Repomix/AI Context Pack 主体。Human Manual 只提供阅读骨架；踩坑日志会被转成宿主 AI 必须遵守的工作约束。

## Human Manual 骨架

使用规则：这里只是项目阅读路线和显著性信号，不是事实权威。具体事实仍必须回到 repo evidence / Claim Graph。

宿主 AI 硬性规则：
- 不得把页标题、章节顺序、摘要或 importance 当作项目事实证据。
- 解释 Human Manual 骨架时，必须明确说它只是阅读路线/显著性信号。
- 能力、安装、兼容性、运行状态和风险判断必须引用 repo evidence、source path 或 Claim Graph。

- **项目概览与整体架构**：importance `high`
  - source_paths: README.md, README.zh.md, package.json, pnpm-workspace.yaml, nx.json
- **核心引擎:Agent、多模态模型与 AI 工作流**：importance `high`
  - source_paths: packages/core/src/agent/agent.ts, packages/core/src/agent/tasks.ts, packages/core/src/agent/execution-session.ts, packages/core/src/agent/task-builder.ts, packages/core/src/agent/task-cache.ts
- **平台集成:Web、Mobile、桌面与自定义接口**：importance `high`
  - source_paths: packages/core/src/device/index.ts, packages/core/src/device/device-options.ts, packages/web-integration/src/playwright/index.ts, packages/web-integration/src/puppeteer/index.ts, packages/web-integration/src/bridge-mode/index.ts
- **开发者工具、扩展能力与运维**：importance `medium`
  - source_paths: packages/cli/src/index.ts, packages/cli/src/framework/index.ts, packages/cli/src/yaml-batch-executor.ts, packages/core/src/yaml/player.ts, packages/core/src/yaml/builder.ts

## Repo Inspection Evidence / 源码检查证据

- repo_clone_verified: true
- repo_inspection_verified: true
- repo_commit: `1d39b33c43b77acd694fe229dd67e64c45048d95`
- inspected_files: `README.md`, `package.json`, `pnpm-lock.yaml`, `packages/android/README.md`, `packages/android/demo/playground.ts`, `packages/android/package.json`, `packages/android/rslib.config.ts`, `packages/android/src/adb-shell.ts`, `packages/android/src/agent.ts`, `packages/android/src/appNameMapping.ts`, `packages/android/src/cli.ts`, `packages/android/src/device.ts`, `packages/android/src/index.ts`, `packages/android/src/mcp-server.ts`, `packages/android/src/mcp-tools.ts`, `packages/android/src/scrcpy-device-adapter.ts`, `packages/android/src/scrcpy-manager.ts`, `packages/android/src/utils.ts`, `packages/android/tests/ai/ebay.test.ts`, `packages/android/tests/ai/merge-reports.test.ts`

宿主 AI 硬性规则：
- 没有 repo_clone_verified=true 时，不得声称已经读过源码。
- 没有 repo_inspection_verified=true 时，不得把 README/docs/package 文件判断写成事实。
- 没有 quick_start_verified=true 时，不得声称 Quick Start 已跑通。

## Doramagic Pitfall Constraints / 踩坑约束

这些规则来自 Doramagic 发现、验证或编译过程中的项目专属坑点。宿主 AI 必须把它们当作工作约束，而不是普通说明文字。

### Constraint 1: 来源证据：[Feature]: Let MIDSCENE_MODEL_REASONING_ENABLED disable thinking for self-hosted Qwen models

- Trigger: GitHub 社区证据显示该项目存在一个配置相关的待验证问题：[Feature]: Let MIDSCENE_MODEL_REASONING_ENABLED disable thinking for self-hosted Qwen models
- Why it matters: 可能增加新用户试用和生产接入成本。
- Evidence: community_evidence:github | https://github.com/web-infra-dev/midscene/issues/2063 | 来源类型 github_issue 暴露的待验证使用条件。
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 2: 仓库名和安装名不一致

- Trigger: 仓库名 `midscene` 与安装入口 `@midscene/web` 不完全一致。
- Host AI rule: 在 npm/PyPI/GitHub 上确认包名映射和官方 README 说明。
- Why it matters: 用户照着仓库名搜索包或照着包名找仓库时容易走错入口。
- Evidence: identity.distribution | https://github.com/web-infra-dev/midscene | repo=midscene; install=@midscene/web
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 3: 来源证据：[Bug]: Raw \x1b[1A\x1b[2K ANSI escape sequences polluting logs in non-TTY / Kubernetes Pod environment

- Trigger: GitHub 社区证据显示该项目存在一个安装相关的待验证问题：[Bug]: Raw \x1b[1A\x1b[2K ANSI escape sequences polluting logs in non-TTY / Kubernetes Pod environment
- Why it matters: 可能增加新用户试用和生产接入成本。
- Evidence: community_evidence:github | https://github.com/web-infra-dev/midscene/issues/2689 | 来源讨论提到 node 相关条件，需在安装/试用前复核。
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 4: 来源证据：Bridge 模式下 fileChooserAccept 报错 -32000 Not allowed

- Trigger: GitHub 社区证据显示该项目存在一个配置相关的待验证问题：Bridge 模式下 fileChooserAccept 报错 -32000 Not allowed
- Why it matters: 可能增加新用户试用和生产接入成本。
- Evidence: community_evidence:github | https://github.com/web-infra-dev/midscene/issues/2691 | 来源讨论提到 windows 相关条件，需在安装/试用前复核。
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 5: 能力判断依赖假设

- Trigger: README/documentation is current enough for a first validation pass.
- Host AI rule: 将假设转成下游验证清单。
- Why it matters: 假设不成立时，用户拿不到承诺的能力。
- Evidence: capability.assumptions | https://github.com/web-infra-dev/midscene | README/documentation is current enough for a first validation pass.
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 6: 维护活跃度未知

- Trigger: 未记录 last_activity_observed。
- Host AI rule: 补 GitHub 最近 commit、release、issue/PR 响应信号。
- Why it matters: 新项目、停更项目和活跃项目会被混在一起，推荐信任度下降。
- Evidence: evidence.maintainer_signals | https://github.com/web-infra-dev/midscene | last_activity_observed missing
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

- Trigger: no_demo
- Evidence: downstream_validation.risk_items | https://github.com/web-infra-dev/midscene | no_demo; severity=medium
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 8: 存在评分风险

- Trigger: no_demo
- Why it matters: 风险会影响是否适合普通用户安装。
- Evidence: risks.scoring_risks | https://github.com/web-infra-dev/midscene | no_demo; severity=medium
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 9: issue/PR 响应质量未知

- Trigger: issue_or_pr_quality=unknown。
- Host AI rule: 抽样最近 issue/PR，判断是否长期无人处理。
- Why it matters: 用户无法判断遇到问题后是否有人维护。
- Evidence: evidence.maintainer_signals | https://github.com/web-infra-dev/midscene | issue_or_pr_quality=unknown
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。

### Constraint 10: 发布节奏不明确

- Trigger: release_recency=unknown。
- Host AI rule: 确认最近 release/tag 和 README 安装命令是否一致。
- Why it matters: 安装命令和文档可能落后于代码，用户踩坑概率升高。
- Evidence: evidence.maintainer_signals | https://github.com/web-infra-dev/midscene | release_recency=unknown
- Hard boundary: 不要把这个坑点包装成已解决、已验证或可忽略，除非后续验证证据明确证明它已经关闭。
