article-extractor

Extract clean article content from URLs (blog posts, articles, tutorials) and save as readable text. Use when user wants to download, extract, or save an article/blog post from a URL without ads, navigation, or clutter.

By michalparkola · 572 installs

npx skills add michalparkola/tapestry-skills --skill article-extractor

Source repository · Upstream listing

Article Extractor This skill extracts the main content from web articles and blog posts, removing navigation, ads, newsletter signups, and other clutter. Saves clean, readable text. When to Use This Skill Activate when the user: Provides an article/blog URL and wants the text content Asks to "download this article" Wants to "extract the content from [URL]" Asks to "save this blog post as text" Needs clean article text without distractions How It Works Priority Order: 1. Check if tools are installed (reader or trafilatura) 2. Download and extract article using best available tool 3. Clean up the content (remove extra whitespace, format properly) 4. Save to file with article title as filename 5. Confirm location and show preview Installation Check Check for article extraction tools in this order: Option 1: reader (Recommended Mozilla's Readability) If not installed: Option 2: trafilatura (Python based, very good) If not installed: Option 3: Fallback (curl + simple parsing) If no tools available, use basic curl + text extraction (less reliable but works) Extraction Methods Method 1: Using reader (Best for most articles) Pros: Based on Mozilla's Readability algorithm Excellent at removing clutter Preserves article structure Method 2: Using trafilatura (Best for blogs/news) Pros: Very accurate extraction Good with various site structures Handles multiple languages Options: no comments : Skip comment sections no tables : Skip data tables precision : Favor precision over recall recall : Extract more content (may include some noise) Method 3: Fallback (curl + basic parsing) Note: This is less reliable but works without dependencies. Getting Article Title Extract title for filename: Using reader: Using trafilatura: Using curl (fallback): Filename Creation Clean title for filesystem: Complete Workflow Error Handling Common Issues 1. Tool not installed Try alternate tool (reader → trafilatura → fallback) Offer to install: "Install reader with: npm install g reader cli" 2. Paywall or login required Extraction tools may fail Inform user: "This article requires authentication. Cannot extract." 3. Invalid URL Check URL format Try with and without redirects 4. No content extracted Site may use heavy JavaScript Try fallback method Inform user if extraction fails 5. Special characters in title Clean title for filesystem Remove: / , : , ? , " , < , , Replace with or remove Output Format Saved File Contains: Article title (if available) Author (if available from tool) Main article text Section headings No navigation, ads, or clutter What Gets Removed: Navigation menus Ads and promotional content Newsletter signup forms Related articles sidebars Comment sections (optional) Social media buttons Cookie notices Tips for Best Results 1. Use reader for most articles Best all around tool Based on Firefox Reader View Works on most news sites and blogs 2. Use trafilatura for: Academic articles News sites Blogs with complex layouts Non English content 3. Fallback method limitations: May include some noise Less accurate paragraph detection Better than nothing for simple sites 4. Check extraction quality: Always show preview to user Ask if it looks correct Offer to try different tool if needed Example Usage Simple extraction: With error handling: Best Practices ✅ Always show preview after extraction (first 10 lines) ✅ Verify extraction succeeded before saving ✅ Clean filename for filesystem compatibility ✅ Try fallback method if primary fails ✅ Inform user which tool was used ✅ Keep filename length reasonable (< 100 chars) After Extraction Display to user: 1. "✓ Extracted: [Article Title]" 2. "✓ Saved to: [filename]" 3. Show preview (first 10 15 lines) 4. File size and location Ask if needed: "Would you like me to also create a Ship Learn Next plan from this?" (if using ship learn next skill) "Should I extract another article?"