markdown-new 技能在原始网络和 AI 原生工作流之间架起了一座坚实的桥梁。通过与 markdown.new 服务集成,此 Openclaw Skills 扩展使开发人员能够将复杂的、重度依赖 JavaScript 的网页转换为结构化的 Markdown 文本。这一过程对于降低大语言模型提示词中的 token 成本,以及通过去除不必要的 HTML 噪音和样板内容来提高检索增强生成 (RAG) 系统的准确性至关重要。
该技能专为速度和灵活性而构建,可处理从简单的博客文章到复杂的单页应用程序的所有内容。它提供对渲染方法的细粒度控制,允许开发人员在标准转换、AI 增强提取或完整的无头浏览器渲染之间进行选择。这确保了生成的数据始终保持高质量,并可立即用于 Openclaw Skills 自动化流水线。
下载入口:https://github.com/openclaw/skills/tree/main/skills/joelchance/markdown-convert从源直接安装技能的最快方式。
npx clawhub@latest install markdown-convert
将技能文件夹复制到以下位置之一
全局模式~/.openclaw/skills/
工作区
<project>/skills/
优先级:工作区 > 本地 > 内置
将此提示词复制到 OpenClaw 即可自动安装。
请帮我使用 Clawhub 安装 markdown-convert。如果尚未安装 Clawhub,请先安装(npm i -g clawhub)。
要开始使用此 Openclaw Skills 扩展,请确保已安装 Python 3,并导航到技能目录以执行抓取程序。
# 导航到技能根目录以确保正确的路径解析
cd ~/.codex/skills/markdown-new
# 测试基本抓取以验证安装和连接性
python3 scripts/markdown_new_fetch.py 'https://example.com'
该技能将其输出组织成干净的 Markdown 文件,并捕获响应元数据,以协助规划下游 AI 任务。
| 属性 | 描述 |
|---|---|
| x-markdown-tokens | 提供所用 token 的估计值,帮助管理 AI 上下文窗口。 |
| x-rate-limit-remaining | 跟踪每日 API 使用情况(500 次请求/天),以防止工作流中断。 |
| method | 指示转换使用的是 auto、ai 还是 browser 渲染。 |
| --deliver-md | 将内容包裹在自定义 XML 风格的标签中,以便编码代理进行结构化解析。 |
name: markdown-new
description: "Convert public web pages into clean Markdown with markdown.new for AI workflows. Use when tasks require URL-to-Markdown conversion for summarization, RAG ingestion, extraction, archiving, or token reduction, including selecting conversion method (auto/ai/browser), enabling image retention, and handling rate limits or conversion failures."
Use this skill to convert public URLs into LLM-ready Markdown via markdown.new.
scripts/... and references/... from the skill directory, not workspace root.python3 ~/.codex/skills/markdown-new/scripts/markdown_new_fetch.py 'https://example.com'
cd ~/.codex/skills/markdown-new
python3 scripts/markdown_new_fetch.py 'https://example.com'
Avoid this pattern from an arbitrary workspace root:
python3 scripts/markdown_new_fetch.py 'https://example.com'
http or https.scripts/markdown_new_fetch.py with --method auto first.--method browser if output misses JS-rendered content.--retain-images only when image links are required.x-markdown-tokens, x-rate-limit-remaining, and JSON metadata when present) for downstream planning.Commands below assume current directory is the skill root (~/.codex/skills/markdown-new).
python3 scripts/markdown_new_fetch.py 'https://example.com' > page.md
python3 scripts/markdown_new_fetch.py 'https://example.com' --method browser --retain-images --output page.md
python3 scripts/markdown_new_fetch.py 'https://example.com' --deliver-md
auto: default. Let markdown.new use its fastest successful pipeline.ai: force Workers AI HTML-to-Markdown conversion.browser: force headless browser rendering for JS-heavy pages.Use auto first, then retry with browser only when needed.
--deliver-md to force file output in .md format.<url>...markdown...</url>--output is omitted, the script auto-generates a filename from the URL.https://markdown.new/https://example.com?method=browser&retain_images=truePOST https://markdown.new/{"url":"https://example.com","method":"auto","retain_images":false}Prefer POST mode for automation and explicit parameters.
429 as rate limiting (documented limit: 500 requests/day/IP).robots.txt, terms of service, and copyright constraints.references/markdown-new-api.md