Skip to main content
Glama
qqkkrr

universal-scraper

by qqkkrr

extract

Converts raw HTML into clean Markdown, article text, or tables for token-efficient reading; sanitizes hidden elements and comments first, optionally narrowing to main content.

Instructions

把 HTML 源码转成干净 Markdown/正文/表格,用于省 token 地阅读网页内容。默认先净化(剥离隐藏元素/注释/零宽字符等提示注入载体)再转换;main_only=true 时额外收窄到主内容容器(更适合阅读文章页)。

Input Schema

NameRequiredDescriptionDefault
rawNo跳过净化(默认 false;仅在确需原始 HTML 时用)
htmlYesHTML 源码
modeNomarkdown(默认)/ article / table
base_urlNo用于把相对链接转绝对(可选)
main_onlyNo只取主内容容器(默认 false;正文页建议 true)
max_charsNo输出上限字符(默认 50000,防爆 token)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.2.0

TDQS

A3.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the burden and does well: it discloses that sanitization runs by default stripping hidden elements, comments, and zero-width characters (prompt-injection vectors), and that main_only narrows to the main content container. It does not cover behavior on malformed HTML or that the operation is a side-effect-free pure transform.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two dense sentences with the transformation stated first and defaults/options after; minimal waste. Slightly clause-heavy but every clause carries information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a one-required-parameter transform with no output schema and no annotations, it covers purpose, defaults, sanitization behavior, and output kinds. Missing only return-shape specifics and failure behavior, which are minor here.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so all six parameters are already documented. The description mainly reinforces the sanitization/raw interaction and main_only intent that the schema already states, adding only marginal nuance beyond the structured fields.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a concrete transformation: converting HTML source into clean Markdown/body text/tables, with the goal of token-efficient reading. The input being raw HTML rather than a URL implicitly distinguishes it from scrape/crawl siblings, though no sibling is named explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives conditional guidance (main_only=true is better for article pages; raw only when truly needed) but never states when to pick this tool over scrape, crawl, or auto. Usage is implied by the input type rather than spelled out.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools