agentleFS
tboome33tboome33/obsidian-mcp-router/skills/defuddle/SKILL.md

defuddle

Skill1 starsChanged 7 months agoApache-2.0View on GitHub

Strip noise (ads, navigation, cookie banners, related-post widgets, comment threads, footers) from a webpage and return clean readable markdown — typically saving 40-60% of tokens vs. fetching the raw page. Use as a preprocessor for wiki-ingest or autoresearch when the source is a webpage with heavy chrome. Triggered by "defuddle <url>", "clean this page", "fetch and clean <url>", "/defuddle", "strip the noise from <url>", or implicitly inside autoresearch when fetching commercial/blog pages.

66 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use results-report, knap and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • Galaxy-DawnSkill

    results-report

    This skill should be used when the user asks to "write an experiment report", "summarize experimental results", "do experiment retrospection", "write a results report", "写实验总结报告", "写实验复盘", or mentions turning completed experiment artifacts into a structured, decision-oriented research report. It assumes strict analysis should come from `results-analysis` first.

    Also in 3 projects that use this

  • lucasmaher-hashSkill

    knap

    Render Markdown from templates and structured data using Knap CLI. Use when the user asks to apply a Knap template, turn JSON or CSV data into notes, batch-generate Markdown files, or format Defuddle output into a note.

    Also in 4 projects that use this

  • Clay-HHKSkill

    daily-coding

    Daily coding assistant that auto-triggers when writing/modifying code, providing a core checklist.

    Also in 3 projects that use this

  • Clay-HHKSkill

    kaggle-learner

    This skill should be used when the user asks to "learn from Kaggle", "study Kaggle solutions", "analyze Kaggle competitions", or mentions Kaggle competition URLs. Provides access to extracted knowledge from winning Kaggle solutions across NLP, CV, time series, tabular, and multimodal domains.

    Also in 3 projects that use this

  • kharlamenkodevSkill

    bug-detective

    Also in 3 projects that use this

  • az9713Skill

    vault-health

    Audit vault health: unresolved links, orphan notes, dead-end files, missing frontmatter, structural gaps. Produces an actionable report note with prioritized fix suggestions. Use when wanting to clean up, organize, or assess the current state of the vault.

    Also in 3 projects that use this

  • +2 more from Clay-HHK

The file

We split this skill into the rules it gives an agent

11 rules. 0 are common, 2 are distinctive, and 9 are very specific to this project.

  • 0

    Common

    Most of the 60 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 9

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Before wiki-ingest on a URL that's a typical webpage (blog post, news article, documentation site).

    line 12
  2. Very specific:

    Use WebFetch with a prompt like:

    line 26
  3. Very specific:

    After defuddle returns clean markdown, ALSO call mcp__obsidian-router__extract_page_metadata({url}) (or {html} if you already have the raw …

    line 39
  4. Very specific:

    Anti-pattern: do NOT infer title / author / published when the meta extractor has returned non-null values for those fields.

    line 48
  5. Very specific:

    If invoked from wiki-ingest: return {markdown, metadata} so wiki-ingest can assemble deterministic frontmatter (step 4 of that skill) …

    line 54
  6. Very specific:

    If invoked from autoresearch: same.

    line 55
  7. Very specific:

    If invoked directly by the user ("defuddle <url>"): show them the cleaned content + a compact metadata header (title / author / published / …

    line 56
  8. Very specific:

    If the same URL gets defuddled multiple times in a session, cache the result in wiki/.raw/defuddle-cache/<sha256-of-url>.md.

    line 62
  9. Very specific:

    Don't defuddle and then DUMP the cleaned content as a wiki page directly.

    line 66
  10. Distinctive:

    Don't defuddle internal vault content — the router already returns clean markdown.

    line 67
  11. Distinctive:

    Don't defuddle when the user explicitly wants the raw HTML (e.g., "what does the HTML structure of this page look like").

    line 68

“Common” is measured: kept by at least 6 in 10 of the 60 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

defuddle

Cheap content cleaning before ingestion. Worth the extra step on most webpages — almost free in tokens after, much cheaper to ingest, and the wiki page that comes out is more readable.

When to use

  • Before wiki-ingest on a URL that's a typical webpage (blog post, news article, documentation site).
  • Inside autoresearch for any HTML fetch.
  • The user pastes a URL and says "what does this say" — defuddle it then summarize.

When NOT to use

  • The URL is already a clean source (raw markdown, GitHub raw, RSS feed, JSON API).
  • The URL is a PDF or video — defuddle is for HTML.
  • The user wants the raw HTML for some specific reason.

Steps

1. Fetch the page

Use WebFetch with a prompt like:

Return the main article content as clean markdown. Drop navigation, ads, cookie banners, related posts, comment sections, social media widgets, footer boilerplate, and "subscribe to our newsletter" callouts. Preserve: the article title, author, publication date if visible, headings, body paragraphs, code blocks, lists, blockquotes, inline links to relevant resources (drop tracking-only links), images that are part of the content (note their captions if any).

WebFetch's underlying small model is good at this kind of selective extraction. Trust its output.

2. Validate the output

Quick sanity checks:

  • Length: if the cleaned output is < 200 chars or > 50K chars, something probably went sideways. Surface to the user with the URL and offer to retry or fall back to raw fetch.
  • Title presence: a defuddled article should start with an H1 (the title) or a clear opening paragraph. If it starts mid-sentence, defuddle was too aggressive — flag and offer raw.

2.5 Extract deterministic metadata (v0.13.2+, Phase B obsidian-clipper port)

After defuddle returns clean markdown, ALSO call mcp__obsidian-router__extract_page_metadata({url}) (or {html} if you already have the raw HTML cached) to pull structured metadata that the LLM should NOT have to infer:

  • title, author, published, image (cover), site (publisher), lang, description
  • wordCount, readingMinutes (derived)

This populates the source-page frontmatter deterministically downstream (see wiki-ingest step 4). The extractor parses Schema.org JSON-LD + OpenGraph + meta tags in priority order; values that come back as null mean none of those signals were present, and the consumer falls back to inferring from the body — but only as last resort.

Why two calls (defuddle + extract_page_metadata) instead of one combined tool: clean separation of concerns. defuddle strips chrome and returns prose; extract_page_metadata parses structured signals from the same URL. Each is independently useful, and a future client could call only one.

Anti-pattern: do NOT infer title / author / published when the meta extractor has returned non-null values for those fields. The whole point of the extractor is to make these deterministic — re-inferring undoes that.

3. Hand off to the consumer

Defuddle is rarely a terminal action. The output is the input to the next skill. Return an object {markdown, metadata} (the markdown from step 1, the metadata from step 2.5) so the consumer doesn't have to re-fetch:

  • If invoked from wiki-ingest: return {markdown, metadata} so wiki-ingest can assemble deterministic frontmatter (step 4 of that skill) before Claude touches the body.
  • If invoked from autoresearch: same.
  • If invoked directly by the user ("defuddle <url>"): show them the cleaned content + a compact metadata header (title / author / published / wordCount), ask "ingest this?" — if yes, hand off to wiki-ingest.

Optional relevance filter (v0.47.0+, Crawl4AI W-A): if the consumer has an explicit topic for this page (a targeted ingest, an autoresearch question), it can narrow the cleaned markdown to the on-topic blocks with mcp__obsidian-router__filter_relevant_blocks({markdown, query: <topic>}) — a cheap BM25 second pass, no re-fetch. Defuddle strips chrome; this strips off-topic content. Leave it to the consumer (wiki-ingest step 1.6 already does this); don't filter inside defuddle, which has no notion of the caller's topic.

Caching (optional, not required for v1)

If the same URL gets defuddled multiple times in a session, cache the result in wiki/.raw/defuddle-cache/<sha256-of-url>.md. Skip if already cached and < 1 hour old. Keeps autoresearch loops cheap when they revisit the same domains.

Anti-patterns

  • Don't defuddle and then DUMP the cleaned content as a wiki page directly. The wiki should hold the synthesis, not the raw cleaned source. Use wiki-ingest after defuddle to get proper synthesis.
  • Don't defuddle internal vault content — the router already returns clean markdown.
  • Don't defuddle when the user explicitly wants the raw HTML (e.g., "what does the HTML structure of this page look like").

Output format (when invoked directly)

✅ Defuddled <url> — kept ~<N>%, dropped chrome.

# <title>

<body>

Ingest this into the wiki? (wiki-ingest <url> or "yes")

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.