
Lean Reader
io.github.AIMento由 GitHub 帳號 AIMento 發布v0.1.0更新於 Oct 24, 2026
Token-minimized URL-to-clean-text reader for LLMs, with a token-savings receipt.
概覽
一個本機 MCP 伺服器,抓取 URL 並回傳經 token 精簡的乾淨正文,同時附上節省 token 與估算費用的回執。
- 可以做什麼
- 抓取 URL 並把頁面轉換成適合 LLM 的乾淨精簡文字,可透過 lean_read 工具指定 markdown 等格式。回傳回執,包含處理前後 token 數、節省百分比、壓縮倍數與估算節省費用。計數以 o200k_base 分詞器為準,並與原始頁面 HTML 相比。
- 適用情境
- 適合助理需要閱讀網頁文章或文件頁面,並希望降低 token 用量而不是直接貼上原始 HTML 的情境。對靜態、伺服器端渲染的頁面效果最好;用戶端渲染的單頁應用可能只回傳很少內容。
- 執行需求
- 透過 stdio 在本機執行,通常以 npx 從 lean-reader npm 套件啟動,因此需要 Node.js 以及連線目標 URL 的網路存取。未宣告帳號、API 金鑰、環境變數或請求標頭。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Lean Reader,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Lean Reader
Turn any URL into token-minimized clean text for LLMs, with a token-savings receipt on every call. MCP server + library.
LLMs don't need your nav bar, your cookie banner, your <script> tags, or 200 KB of inlined SVG — but raw page HTML makes them pay for all of it. Lean Reader strips a page down to the article and tells you exactly how many tokens (and dollars) you just saved.
Use as an MCP server
Add to your client's MCP config (Claude Desktop/Code, Cursor, …):
Then the lean_read(url, format?) tool returns clean text plus the receipt.
Use as a library
How much does it save?
Measured, not marketed — the open benchmark ships the corpus, the tokenizer, and every raw output, and flags the cases where Lean Reader loses:
- ~29% fewer tokens than Mozilla Readability (the standard extractor) at the median, while keeping ~99% of the body text. Be honest about where that edge comes from: it's the
minimizepost-pass (link/image/footnote/whitespace strip), not smarter extraction — run both throughminimizeand they're roughly par. Lean actually runs Readability as one of its two extractors (see Honest limits), so it doesn't lose to it. - Versus raw page HTML the multiple is much larger (median ~8.7×, down to ~3.1× on already-clean blog prose, 100×+ on script-heavy docs) — but that's HTML nobody feeds an LLM, so read it as "don't dump raw pages," not as a competitive claim.
- Versus Jina Reader (measured, anonymous tier): ~1.6× fewer tokens on a like-for-like body, ~4.3× if you count the nav and reference dumps Jina also returns. Firecrawl is not yet measured (needs an API key).
The receipt uses the o200k_base tokenizer (GPT-4o/4.1 class); the model and tokenizer are always shown, and counts are vs the raw page HTML so you can check the math.
Honest limits
- Static HTML only (v1). Pages whose body is client-rendered (some SPAs, GitHub repo landing pages) return little — Lean Reader flags
partialinstead of emitting empty text. Jina/Firecrawl render JS and will beat us there. - Two extractors, body-max selection. Defuddle and Mozilla Readability each silently drop the body on different pages (Defuddle on some large Wikipedia articles, Readability on some docs/SPAs). Lean runs both and keeps whichever recovers more body, so neither's blind spot becomes a silent content drop. A ROUGE-L ground-truth pass on a 14-page hand-labeled sample is done: reference-body recall 0.99, equal to Readability on the same ground truth, so the word-count gap is noise removal, not body loss (see the bench repo).
- Token counts are
o200k_base; Claude/Gemini tokenize differently.
Open-core
The extraction + token-minimization core (lib/) and the MCP server (src/) are MIT. Hosted service, sharing UI, and metering are separate.
MIT © 2026
來源:README.md,提交 9e3aa7c
工具
0版本歷史
1- v0.1.0最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分