Skip to content

Smart Reader

Feed web articles into CodeBuddy without leaving the editor. Extracts clean, readable content and injects it as context for both Ask and Agent modes.

  1. CodeBuddy: Read URL
  2. Paste URL.
  3. Article opens in a webview panel with two actions:
    • Add to Chat — inject as context in your current conversation
    • Summarize Article — AI-generated summary

Or paste a URL into the chat input — CodeBuddy detects it and offers to read the page.

graph TB A[URL] --> B[axios fetch<br/>redirects + 30 s timeout] B --> C[JSDOM parse<br/>virtual DOM from raw HTML] C --> D[Mozilla Readability<br/>strips nav / ads / sidebars / scripts<br/>extracts title, author, excerpt, content] D --> E[DOMPurify<br/>removes XSS vectors, unsafe tags/attrs] E --> F[Clean article]

Same Readability algorithm that powers Firefox’s Reader View. Works well on blog posts, docs, Stack Overflow, READMEs, and article-style pages.

Add to Chat injects the first 5000 chars into the conversation context:

  • Ask mode — text prepended to the system prompt alongside @-mentions.
  • Agent mode — text lives in the agent’s context window; the agent can reference it while reasoning + using tools.
AspectValue
Capacity100 articles
TTL24 hours
EvictionLRU
StorageIn-memory (session-scoped)

Browsing history: last 50 URLs. Access via the webview panel to re-read or re-inject.

CommandEffect
CodeBuddy: Read URLOpen a URL in Smart Reader
CodeBuddy: Add Article to ChatInject current article into the active conversation
CodeBuddy: Summarize ArticleGenerate an AI summary
  • Technical blog posts, tutorials
  • Library / framework documentation
  • Stack Overflow Q&A
  • GitHub README + wiki
  • News + long-form content
  • SPAs requiring JavaScript to render content
  • Pages behind auth walls
  • PDF or non-HTML content
  • Pages with aggressive anti-scraping

For JS-heavy pages, use Browser Automation — it runs a full Chromium that can render client-side content.