← 返回 Skills 市场
icestorms

HTML-to-Selenium

作者 张 庆 ( Zhang Qing ) · GitHub ↗ · v1.0.2 · MIT-0
cross-platform ✓ 安全检测通过
143
总下载
0
收藏
0
当前安装
3
版本数
在 OpenClaw 中安装
/install html-to-selenium
功能描述
General webpage element analysis and Selenium automation control script generation. Use cases: (1) Analyze HTML element structure of any webpage (2) Automati...
使用说明 (SKILL.md)

General Webpage Element Analysis & Selenium Control

Overview

This skill analyzes HTML structure of any webpage, identifies interactive elements, and generates Selenium automation control code.

⚠️ Security Warnings

  1. Dependencies Required: Install selenium package and matching WebDriver before running

    pip install selenium
    

    WebDriver (Edge/Chrome/Firefox) must match your browser version

  2. Sensitive Data Risk:

    • Do not access internal network pages with sensitive information
    • Page HTML may contain tokens, CSRF credentials, etc.
    • Delete temporary files after analysis
  3. Authorized Pages Only:

    • Only analyze pages you have permission to access
    • Do not automate control of devices you don't own

Workflow

Step 1: Download Page Source

python scripts/fetch_page.py \x3CURL> -o \x3Coutput_file> -w \x3Cwait_seconds>

Step 2: LLM Analysis

Send the downloaded HTML to LLM for element identification and analysis.

Step 3: Generate Control Script

Write Selenium automation script based on analysis results.

Output Format

LLM analysis should include:

  • Page overview (title, framework)
  • Element inventory table (recommended locating method)
  • Complete Python code
  • Notes & considerations

通用网页元素分析与Selenium控制

概述

这个Skill用于分析任意网页的HTML结构,识别可交互元素,并生成Selenium自动化控制代码。

⚠️ 安全警告

  1. 依赖要求:运行前需安装 selenium 包和对应浏览器的 WebDriver

    pip install selenium
    

    WebDriver(Edge/Chrome/Firefox)需与浏览器版本匹配

  2. 敏感数据风险

    • 不要访问包含敏感信息的内部网络页面
    • 页面HTML可能包含token、CSRF凭证等敏感数据
    • 分析完成后建议删除临时文件
  3. 仅用于授权页面

    • 仅分析你有权限访问的页面
    • 不要自动化控制你不拥有的设备

工作流程

步骤1: 下载网页源码

python scripts/fetch_page.py \x3CURL> -o \x3C输出文件> -w \x3C等待秒数>

步骤2: 大模型分析

将下载的HTML源码发送给大模型进行元素识别和分析。

步骤3: 生成控制脚本

根据分析结果编写Selenium自动化脚本。

输出格式要求

大模型分析后应输出:

  • 页面概述(标题、框架)
  • 元素清单表格(推荐定位方式)
  • 完整Python代码
  • 注意事项
安全使用建议
This skill appears coherent with its purpose, but take these precautions before using it: - Only run it on pages you are authorized to access. The script will load arbitrary URLs from your environment and can access internal/network-only resources if run locally. - Install and use the correct browser WebDriver (the script uses Edge by default) and the selenium Python package. The skill does not install those for you. - Be cautious about sending downloaded HTML to external LLMs: page source can include tokens, CSRF values, or personally identifiable data. Remove or redact sensitive fields before transmission. - The script saves HTML to the current directory and by default deletes it; verify the cleanup behavior (use --keep if you want to retain files). Inspect any saved files before sharing them. - If you need broader browser support, consider updating the script to detect/choose the available WebDriver or use a webdriver-manager rather than assuming Edge. If you follow the above precautions, the skill's behavior is consistent with its stated function.
能力评估
Purpose & Capability
Name/description ('HTML-to-Selenium') align with the included script and SKILL.md: the bundle downloads page HTML, enumerates interactive elements, and instructs generating Selenium control code. There are no unrelated environment variables or surprising binaries requested.
Instruction Scope
SKILL.md explicitly directs downloading pages and then sending the HTML to an LLM for analysis — this matches the skill's goal but is also the main privacy/safety concern because page HTML can contain tokens/CSRF data. The SKILL.md contains warnings about only using authorized pages and deleting temporary files, which is appropriate; however sending raw HTML to an external LLM could leak sensitive data and is left as a user responsibility.
Install Mechanism
No install spec and only a small Python script are included (instruction-only style). No remote downloads or archives are executed, so there is low install-time risk.
Credentials
The skill requires no environment variables or credentials. It does require the user to have the selenium package and a matching WebDriver available locally (the script uses Edge WebDriver). Those requirements are proportional to the stated functionality.
Persistence & Privilege
always is false and the skill does not request permanent presence or modify other skills/config. It writes temporary files to the working directory (and deletes them by default); that's expected for its operation.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install html-to-selenium
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /html-to-selenium 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.2
- Added full English documentation and description alongside existing Chinese content for broader accessibility. - Clarified workflow and output format sections for both languages. - Updated security warnings and dependency instructions to ensure correct usage. - No code or functional changes; documentation only.
v1.0.1
Version 1.0.1 - 增加安全与合规声明,强调仅限分析公开或有授权的网页 - 新增依赖安装和WebDriver版本要求说明 - 强调页面敏感信息风险和临时文件删除建议 - 简化和精炼“工作流程”与“输出格式要求”部分 - 移除部分操作细节,突出大模型分析和自动化脚本生成功能
v1.0.0
Initial release of universal HTML analysis and Selenium script generation skill. - Analyze any webpage's HTML structure and identify interactive elements. - Auto-detect form controls (inputs, buttons, selects) for automation. - Provides prompts and workflow for detailed large-model-driven page analysis. - Generates Python Selenium scripts covering login, search, form submission, and dynamic content handling. - Includes fetch_page.py utility for reliable HTML downloading with custom wait times.
元数据
Slug html-to-selenium
版本 1.0.2
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 3
常见问题

HTML-to-Selenium 是什么?

General webpage element analysis and Selenium automation control script generation. Use cases: (1) Analyze HTML element structure of any webpage (2) Automati... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 143 次。

如何安装 HTML-to-Selenium?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install html-to-selenium」即可一键安装,无需额外配置。

HTML-to-Selenium 是免费的吗?

是的,HTML-to-Selenium 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

HTML-to-Selenium 支持哪些平台?

HTML-to-Selenium 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 HTML-to-Selenium?

由 张 庆 ( Zhang Qing )(@icestorms)开发并维护,当前版本 v1.0.2。

💬 留言讨论