chrome-cdp/SKILL.md
# chrome-cdp-skill > 让AI agent访问你已打开的Chrome标签页 ## 简介 chrome-cdp-skill 通过Chrome远程调试协议(CDP)连接你已经在用的Chrome会话,让AI可以: - 读取已登录账户的页面(Gmail、GitHub等) - 与你正在工作的标签页交互 - 查看真实页面状态(非重新加载的干净状态) ## 安装 ### 前提条件 - Chrome浏览器 - Node.js 22+ ### 启用Chrome远程调试 1. 在Chrome地址栏输入:`chrome://inspect/#remote-debugging` 2. 打开"启用远程调试"开关 ### 安装Skill ```bash # 克隆仓库 git clone https://github.com/pasky/chrome-cdp-skill.git cd chrome-cdp-skill # 或复制 skills/chrome-cdp/ 目录到你的agent skills目录 ``` ## 使用方法 ### 基本命令 ```bash # 列出
npx skillsauth add adminlove520/xiaoxi-skills chrome-cdpInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
让AI agent访问你已打开的Chrome标签页
chrome-cdp-skill 通过Chrome远程调试协议(CDP)连接你已经在用的Chrome会话,让AI可以:
chrome://inspect/#remote-debugging# 克隆仓库
git clone https://github.com/pasky/chrome-cdp-skill.git
cd chrome-cdp-skill
# 或复制 skills/chrome-cdp/ 目录到你的agent skills目录
# 列出打开的标签页
node scripts/cdp.mjs list
# 截图
node scripts/cdp.mjs shot <targetId>
# 获取可访问性树
node scripts/cdp.mjs snap <targetId>
# 获取HTML
node scripts/cdp.mjs html <targetId> [".selector"]
# 点击元素
node scripts/cdp.mjs click <targetId> "selector"
# 输入文字
node scripts/cdp.mjs type <targetId> "text"
# 导航
node scripts/cdp.mjs nav <targetId> https://...
# 评估JavaScript
node scripts/cdp.mjs eval <targetId> "expression"
# 网络资源计时
node scripts/cdp.mjs net <targetId>
# 加载更多(点击"加载更多"直到消失)
node scripts/cdp.mjs loadall <targetId> "selector"
首先运行 list 命令获取标签页的targetId:
$ node scripts/cdp.mjs list
TargetID Title URL
--------- ----- ---
abc123def Gmail - Google Account https://mail.google.com/...
def456ghi GitHub https://github.com/...
然后用targetId前缀操作:
node scripts/cdp.mjs snap abc
node scripts/cdp.mjs click abc "#compose"
node scripts/cdp.mjs type abc "Hello World"
在OpenClaw中通过exec调用:
node /path/to/chrome-cdp-skill/scripts/cdp.mjs list
可以将其封装为MCP服务器供OpenClaw调用。
参考 skills/chrome-cdp/index.js 创建完整Skill。
| 特性 | chrome-cdp | Puppeteer类工具 | |------|------------|----------------| | 浏览器 | 已有Chrome | 新启动浏览器 | | 登录状态 | 保持 | 需重新登录 | | 页面状态 | 真实状态 | 干净状态 | | 标签页数量 | 100+不卡 | 容易超时 | | 依赖 | 仅Node.js | Puppeteer+浏览器 |
data-ai
Spaced-repetition flashcard system. Create cards from facts or text, chat with flashcards using free-text answers graded by the agent, generate quizzes from YouTube transcripts, review due cards with adaptive scheduling, and export/import decks as CSV.
development
Canvas LMS integration — fetch enrolled courses and assignments using API token authentication.
development
Provides PyTorch-native distributed LLM pretraining using torchtitan with 4D parallelism (FSDP2, TP, PP, CP). Use when pretraining Llama 3.1, DeepSeek V3, or custom models at scale from 8 to 512+ GPUs with Float8, torch.compile, and distributed checkpointing.
devops
Optimizes LLM inference with NVIDIA TensorRT for maximum throughput and lowest latency. Use for production deployment on NVIDIA GPUs (A100/H100), when you need 10-100x faster inference than PyTorch, or for serving models with quantization (FP8/INT4), in-flight batching, and multi-GPU scaling.