<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Feed Signals — FeedSummary.com</title>
    <link>https://feedsummary.com/blog/</link>
    <description>Implementation guides for AI feed summary formats, pipelines, prompts, documents, scraping, APIs, and agents.</description>
    <language>en-us</language>
    <lastBuildDate>Mon, 19 Oct 2026 12:00:00 +0000</lastBuildDate>
    <atom:link href="https://feedsummary.com/rss.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Building an Agentic AI News Agent Without Losing Editorial Control</title>
      <link>https://feedsummary.com/blog/agentic-ai-news-agent/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/agentic-ai-news-agent/</guid>
      <pubDate>Tue, 29 Sep 2026 12:00:00 +0000</pubDate>
      <description>An architecture for agentic AI news summaries that uses clear tool boundaries, event-driven updates, provenance, and human review gates.</description>
      <category>Automation</category><category>AI Agents</category><category>News Monitoring</category><category>WebSub</category>
      <content:encoded><![CDATA[<p>An agentic AI news agent is best understood as a workflow of bounded tools, state transitions, and review rules—not as one autonomous model roaming the web. Retrieval, parsing, ranking, summarization, verification, and publishing have different failure modes. Separating them makes the system easier to secure, evaluate, and stop when evidence is weak.</p>
<p>This guide outlines an event-driven architecture for monitoring feeds, APIs, documents, and selected websites. It emphasizes editorial control: the agent can coordinate tasks and propose outputs, but source policy, materiality rules, evidence requirements, and publication authority remain explicit.</p>
<h2>Define the agent’s mandate</h2>
<p>Write a narrow mandate that names the topics, sources, geographies, languages, cadence, and audience. State what the agent may do automatically and what requires approval. “Monitor all news” is not an operational scope. “Create a weekday briefing on three named competitors using approved sources, with alerts only for launches, filings, outages, and executive changes” is testable.</p>
<h2>Model the workflow as states</h2>
<p>Use explicit states such as <code>scheduled</code>, <code>collecting</code>, <code>normalizing</code>, <code>clustering</code>, <code>ranking</code>, <code>summarizing</code>, <code>verifying</code>, <code>awaiting_review</code>, <code>approved</code>, <code>published</code>, and <code>failed</code>. A run record should show when each state began, which tool acted, what inputs were used, and why a transition occurred.</p>
<h2>Use events to trigger focused work</h2>
<p>Polling feeds on a schedule is simple, but event-driven updates can reduce delay and unnecessary requests. The <a href="https://www.w3.org/TR/websub/">W3C WebSub Recommendation</a> describes a publish-subscribe pattern in which hubs distribute updates to subscribers. When available, push events can enqueue a specific feed for retrieval while scheduled checks remain as a fallback.</p>
<h2>Create a source registry</h2>
<p>The agent should not discover arbitrary sources at runtime unless discovery is an explicit, reviewed task. Maintain a registry with feed or API URLs, host allowlists, authentication references, polling cadence, parser profile, language, topic scope, and access policy. Each source has an owner and health status.</p>
<h2>Separate collection from interpretation</h2>
<p>Collection tools retrieve bytes and metadata. Parsing tools convert them into source records. Neither should decide whether an article is important. Keep raw or hashed payloads, response status, retrieval time, content type, and parser warnings. This gives later stages an evidence base and allows reprocessing after a parser improvement.</p>
<p>Interpretation begins only after normalization. The model receives bounded records with stable IDs, not live network access. This reduces prompt injection risk and prevents the summarizer from following arbitrary links or instructions embedded in a page.</p>
<h3>Use least-privilege tools</h3>
<p>Give each tool only the permissions it needs. A feed fetcher should not send email. A summarizer should not publish. A publisher should accept only validated, approved briefing objects. Credentials should be scoped by source and operation.</p>
<p>Tool inputs and outputs need schemas. Reject unknown fields, invalid URLs, oversized content, and unexpected media types. Every call should include a correlation ID so the run can be reconstructed without exposing hidden reasoning.</p>
<h2>Normalize every source into one record model</h2>
<p>RSS, Atom, JSON Feed, news APIs, Markdown, PDFs, and scraped pages should converge on a common item schema. Include source ID, item ID, canonical URL, title, authors, publication and modification times, content blocks, language, tags, attachments, extraction status, and provenance.</p>
<p>The <a href="/feed-formats/">feed formats hub</a> describes how different syndication formats map into a shared pipeline.</p>
<h2>Build deterministic filters before model ranking</h2>
<p>Apply host scope, date windows, language rules, required fields, duplicate IDs, and known exclusions with deterministic code. These filters are cheap, explainable, and consistent. A model should not spend tokens deciding whether an item is outside the configured time window.</p>
<h2>Cluster events without erasing disagreement</h2>
<p>Create exact-duplicate groups first, then broader event clusters. Use canonical URLs, content hashes, titles, entities, time, event type, and semantic similarity. Preserve all member records and likely syndication relationships.</p>
<h3>Keep rolling events bounded</h3>
<p>Some stories evolve for days. Define when a new item joins an existing cluster and when a new cluster begins. Use time windows, event states, and material changes. A rolling cluster can maintain a timeline, but it should not become an endless container that mixes unrelated developments.</p>
<p>When a correction arrives, create a revision event and mark affected summaries. Do not silently overwrite the prior record. The agent can propose updated text, but publication rules determine whether to send a correction alert.</p>
<h2>Use specialized summary tasks</h2>
<p>An item-summary task extracts a neutral headline, abstract, key facts, entities, dates, content type, and evidence IDs. A cluster-synthesis task identifies the central development, what changed, source agreement, conflicts, and open questions. A briefing task ranks validated clusters and writes audience-specific sections.</p>
<p>Each task has a separate schema and template version. This prevents one prompt from performing ingestion, ranking, writing, and verification at once. It also allows different models or deterministic methods to be used for different stages.</p>
<h2>Add an independent verification gate</h2>
<p>Verification should receive the draft and the exact evidence blocks, not the entire source universe. It checks named entities, dates, quantities, attributions, evidence IDs, and unsupported inferences. Deterministic validators confirm schema, source references, and time windows.</p>
<h2>Define human review as a product feature</h2>
<p>A review queue should show the draft, materiality reason, source list, timestamps, evidence highlights, extraction warnings, and prior revisions. Reviewers need actions to approve, edit, hold, reject, or request reprocessing. Their decisions should be logged as structured feedback.</p>
<p>Approval thresholds can depend on topic and destination. A low-risk internal digest may auto-publish after verification, while an external alert may always require review. The rule should be configuration, not a hidden judgment inside a prompt.</p>
<p>The <a href="/ai-feed-summary/">AI feed summary workflow</a> explains how evidence and review fit around model generation.</p>
<h2>Keep publishing deterministic</h2>
<p>The publisher should accept only a validated briefing object in an approved state. It renders the object into email, web, chat, or another destination. It should not rewrite the summary or choose new sources. This makes the published output reproducible from the approved record.</p>
<p>Use idempotency keys to prevent duplicate sends. Record destination, delivery ID, time, and rendered content hash. If a delivery fails, retry the publishing operation without rerunning the entire agent workflow.</p>
<h2>Design memory as explicit state</h2>
<p>An agent needs prior context to identify novelty, but “memory” should be stored records, not an unbounded conversation. Maintain source items, clusters, entity timelines, prior briefings, reviewer decisions, and known topic definitions in queryable stores. Retrieve only the relevant slice for each task.</p>
<h2>Protect against prompt injection and tool misuse</h2>
<p>Source content may contain instructions addressed to bots or models. Mark it as untrusted data, use clear boundaries, and prevent the model from selecting arbitrary tools based on article text. Tool calls should be generated from the workflow state and validated against policy.</p>
<p>Block private network destinations, restrict protocols, cap file sizes, sanitize HTML, and isolate document parsers. Do not allow retrieved content to modify source configuration, approval rules, credentials, or publishing destinations.</p>
<p>A security review should consider data exfiltration, malicious documents, compromised feeds, duplicate-event floods, credential scope, and unauthorized publishing. Logs should capture decisions without storing sensitive content unnecessarily.</p>
<h2>Observe runs with useful metrics</h2>
<p>Track source retrieval success, freshness, item volume, parser warnings, duplicate rate, cluster size, ranking acceptance, summary schema failures, verification issues, review time, edit rate, and publication success. Segment metrics by source, topic, language, and workflow version.</p>
<p>A dashboard should make coverage gaps visible. “No news” and “source failed for three days” are different states. Alert on stale sources, sudden content-length shifts, repeated empty extraction, and unusual event volume.</p>
<h2>Evaluate the whole agent, not only summaries</h2>
<p>Create historical replay sets with known source items and desired briefings. Test retrieval coverage, filtering, duplicate handling, cluster formation, ranking, factual support, and publication decisions. A perfect paragraph cannot compensate for a missed critical source or an incorrect cluster.</p>
<p>Use stage-specific labels. When a reviewer rejects a briefing item, record whether the problem was scope, extraction, duplication, ranking, unsupported claim, tone, or timing. This determines which component should change.</p>
<p>Run adversarial tests with misleading headlines, injected instructions, conflicting dates, syndicated copies, broken feeds, scanned PDFs, and source corrections. Verify that the workflow pauses or degrades visibly rather than producing confident output from weak evidence.</p>
<h2>Plan failure and recovery</h2>
<p>Every state should have a timeout, retry policy, and owner. If a model service is unavailable, the agent can preserve collected items and resume later. If one source fails, the briefing should disclose incomplete coverage rather than blocking all other sources indefinitely.</p>
<h2>A staged rollout</h2>
<p>Begin with approved feeds, a scheduled daily run, deterministic filters, item summaries, and mandatory human review. Add clustering and cluster synthesis after reviewers trust item records. Introduce event-driven updates, source enrichment, and limited automatic publication only after verification and rollback paths are proven.</p>
<h2>Conclusion</h2>
<p>An agentic AI news agent remains controllable when agency is expressed through bounded state transitions and validated tools. Define a narrow mandate, register approved sources, normalize records, filter deterministically, cluster with provenance, use specialized summary tasks, verify independently, and make review and publishing explicit gates.</p>
<p>The result can move quickly without becoming opaque. Automation handles repetitive collection and synthesis, while editorial authority remains visible in source policy, materiality rules, evidence requirements, and approval decisions.</p>
]]></content:encoded>
    </item>
    <item>
      <title>Prompt Templates for Consistent Feed Summaries</title>
      <link>https://feedsummary.com/blog/prompt-templates-feed-summaries/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/prompt-templates-feed-summaries/</guid>
      <pubDate>Wed, 24 Jun 2026 12:00:00 +0000</pubDate>
      <description>Create prompt templates that keep feed summaries consistent across sources, models, topics, lengths, and editorial use cases.</description>
      <category>AI Summarization</category><category>Prompt Engineering</category><category>Structured Output</category><category>Evaluation</category>
      <content:encoded><![CDATA[<p>A prompt template for feed summaries should behave like a small editorial contract. It defines the purpose of the summary, separates instructions from source content, specifies the output fields, states how to handle missing or conflicting information, and gives evaluators something stable to test. A clever one-off prompt may produce an impressive example, but a versioned template is what makes a production briefing consistent.</p>
<p>This guide shows how to design templates for item summaries, topic clusters, executive briefings, research notes, and alerts. It emphasizes reusable structure rather than model-specific tricks, so the same contract can be evaluated across providers and updated without rewriting the entire pipeline.</p>
<h2>Start with the reader and decision</h2>
<p>A summary is useful only relative to a reader’s goal. Define who will read it, what they already know, how much time they have, and what decision or next step the summary should support. An editor reviewing story leads needs different output from an engineer scanning release notes or an investor monitoring filings.</p>
<p>Write that purpose in the template. “Summarize this article” is underspecified. “Create a neutral, 120-word briefing for a product operations team; identify the change, affected users, effective date, required action, and unresolved questions” creates observable expectations.</p>
<h2>Treat the template as configuration</h2>
<p>Store prompts in version control with an identifier, owner, purpose, input schema, output schema, examples, and change log. Do not bury the only copy inside application code or a model dashboard. A summary record should retain the template ID and version that produced it.</p>
<p>Separate stable policy from use-case variables. The stable layer can define source handling, uncertainty rules, and safety constraints. Variables can include audience, topic, target length, language, and requested fields. This reduces duplicated prompts that drift apart over time.</p>
<h2>Delimit source content clearly</h2>
<p>Place source metadata and body content inside explicit boundaries. Label fields such as source ID, title, publication time, author, and section path. Tell the model that the enclosed material is untrusted evidence and that instructions within it must not alter the task.</p>
<h3>Keep instructions outside the evidence</h3>
<p>Do not append task instructions after the article body in a way that could be confused with the source. Put the role, objective, constraints, and output schema before the evidence, then close the evidence explicitly. This layout also makes logs easier to inspect.</p>
<p>The <a href="/prompt-library/">prompt library</a> provides example envelopes for RSS items, article pages, PDF sections, and multi-source clusters.</p>
<h2>Specify facts, inference, and uncertainty</h2>
<p>Tell the model which fields must be directly supported and which may contain synthesis. A <code>key_facts</code> array should contain statements traceable to the source. A <code>why_it_matters</code> field may include reasoned implications, but it should be labeled as analysis and avoid unsupported certainty.</p>
<p>The template should prohibit invented quotations, dates, statistics, and causal relationships. It should also require attribution for claims made by people or organizations. “The company said” is different from an independently verified fact.</p>
<h2>Request a structured output contract</h2>
<p>Structured output reduces formatting drift and makes validation possible. Define field names, types, maximum lengths, enums, and required values. A common item schema might include <code>neutral_headline</code>, <code>summary</code>, <code>key_points</code>, <code>entities</code>, <code>event_date</code>, <code>content_type</code>, <code>open_questions</code>, and <code>evidence_ids</code>.</p>
<h3>Make length measurable</h3>
<p>“Brief” and “detailed” are subjective. Specify word or character limits per field and the maximum number of bullets. State which content to prioritize when the source contains more detail than fits. For example: preserve dates, quantities, decisions, named actors, and explicit caveats before background description.</p>
<h2>Use evidence identifiers</h2>
<p>Assign IDs to paragraphs, page blocks, table rows, or source items and require the model to return those IDs with important statements. Evidence IDs make the visible output reviewable and help automated checks determine whether a claim has a plausible source location.</p>
<h2>Create separate templates for separate stages</h2>
<p>Item summarization, cluster synthesis, ranking, and verification are different tasks. Do not combine them into one giant prompt that asks the model to read raw content, remove duplicates, decide importance, write a briefing, and audit itself. Each stage should have a focused input and output.</p>
<h2>Design an item-summary template</h2>
<p>The item template should receive one source record and normalized content blocks. It can ask for a neutral headline, one-sentence abstract, three to five key points, entities, dates, content type, and evidence. Include the source title as metadata, but tell the model not to copy promotional wording blindly.</p>
<p>A strong template also asks for extraction warnings to be considered. When the system supplies only an excerpt, the output can state that coverage is limited and avoid claims about what the full article contains.</p>
<h2>Design a cluster-synthesis template</h2>
<p>The cluster template should receive structured item summaries plus source metadata and duplicate relationships, not a pile of raw articles. Ask it to identify the central development, new information, points of agreement, meaningful differences, timeline, and open questions. Require source IDs for each key point.</p>
<p>Tell the model that multiple syndicated copies do not equal independent confirmation. Provide a field indicating likely syndication or shared origin. The synthesis should not say “several independent reports” unless the metadata supports independence.</p>
<p>Limit background repetition. A cluster summary should explain the change from prior known state, not restate every item. When the cluster contains contradictory claims, preserve them and identify what evidence would resolve the conflict.</p>
<h2>Design an executive briefing template</h2>
<p>An executive briefing works from validated cluster records. It should prioritize material developments, state the coverage window, and separate confirmed changes from watch items. A useful schema may include <code>top_developments</code>, <code>implications</code>, <code>decisions_needed</code>, <code>watchlist</code>, and <code>coverage_notes</code>.</p>
<p>The <a href="/ai-news-agent/">AI news agent page</a> explains how briefing templates fit into a tool-based workflow with review gates.</p>
<h2>Design an alert template</h2>
<p>Alerts need strict thresholds and compact output. Provide the triggering rule, entity, event type, and source evidence. Ask for a short title, what happened, why the alert fired, confidence conditions, and a link to the source record. Include a <code>send</code> or <code>hold</code> recommendation only if the model has explicit decision criteria.</p>
<h2>Use examples carefully</h2>
<p>Examples clarify tone, field boundaries, and uncertainty handling. Include a small number of representative input-output pairs, especially edge cases. Show a missing date returning null, conflicting sources remaining separate, and an opinion article labeled as analysis.</p>
<p>The <a href="https://developers.openai.com/api/docs/guides/prompt-engineering">OpenAI prompt engineering guide</a> discusses general techniques for writing and organizing instructions. Regardless of model provider, the production discipline is the same: make requirements explicit, separate data from instructions, test changes, and prefer observable contracts over vague stylistic requests.</p>
<h2>Validate every response</h2>
<p>Parse the output against the declared schema. Reject or repair invalid types, missing required fields, unexpected fields, excessive lengths, and unknown evidence IDs. Do not render raw model output directly into a page or email.</p>
<h2>Build an evaluation set before tuning</h2>
<p>Collect representative source items and write expected facts, prohibited errors, and preferred output characteristics. Include short posts, long reports, duplicate coverage, corrections, ambiguous dates, low-quality extraction, opinion pieces, and tables. The set should reflect actual production sources.</p>
<p>Evaluate field completeness, factual support, attribution, compression, readability, and uncertainty handling. Keep metrics separate. A template can become more concise while losing a critical date; one overall score may hide that tradeoff.</p>
<p>Human reviewers should compare outputs without knowing which template version produced them. Record reasons for preference and classify failures. These labels guide revisions more effectively than unstructured comments.</p>
<h2>Change one dimension at a time</h2>
<p>When improving a template, isolate the change when possible. Adjust evidence rules, length, or examples separately so the effect can be measured. Run the full evaluation set and compare failures by category. A change that helps long reports may harm short alerts.</p>
<p>Retain prior versions and support rollback. A template deployment should be treated like a code change with review, tests, staged release, and monitoring. Record the model configuration alongside the prompt because behavior can change when either component changes.</p>
<h2>Monitor production drift</h2>
<p>Track schema failures, empty fields, unsupported-claim flags, correction rate, reviewer edits, and summary length by source and template version. A sudden shift may indicate a model update, extraction change, new source layout, or topic drift.</p>
<p>Sample production outputs regularly, including successful-looking ones. Fluent text can conceal attribution or date errors. Monitor low-frequency but high-impact fields such as regulatory deadlines and monetary amounts separately.</p>
<h2>A reusable template anatomy</h2>
<p>A practical template can contain: role and audience; objective; source-handling rules; definitions; output schema; length limits; uncertainty and conflict rules; evidence requirements; prohibited behavior; and a small set of examples. The runtime then inserts metadata and source blocks into a clearly delimited evidence section.</p>
<p>Keep the language direct. Remove duplicated instructions and resolve contradictions. A long prompt is not automatically a strong prompt. Every clause should exist because a test or production failure demonstrated its value.</p>
<h2>Conclusion</h2>
<p>Consistent feed summaries come from versioned output contracts, not from repeatedly asking for “a good summary.” Define the reader’s decision, separate instructions from evidence, request structured fields, require evidence IDs, split pipeline stages, validate responses, and test every change against a stable corpus.</p>
<p>A prompt template built this way is easier to compare across models, safer to automate, and simpler for editors and engineers to improve together. It turns summarization from an improvised conversation into an observable component of the feed pipeline.</p>
]]></content:encoded>
    </item>
    <item>
      <title>Website Scraping for Feed Summaries: Respectful Extraction and Change Detection</title>
      <link>https://feedsummary.com/blog/website-scraping-feed-summary/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/website-scraping-feed-summary/</guid>
      <pubDate>Wed, 11 Feb 2026 12:00:00 +0000</pubDate>
      <description>A responsible website-scraping workflow for generating feed summaries from pages that do not publish usable RSS, Atom, or JSON feeds.</description>
      <category>Data Pipelines</category><category>Web Scraping</category><category>Robots.txt</category><category>Change Detection</category>
      <content:encoded><![CDATA[<p>Website scraping can fill a gap when a site does not publish a usable feed or API, but it adds responsibilities that feed consumers normally avoid. The workflow must check access policy, limit request load, distinguish article content from interface boilerplate, detect changes without refetching everything, and preserve evidence from pages that may later change.</p>
<p>A responsible scraping system is not a generic “download the web” tool. It is a source-specific ingestion process with explicit scope, rate controls, and failure handling. This guide focuses on using page extraction to create feed-like records and AI summaries while keeping the process reviewable.</p>
<h2>Prefer published interfaces first</h2>
<p>Before scraping a page, look for RSS, Atom, JSON Feed, sitemaps, publisher APIs, export endpoints, or structured data. A published interface is usually more stable and supplies cleaner identity and date metadata. Scraping should be the fallback for sources whose public pages are the only suitable representation.</p>
<h2>Define scope and authority</h2>
<p>Specify which hosts, paths, page types, and content fields are in scope. A monitor for a newsroom’s press releases should not drift into account pages, archives, search results, or unrelated subdomains. Use an allowlist of hosts and path patterns, and reject destinations outside it after every redirect.</p>
<h2>Read and respect crawl instructions</h2>
<p>The <a href="https://datatracker.ietf.org/doc/rfc9309/">Robots Exclusion Protocol in RFC 9309</a> defines a standardized way for service owners to communicate crawler access rules. Fetch the robots file for the target origin, parse it for the crawler identity in use, cache it according to policy, and recheck it periodically. A missing or unreachable file should be handled according to documented rules, not personal assumption.</p>
<h2>Use a transparent crawler identity</h2>
<p>Send a stable user-agent string that identifies the crawler and provides a contact or information page when appropriate. Do not impersonate a browser or another crawler to bypass controls. A transparent identity lets operators diagnose requests and reach the responsible party.</p>
<p>Keep request headers simple and consistent. Avoid carrying user cookies or authentication tokens into a general scraping worker. Isolate source credentials when authorized access is required, and ensure one source cannot receive another source’s secrets.</p>
<h2>Limit requests by host and purpose</h2>
<p>Set per-host concurrency, minimum delays, daily caps, timeouts, and backoff. The right rate depends on source scale and agreement, but “as fast as possible” is rarely appropriate. A scheduler should spread work and prioritize changed pages rather than repeatedly downloading stable archives.</p>
<h3>Prevent retry storms</h3>
<p>Classify errors before retrying. Network timeouts and some server errors may be transient; access denials, unsupported media types, or invalid URLs are usually not. Apply exponential backoff with jitter and a maximum attempt count. Pause a source when repeated failures indicate a site change or operator block.</p>
<p>A queue should use deterministic job keys so retries do not create duplicate records. Capture the attempt count, response status, and next eligible time. Operational visibility is essential when dozens of source-specific crawlers are running on different schedules.</p>
<h2>Discover pages conservatively</h2>
<p>Start with known listing pages, sitemaps, category archives, or a curated URL set. Extract candidate links only from in-scope pages and normalize them before queueing. Avoid unbounded recursive crawling. A depth limit alone is not enough; calendar and faceted navigation can create infinite URL spaces at shallow depth.</p>
<p>Canonicalize URLs by resolving relative paths, normalizing host case, removing fragments, and stripping known tracking parameters. Preserve parameters that select real content. Maintain a denylist for logout links, search pages, print variants, tag combinations, and other traps discovered during operation.</p>
<p>The <a href="/content-workflows/">content workflows hub</a> compares scraping with feed, API, article, and PDF ingestion paths.</p>
<h2>Identify article pages before full extraction</h2>
<p>Use URL patterns, link context, structured data, meta tags, and page layout signals to classify candidate pages. A page with an article title, publication time, author, and substantial central text is more likely to be an item than a category page. Keep the classifier’s reasons and confidence for review.</p>
<h2>Preserve the fetch record</h2>
<p>For every response, store the requested URL, final URL, status, retrieval time, content type, relevant headers, content hash, and source configuration version. Keep the raw HTML or a policy-compliant snapshot when reproducibility is required. A live page may change before a summary is reviewed.</p>
<h2>Extract the main content with evidence boundaries</h2>
<p>Parse the document and identify the main article container. Remove navigation, advertisements, recommendation modules, social controls, cookie banners, and repeated footer elements. Preserve title, subtitle, authors, publication and modification times, headings, paragraphs, lists, quotations, captions, and table labels.</p>
<p>Convert meaningful elements into ordered blocks with stable IDs and source selectors or coordinates. Store extraction confidence and the rules that selected the container. This structure supports semantic chunking and lets a reviewer locate the source behind a summary claim.</p>
<h3>Use structured data as a signal, not absolute truth</h3>
<p>JSON-LD and meta tags can provide titles, dates, authors, and canonical URLs. They are valuable, but they may be stale, templated, or inconsistent with visible content. Compare them with page text and preserve both values when they differ.</p>
<h2>Detect templates and boilerplate over time</h2>
<p>Source-specific boilerplate is easier to detect across many pages. Repeated blocks at the same structural location can be marked as navigation or promotion. Use text frequency, DOM paths, and visual position, but retain exceptions. A recurring legal disclaimer may be important in one domain and irrelevant in another.</p>
<p>Template learning should be versioned. When a site redesigns, old selectors may extract nothing or the wrong region. Monitor meaningful-text length, heading count, link density, and block similarity. Sudden shifts should pause automatic summaries until the new layout is reviewed.</p>
<h2>Create stable page identity</h2>
<p>Use the canonical URL when it is valid and in scope, supplemented by a source-specific ID from structured data when available. Keep the requested and final URLs. Generate a normalized content hash for revision detection, but do not use the hash as the only identity because every edit would create a new item.</p>
<h2>Detect meaningful changes</h2>
<p>HTML hashes change for trivial reasons such as timestamps, ad slots, and personalization. Compare normalized content blocks instead. Ignore known dynamic regions and calculate hashes by block or section. A material-change rule can consider added or removed paragraphs, changed numbers, new headings, or revised publication metadata.</p>
<h2>Guard against hostile and accidental input</h2>
<p>Fetched pages are untrusted. Block private and link-local destinations, revalidate addresses after redirects, restrict protocols, cap response sizes, and use parser limits. Sanitize active HTML and process complex documents in constrained workers. Never execute scripts from the target page in the main application context.</p>
<h2>Summarize only supported content</h2>
<p>The summary request should include the normalized title, source metadata, ordered content blocks, and a clear schema. Ask for a concise abstract, key facts, dates, entities, and evidence IDs. If extraction is partial or the page is mostly navigation, return a warning or no summary.</p>
<p>For several related pages, cluster them after item-level extraction. Do not concatenate raw HTML from multiple pages. Provide source IDs and timestamps so the synthesis can distinguish repeated reporting from independent details.</p>
<p>The <a href="/website-scraping/">website scraping page</a> includes a sample record for crawl policy, retrieval, extraction, revision, and summary state.</p>
<h2>Expose coverage and limitations</h2>
<p>A final briefing should identify scraped sources and indicate when content was partial, rendered, or changed. Show source links, retrieval times, and publication times separately. A reader should not assume a page was current at briefing time if it was retrieved hours earlier.</p>
<p>Track extraction coverage, warnings, and last successful fetch per source. A source that has failed for three days should be visibly stale. Silent gaps create a false impression that nothing happened.</p>
<h2>Maintain a source test suite</h2>
<p>Save representative pages for every source: a normal article, a short update, a page with a table, an archive page, and a redesigned variant when available. Test selectors and extraction rules against these snapshots. Verify that navigation is removed, body content remains ordered, and metadata mappings are stable.</p>
<p>Run regression tests before deploying parser changes. A global heuristic that improves one site may damage another. Prefer small source-specific profiles built on a safe shared extractor. Record why each override exists.</p>
<h2>Operational checklist</h2>
<p>A responsible source configuration should answer: Is access authorized? What do robots rules say? Which paths are allowed? What is the request rate? How are URLs discovered? How is an article page classified? Which extractor profile is used? What counts as a material change? When does the source pause for review?</p>
<p>At the item level, retain requested and final URLs, retrieval metadata, raw or hashed content, normalized blocks, canonical identity, extraction warnings, content version, and summary provenance. These records turn scraping from an opaque script into an auditable ingestion system.</p>
<h2>Conclusion</h2>
<p>Website scraping can extend feed summaries to sources without usable feeds, but it should remain narrow, respectful, and observable. Prefer published interfaces, define scope, respect crawl instructions, identify the crawler, control request rates, preserve fetch records, and detect meaningful content changes rather than raw HTML noise.</p>
<p>When source policy, extraction quality, and evidence remain visible, a scraped page can enter the same normalized summary workflow as an RSS item or API result. The system gains coverage without sacrificing accountability.</p>
]]></content:encoded>
    </item>
    <item>
      <title>Markdown Feed Summary: Clean Text, Stable Structure, Better Prompts</title>
      <link>https://feedsummary.com/blog/markdown-feed-summary-workflow/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/markdown-feed-summary-workflow/</guid>
      <pubDate>Fri, 19 Dec 2025 12:00:00 +0000</pubDate>
      <description>Learn why Markdown is useful for feed summary pipelines and how to preserve headings, lists, links, code, and document boundaries.</description>
      <category>Document Processing</category><category>Markdown</category><category>CommonMark</category><category>Content Normalization</category>
      <content:encoded><![CDATA[<p>Markdown is useful in a feed summary pipeline because it can preserve document structure without carrying the full complexity of source HTML. Headings, paragraphs, lists, quotations, links, tables, and code remain visible to both people and software. That makes Markdown a strong intermediate representation between extraction and AI summarization, provided the conversion rules are predictable.</p>
<p>The key is to treat Markdown as structured content rather than as a cosmetic export format. A pipeline should know where the Markdown came from, which elements were preserved, what was removed, and how document boundaries are represented. This guide explains how to normalize feed items, articles, and documents into stable Markdown for downstream summaries.</p>
<h2>Decide why Markdown belongs in the pipeline</h2>
<p>Markdown can serve several roles. It can be the original source format, a normalized representation of HTML, a transport format between services, or a human-review artifact. These roles have different requirements. Original Markdown may include site-specific extensions, while normalized Markdown should use a deliberately limited subset that every downstream component understands.</p>
<p>A useful design separates canonical structured blocks from rendered Markdown. The block model stores element type, source location, identifiers, and metadata. Markdown is generated from those blocks for model input and reviewer display. This avoids making a parser recover provenance from punctuation later.</p>
<h2>Choose a documented syntax baseline</h2>
<p>Markdown implementations differ in tables, footnotes, task lists, raw HTML, automatic links, and line breaks. Select a baseline and name any extensions explicitly. The <a href="https://commonmark.org/help/">CommonMark reference</a> provides a concise overview of a standardized core syntax. A pipeline can add a small extension set, but it should not assume that every renderer interprets vendor-specific features in the same way.</p>
<p>Record the dialect on each normalized document. If source content uses unsupported constructs, convert them to a supported representation or preserve them as fenced raw blocks with a warning. Silent reinterpretation can change meaning, especially in nested lists or code examples.</p>
<h2>Preserve source metadata outside the body</h2>
<p>Do not place every field in an unstructured preamble. Keep title, canonical URL, authors, publication date, source name, language, feed item ID, and retrieval time in a metadata object. When a self-contained Markdown artifact is useful, serialize that metadata in a documented front matter block, but treat the front matter as data rather than part of the article body.</p>
<h2>Convert HTML by meaning, not appearance</h2>
<p>Source HTML often contains nested containers that exist only for layout. Map semantic elements to Markdown: headings to heading markers, paragraphs to paragraphs, ordered and unordered lists to list syntax, block quotations to quote markers, and code to inline or fenced code. Ignore style classes unless they carry known meaning.</p>
<p>Remove navigation, advertisements, cookie messages, related-story grids, and repeated footer text before conversion. Preserve meaningful captions, callouts, definition terms, and table headers. When an element has no safe Markdown equivalent, represent it with a labeled placeholder or a fenced block rather than dropping it silently.</p>
<h3>Handle links deliberately</h3>
<p>Links can be preserved as text plus destination, but a summary prompt rarely needs every navigation or citation URL inline. Classify links before rendering. Keep editorial links, references, and definitions. Remove tracking parameters and exclude interface links such as “share,” “print,” or “next page.”</p>
<p>For model input, reference-style links can reduce visual noise when an article contains many long URLs. Assign stable link IDs and place destinations in a link table after the content. The final summary can cite internal source IDs rather than copying arbitrary external URLs.</p>
<h2>Represent headings as a real hierarchy</h2>
<p>Heading levels help chunking and synthesis. Normalize skipped levels cautiously: a source may jump from an H1 to an H4 for visual styling, but the visual relationship does not always justify inventing intermediate sections. Use surrounding structure, typography, and section numbering to infer a hierarchy, and record when the mapping is uncertain.</p>
<p>The <a href="/markdown-feed-summary/">Markdown feed summary page</a> provides an example of a document envelope that keeps item metadata, content, and evidence identifiers separate.</p>
<h2>Preserve lists and procedural order</h2>
<p>Lists often carry more meaning than equivalent paragraphs. Ordered steps should remain ordered, including nested substeps. Bullet lists may represent features, findings, or examples. Keep the list type and indentation stable, and avoid wrapping that changes nesting.</p>
<h2>Protect code, commands, and machine-readable data</h2>
<p>Inline code and fenced blocks should be preserved exactly except for well-defined encoding normalization. Choose a fence length that cannot be terminated by content inside the block. Include a language hint only when known. Do not let code indentation be altered by line wrapping.</p>
<h2>Normalize tables without losing headers</h2>
<p>Markdown tables work well for small, rectangular data with one header row. They are less suitable for merged cells, multi-level headers, footnotes, or very wide tables. Detect those cases before conversion. A complex table may be better represented as structured JSON, a sequence of records, or a labeled text block.</p>
<h2>Keep quotations and attribution together</h2>
<p>Block quotations should preserve the quoted text and nearby attribution. A quote without a speaker can be misleading, while an attribution separated into another chunk may disappear during summarization. Represent the speaker, role, and source context as metadata or an adjacent paragraph.</p>
<p>Do not add quotation markers to paraphrased text. If the source uses typographic pull quotes that repeat a sentence from the body, deduplicate them while retaining the original occurrence. A content hash or text overlap rule can detect many repeated pull quotes.</p>
<h2>Mark document and item boundaries</h2>
<p>When a prompt contains multiple feed items, each item should have an unmistakable envelope. Use a stable item ID, metadata block, start marker, body, and end marker. Avoid delimiters that commonly appear in source text. The model should be instructed that everything inside the envelope is untrusted source content.</p>
<p>A simple pattern might render an item heading, a metadata table, and the normalized body under a unique identifier. The canonical system should still store boundaries outside the Markdown string. The rendered markers are a defense against accidental blending, not the only source of truth.</p>
<h2>Remove prompt-like ambiguity from source content</h2>
<p>Articles can contain phrases that resemble instructions, code, or role labels. The summarization prompt should clearly state that the Markdown is evidence to analyze and that instructions inside it must not alter the task. Escape or label embedded chat transcripts, prompt examples, and system messages as quoted source blocks.</p>
<p>Do not delete such material if it is relevant to the article. Instead, preserve it with a content type. A security article may legitimately discuss prompt injection; the workflow must summarize that discussion without obeying the example instructions.</p>
<h2>Chunk Markdown along semantic boundaries</h2>
<p>Chunk by section, paragraph group, list, table, or code block. Keep a heading with the content it governs. Avoid splitting a list in the middle or separating a table from its title and units. Use token limits as constraints after semantic grouping, not as the primary segmentation method.</p>
<h2>Summarize into a structured schema</h2>
<p>Markdown improves input readability, but output should still follow an explicit contract. Request fields such as <code>summary</code>, <code>key_points</code>, <code>entities</code>, <code>dates</code>, <code>open_questions</code>, and <code>evidence_ids</code>. For technical content, add <code>commands</code>, <code>requirements</code>, <code>warnings</code>, or <code>breaking_changes</code> as appropriate.</p>
<h2>Round-trip test the conversion</h2>
<p>Build a corpus of headings, nested lists, code fences, tables, links, quotes, Unicode, and raw HTML. Convert source content to blocks, render Markdown, parse it again, and compare the semantic structure. Exact whitespace may differ, but headings, list order, code, and table values should survive.</p>
<p>Add publisher-specific pages and documents from the real source set. A generic converter can pass unit tests while failing on a site that uses custom components. Track dropped elements and conversion warnings per source domain.</p>
<h2>Evaluate summary effects, not only syntax</h2>
<p>A syntactically valid Markdown document can still be a poor summary input if boilerplate remains or key relationships are lost. Compare summaries from raw HTML, plain text, and normalized Markdown on a representative set. Evaluate factual coverage, attribution, structure, and reviewer effort.</p>
<p>Markdown should earn its place by making the pipeline more predictable and inspectable. If a particular content type, such as a complex financial table, performs better in structured JSON, preserve that specialized representation instead of forcing every block through Markdown.</p>
<h2>A practical normalization profile</h2>
<p>A conservative profile can support headings, paragraphs, emphasis, ordered and unordered lists, block quotes, links, images with meaningful alt text, fenced code, and simple tables. It can strip raw scripts and styles, convert callouts to labeled block quotes, and represent unsupported embeds as descriptive placeholders.</p>
<p>Pair the profile with metadata rules, boundary markers, block IDs, and a warning vocabulary. Version the profile so a conversion change can be tested against prior documents. Store both the original source and normalized output hash.</p>
<h2>Conclusion</h2>
<p>Markdown is effective for feed summaries when it acts as a stable, documented view of richer source blocks. Choose a syntax baseline, keep metadata separate, convert HTML semantically, preserve hierarchy and evidence boundaries, and use specialized representations for content that Markdown cannot express safely.</p>
<p>The result is clean input that remains readable to reviewers and predictable for models. More importantly, the pipeline can explain what was kept, what was removed, and where every summarized claim originated.</p>
]]></content:encoded>
    </item>
    <item>
      <title>PDF to AI Feed Summary: A Reliable Document Processing Workflow</title>
      <link>https://feedsummary.com/blog/pdf-to-ai-feed-summary/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/pdf-to-ai-feed-summary/</guid>
      <pubDate>Mon, 08 Sep 2025 12:00:00 +0000</pubDate>
      <description>A reliable PDF-to-AI feed summary workflow for reports, research papers, filings, manuals, and other long documents.</description>
      <category>Document Processing</category><category>PDF</category><category>Document Processing</category><category>AI Summarization</category>
      <content:encoded><![CDATA[<p>Turning a PDF into an AI feed summary is a document-processing problem before it is a summarization problem. A PDF may contain selectable text, scanned images, multiple columns, page headers, footnotes, tables, forms, or a mixture of all of them. If extraction scrambles reading order or drops page context, a fluent model can produce a concise summary of the wrong text.</p>
<p>A reliable workflow therefore keeps the original file, records how each text block was obtained, preserves page labels and structure, and routes difficult pages through specialized handling. This guide presents a staged process for reports, research papers, filings, manuals, slide-like documents, and other long-form PDFs.</p>
<h2>Treat the PDF as a versioned source object</h2>
<p>Store the source URL or upload identifier, retrieval time, file size, media type, cryptographic hash, and any visible title or publication metadata. The file hash identifies the exact bytes used for extraction and summary. If a publisher replaces a report at the same URL, the workflow can recognize the new version instead of silently treating it as the old one.</p>
<h2>Validate the file before processing</h2>
<p>Confirm that the response is actually a PDF, apply size and page-count limits, and reject encrypted or malformed files according to policy. Complex documents should be processed in an isolated environment with time and memory limits. A parser failure should create a clear error state rather than falling through to an empty summary.</p>
<p>The <a href="https://pdfa.org/pdf-standards/">PDF Association standards overview</a> maps the ISO standards and specialized PDF families used in the ecosystem. A pipeline does not need to implement every feature, but it should record the declared PDF version and recognize that archival, accessible, engineering, and interactive documents may have different structures and expectations.</p>
<h2>Inventory pages before extracting everything</h2>
<p>Run a lightweight page inventory first. Record dimensions, rotation, number of text objects, image coverage, font count, and whether selectable text exists. These signals help classify pages as born-digital text, image scans, forms, slides, or mixed layouts.</p>
<h3>Preserve page labels and physical page numbers</h3>
<p>Documents often print Roman numerals in front matter and restart numbering in the main text. PDF page labels may differ from zero-based file positions. Store both the physical page index and the visible page label when available. Evidence references can then say “page 17” as the reader sees it while still pointing to the exact internal page.</p>
<p>Page boundaries should remain visible in the normalized content. A summary that combines a heading from one page with an unrelated paragraph from the next can create false context. Keep block coordinates or at least page membership until the final rendering stage.</p>
<h2>Extract born-digital text with layout awareness</h2>
<p>For selectable text, collect characters or spans with coordinates, font properties, and reading-order hints. Reconstruct lines and blocks carefully. The order in which text objects appear in a PDF file is not guaranteed to match visual reading order, especially in multi-column layouts.</p>
<h2>Route scanned pages through OCR</h2>
<p>OCR should be applied only where needed, because it introduces its own errors and cost. Preprocess scans with rotation correction, deskewing, contrast adjustment, and noise reduction. Detect the document language or allow it to be supplied; the wrong OCR language can distort names and technical terms.</p>
<h3>Avoid repeated OCR text</h3>
<p>Some PDFs contain both an image and a hidden OCR text layer. Running OCR again can duplicate the content. The page inventory should detect existing text that aligns with image regions. Prefer the existing layer when quality is adequate, or replace it deliberately rather than appending a second copy.</p>
<p>For handwritten annotations, marginal notes, or stamps, decide whether they are in scope. They may be legally or editorially important even though they are not part of the main printed text. Store them as separate annotation blocks with page coordinates when extracted.</p>
<h2>Detect document structure</h2>
<p>A summary improves when the system understands sections. Use typography, numbering patterns, whitespace, bookmarks, and the table of contents to infer headings. Build a hierarchy such as title, section, subsection, and paragraph. Preserve numbered clauses in legal or policy documents because references often depend on them.</p>
<p>The <a href="/pdf-feed-summary/">PDF feed summary page</a> shows a normalized record model for page blocks, section paths, tables, and evidence references.</p>
<h2>Handle tables as data, not paragraphs</h2>
<p>Tables are a frequent source of summary errors. Text extractors may interleave columns or output cells in the wrong order. Detect table regions and reconstruct rows and columns using lines, whitespace, and coordinates. Preserve table titles, headers, units, footnotes, and source page.</p>
<h2>Capture figures and captions selectively</h2>
<p>Figures may carry essential information that is not repeated in text. At minimum, extract captions and nearby references. For charts, consider a vision step that describes axes, series, and annotations, but separate visual interpretation from textual extraction. A chart-derived fact should indicate that its evidence is visual.</p>
<p>Decorative images, logos, and repeated icons can be ignored. Use size, location, caption presence, and cross-reference language to rank figures for processing. A research paper’s primary result chart may deserve attention; a background photograph in an annual report may not.</p>
<h2>Normalize into evidence blocks</h2>
<p>Create an ordered block model with fields such as <code>block_id</code>, <code>page_index</code>, <code>page_label</code>, <code>section_path</code>, <code>block_type</code>, <code>text</code>, <code>bbox</code>, <code>extraction_method</code>, and <code>confidence</code>. Block types can include heading, paragraph, list item, table, caption, footnote, form field, and annotation.</p>
<p>This model supports semantic chunking. A chunk can include a heading and its paragraphs while remaining within a token budget. Tables and captions can travel with the surrounding explanation. Evidence references in the summary can point to stable block IDs and page labels.</p>
<h2>Chunk by section and purpose</h2>
<p>Long PDFs rarely fit in one model context, and sending the entire document is often inefficient. Chunk along section boundaries, then split oversized sections by paragraph or table groups. Include the section path, page range, document title, and relevant metadata with every chunk.</p>
<p>Different document types need different schemas. A research paper may require objective, method, sample, findings, and limitations. A financial filing may require period, statements, material changes, risks, and management commentary. A manual may require prerequisites, procedures, warnings, and troubleshooting.</p>
<h2>Verify numbers, dates, and named entities</h2>
<p>Extract important numbers and dates from the draft summary and compare them with evidence blocks. Pay special attention to decimal points, negative signs, percentages, ranges, and table units. OCR errors often turn <code>0</code> into <code>O</code>, drop minus signs, or split figures across cells.</p>
<p>Entity names should be matched to the document text. Acronyms can refer to different concepts in different sections, so keep local context. Quotations should be exact or clearly paraphrased; do not invent quotation marks around generated wording.</p>
<p>A verification pass can identify unsupported sentences, but deterministic checks remain useful. Evidence IDs must exist, page labels must be valid, and every table-derived figure should retain its row, column, and unit.</p>
<h2>Represent extraction quality honestly</h2>
<p>Return quality signals with the summary: percentage of pages with selectable text, percentage routed through OCR, number of tables detected, pages skipped, and warnings for low-confidence regions. These signals are more interpretable than a single opaque confidence score.</p>
<h2>Support incremental and revised documents</h2>
<p>When a new version arrives, compare file hashes, page counts, text-block hashes, and section structure. If only a few sections changed, regenerate those section summaries and the document synthesis rather than reprocessing everything. Preserve links between old and new versions.</p>
<p>Revision comparison is valuable for policies, reports, and filings. A change summary should describe added, removed, and modified sections with evidence. Do not rely only on visual PDF differences, which may reflect layout changes rather than substantive edits.</p>
<h2>Build an operational review path</h2>
<p>A review interface should display the final summary, section records, page images, and highlighted evidence. Reviewers need a fast way to correct extraction order, merge or split blocks, and mark unsupported claims. Their corrections can become test cases for future parser or prompt changes.</p>
<p>Track failures by document type and source. If one publisher’s reports consistently use a complex two-column layout, create a source-specific profile rather than adding global heuristics that may harm other documents. Maintain a benchmark set with scans, tables, footnotes, rotated pages, and mixed layouts.</p>
<h2>Implementation sequence</h2>
<p>Begin with born-digital PDFs that have clear headings and selectable text. Preserve page boundaries, create structured blocks, and generate section summaries with evidence IDs. Add deterministic verification for dates and numbers. Once the baseline is stable, introduce OCR for scanned pages and specialized table extraction.</p>
<p>Next, add document-type schemas, revision comparison, and visual figure handling. Keep every stage observable. The pipeline should be able to explain which pages were processed, which extraction method produced a block, and which blocks support a final statement.</p>
<h2>Conclusion</h2>
<p>A good PDF-to-AI feed summary depends on document fidelity. Validate and version the file, inventory pages, route scans to OCR, reconstruct layout, preserve tables and captions, normalize into page-aware evidence blocks, and summarize hierarchically.</p>
<p>When extraction quality and coverage remain visible, the model can compress a long document without pretending the source was simpler than it was. Readers receive a concise briefing and retain a reliable path back to the exact page, section, table, or figure behind each important point.</p>
]]></content:encoded>
    </item>
    <item>
      <title>Designing an Article Summarizer API: Inputs, Outputs, and Quality Controls</title>
      <link>https://feedsummary.com/blog/article-summarizer-api-design/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/article-summarizer-api-design/</guid>
      <pubDate>Fri, 16 May 2025 12:00:00 +0000</pubDate>
      <description>Design an article summarizer API with stable inputs, structured outputs, citations, length controls, and transparent failure modes.</description>
      <category>Data Pipelines</category><category>Article Summarization</category><category>API Design</category><category>OpenAPI</category>
      <content:encoded><![CDATA[<p>An article summarizer API is easy to sketch and difficult to make dependable. A minimal endpoint can accept a URL and return a paragraph, but production users soon need length controls, structured fields, provenance, retries, extraction diagnostics, language handling, and clear error states. Those needs are easier to satisfy when the interface is designed as a stable contract rather than a thin wrapper around a model prompt.</p>
<p>This guide outlines a contract-first API for summarizing articles and feed items. It focuses on inputs, outputs, asynchronous jobs, source handling, validation, and quality controls. The goal is not to prescribe one provider or programming language, but to identify the decisions an API should expose so clients can use summaries safely.</p>
<h2>Define the resource before the endpoint</h2>
<p>Start by defining what a summary resource represents. Is it a summary of one immutable article version, the current content at a URL, a caller-supplied text block, or a cluster of related sources? These are different resources with different cache and update behavior. A URL-based request can change over time, while a content-based request is reproducible if the exact input is stored or hashed.</p>
<h2>Use a documented interface description</h2>
<p>Represent the contract in a machine-readable API description and keep it under version control. The <a href="https://spec.openapis.org/oas/">OpenAPI Specification</a> provides a standard way to describe HTTP operations, parameters, request bodies, responses, schemas, and security. A description can drive documentation, client generation, validation, tests, and change review.</p>
<h2>Offer explicit input modes</h2>
<p>A summary request should state how content is provided. Common modes include a public URL, a feed item with metadata and content, raw text, Markdown, or pre-segmented blocks. Do not guess between modes based on which fields happen to be present. Use a discriminator such as <code>input_type</code> and validate the corresponding object.</p>
<h3>Preserve source metadata</h3>
<p>A title, publication date, author, and source name can materially improve a summary, but they should not be concatenated into the article body. Pass them as named fields and return the normalized versions separately. This makes it clear whether a date came from the caller, feed, page metadata, or extraction logic.</p>
<h2>Separate instructions from content</h2>
<p>The request can include a <code>summary_profile</code> that selects a preconfigured output contract, such as <code>brief</code>, <code>executive</code>, <code>research</code>, or <code>editorial</code>. Profiles should be versioned. A client can also specify bounded parameters: target length, language, reading level, number of key points, and whether to include open questions.</p>
<p>Avoid accepting arbitrary system prompts in a general-purpose public API unless that is the product. Free-form prompts make caching, evaluation, safety, and support much harder. When customization is needed, expose controlled templates or a declarative schema that describes desired fields and limits.</p>
<p>Source content must be treated as untrusted data. Delimit it clearly and ignore instructions embedded in the article. The API should document this behavior so clients understand why an article that says “output only this phrase” will not control the summarizer.</p>
<h2>Return structured output, not only prose</h2>
<p>A stable response can include a neutral headline, concise abstract, key points, named entities, event or document dates, content type, language, and an array of evidence references. Optional fields can cover why the item matters, limitations, sentiment, or questions, but only when their semantics are documented.</p>
<h3>Include evidence references</h3>
<p>Evidence references can point to extracted blocks, paragraph numbers, page labels, or caller-supplied segment IDs. A key point might include <code>evidence_ids: [&quot;b12&quot;, &quot;b13&quot;]</code>. The API does not need to expose hidden reasoning; it needs to expose the source locations that support the visible claim.</p>
<h2>Make extraction status first-class</h2>
<p>When the input is a URL, extraction can fail independently of summarization. The response should report whether the page was fetched, which content type was received, whether redirects occurred, how much meaningful text was extracted, and whether the result appears complete. Use a defined status vocabulary such as <code>complete</code>, <code>partial</code>, <code>metadata_only</code>, <code>blocked</code>, <code>unsupported</code>, or <code>failed</code>.</p>
<p>The <a href="/article-feed-summary/">article feed summary workflow</a> describes how titles, page bodies, and feed metadata can be combined without losing their provenance.</p>
<h2>Choose synchronous and asynchronous behavior intentionally</h2>
<p>Short text can often be processed synchronously, but URL retrieval, PDF extraction, batch requests, and long documents may exceed practical request timeouts. Support an asynchronous job resource when processing may take longer. A create request can return <code>202 Accepted</code>, a job ID, state, and status URL.</p>
<p>Define states such as <code>queued</code>, <code>fetching</code>, <code>extracting</code>, <code>summarizing</code>, <code>verifying</code>, <code>completed</code>, <code>completed_with_warnings</code>, and <code>failed</code>. Include timestamps and a machine-readable failure object. Webhooks can notify clients, but polling should remain available and idempotent.</p>
<p>For batch endpoints, return per-item results and errors rather than failing the entire batch because one URL is invalid. Preserve caller item IDs so responses can be matched even if processing completes out of order.</p>
<h2>Design idempotency and caching</h2>
<p>A client retry should not create duplicate jobs or charges. Accept an idempotency key for creation operations and define its scope and retention. For content-based requests, a cache key can include the normalized content hash, summary profile version, output language, and model configuration.</p>
<h2>Use explicit versioning</h2>
<p>Version the API path or media type for breaking contract changes. Also version summary profiles and processing configuration separately. An API version tells the client which fields exist; a profile version tells the client which editorial instructions and output semantics were used.</p>
<h2>Build a clear error model</h2>
<p>Use HTTP status codes consistently, then add a structured error body with a stable code, human-readable message, affected field, retryability, and optional documentation reference. Examples include <code>invalid_url</code>, <code>unsupported_media_type</code>, <code>source_too_large</code>, <code>fetch_blocked</code>, <code>extraction_empty</code>, <code>schema_validation_failed</code>, and <code>rate_limit_exceeded</code>.</p>
<p>Distinguish client errors from transient service failures. A blocked private network address is not retryable; a temporary upstream timeout may be. Clients need this distinction to avoid retry storms. For asynchronous jobs, preserve terminal error details at the job resource.</p>
<p>Warnings belong in successful or partial responses and should also have codes. A summary based on a short excerpt, an ambiguous date, or low extraction coverage may still be useful if the limitation is visible.</p>
<h2>Add security controls at the source boundary</h2>
<p>URL fetching creates server-side request risks. Resolve and validate destinations, block private and link-local networks, limit redirects, restrict protocols, cap response size, and apply timeouts. Recheck resolved addresses after redirects and consider DNS rebinding defenses. Do not fetch arbitrary file schemes or local resources.</p>
<p>Sanitize HTML, disable unsafe XML features, and process complex formats in constrained environments. Rate-limit by client and by destination host. A malicious caller should not be able to use the API as a high-volume crawler or internal network proxy.</p>
<p>Treat article content as untrusted input for the model and renderer. Escape output appropriately, strip active markup, and validate structured responses before returning them. Authentication and authorization should separate read, create, batch, and administrative capabilities.</p>
<h2>Protect privacy and retention choices</h2>
<p>Document whether submitted text, fetched pages, outputs, and logs are stored, for how long, and for what purpose. Offer a no-retention or customer-managed storage mode when appropriate. Avoid placing full article text in routine logs or error messages.</p>
<p>Provide deletion behavior for stored source and summary resources. If a summary is cached across clients, ensure the content and licensing model permit that reuse. Return a <code>retention_expires_at</code> field when it helps clients understand lifecycle behavior.</p>
<h2>Measure quality with API-visible signals</h2>
<p>Expose useful diagnostics without pretending to produce a universal confidence score. Signals can include extraction coverage, number of source blocks, language detection confidence, duplicate content ratio, and whether deterministic verification checks passed.</p>
<p>Internally, evaluate factual support, field completeness, compression, readability, and schema validity on a representative corpus. Track these metrics by input type, source domain, language, and summary profile. Averages can hide a parser that fails consistently on one publisher.</p>
<p>The API can accept optional client feedback tied to a summary ID and field. Use a bounded taxonomy such as <code>missing_fact</code>, <code>unsupported_claim</code>, <code>wrong_entity</code>, <code>wrong_date</code>, <code>too_long</code>, or <code>unclear</code>. Free-form notes can supplement the category, but structured feedback is easier to analyze.</p>
<h2>Provide a useful response envelope</h2>
<p>A strong response envelope might contain <code>id</code>, <code>status</code>, <code>created_at</code>, <code>source</code>, <code>extraction</code>, <code>summary</code>, <code>evidence</code>, <code>warnings</code>, and <code>processing</code>. Keep nested objects cohesive. Avoid mixing transport metadata with summary fields or returning the same value under several names.</p>
<p>Include links to the resource, source record, evidence, and job status when using a hypermedia style. Pagination and batch result ordering should be explicit. Every timestamp should declare a time zone, and every enum should be documented.</p>
<h2>Test the contract, not just the implementation</h2>
<p>Generate validation tests from the API description, but add behavioral tests for idempotency, retries, redirects, partial extraction, batch isolation, and version changes. Maintain golden examples for each summary profile and verify that required fields remain supported by evidence.</p>
<h2>Conclusion</h2>
<p>A dependable article summarizer API exposes the decisions clients need to understand and control. Define the summary resource, support explicit input modes, separate extraction from generation, return structured fields and evidence, provide asynchronous jobs for long work, and make errors and warnings machine-readable.</p>
<p>With a documented contract and stable versions, clients can build briefing tools, feed processors, research systems, and editorial workflows without depending on hidden prompt behavior. The API becomes an observable content service rather than a black-box paragraph generator.</p>
]]></content:encoded>
    </item>
    <item>
      <title>News API Feed Summary Pipelines: From Query to Briefing</title>
      <link>https://feedsummary.com/blog/news-api-summary-pipeline/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/news-api-summary-pipeline/</guid>
      <pubDate>Tue, 21 Jan 2025 12:00:00 +0000</pubDate>
      <description>Plan a news API feed summary pipeline that retrieves relevant articles, groups duplicate coverage, and produces traceable daily briefings.</description>
      <category>Data Pipelines</category><category>News API</category><category>Briefings</category><category>Deduplication</category>
      <content:encoded><![CDATA[<p>A news API can deliver thousands of results for a broad query, but volume is not the same as a useful briefing. The value comes from a pipeline that defines the monitoring question, retrieves a controlled result set, removes duplicate coverage, ranks novelty, and keeps every generated statement connected to source records. Without those stages, an automated news summary tends to amplify repeated stories and bury the developments that actually changed.</p>
<p>This guide presents a practical pipeline from query design to briefing delivery. It applies to commercial news APIs, publisher APIs, internal content indexes, and search endpoints that return structured article metadata. The examples are conceptual so the architecture can be adapted to different providers and editorial policies.</p>
<h2>Begin with a monitoring specification</h2>
<p>Write the monitoring goal as an operational specification rather than a loose keyword list. Define the entities, topics, geographies, languages, source types, exclusions, freshness window, and delivery cadence. State what qualifies as a material development. A product launch, regulatory filing, rumor, opinion column, and minor page update should not automatically receive the same priority.</p>
<h2>Understand the provider’s result model</h2>
<p>Review endpoint behavior before building downstream logic. The <a href="https://newsapi.org/docs">News API documentation</a> is one example of a provider describing query parameters, response fields, endpoints, and access requirements. Other services vary in source coverage, historical depth, language support, pagination, ranking, and licensing. Map the provider’s fields into your own neutral source record instead of letting one vendor’s schema become the permanent application model.</p>
<h2>Design queries for recall and precision</h2>
<p>Broad queries improve recall but increase noise. Narrow queries improve precision but can miss new terminology. Use a query set rather than one expression: exact entity names, common abbreviations, product names, executive names, and important topic combinations. Include exclusions for ambiguous terms and unrelated meanings.</p>
<h3>Separate discovery from ranking</h3>
<p>The retrieval stage should collect plausible candidates; the ranking stage should decide which candidates matter. Mixing those responsibilities into one opaque relevance score makes tuning difficult. Keep provider ranking as one feature, then add your own signals such as entity confidence, source type, freshness, geographic match, topic match, and novelty.</p>
<p>A two-stage approach allows you to widen discovery without flooding the final briefing. It also supports different products from the same result pool: an exhaustive research archive, a high-signal alert stream, and a concise daily digest.</p>
<h2>Normalize URLs, dates, and source names</h2>
<p>Results often contain tracking parameters, redirect URLs, inconsistent source labels, and timestamps in different zones. Preserve originals, then create normalized values. URL normalization should remove known tracking parameters and follow redirects cautiously. Source normalization can map brand variants to one display name without erasing the provider’s value.</p>
<p>Parse publication times into a standard zone and retain the original string. Do not substitute retrieval time silently. When no trustworthy publication time exists, record the limitation and use a separate <code>discovered_at</code> field. Briefings should state whether they are ordered by publication or discovery.</p>
<h2>Enrich only when permitted and necessary</h2>
<p>If the API provides an excerpt, full-text extraction may improve summaries. Before fetching a destination page, confirm that access is permitted by your agreement and site policy. Apply timeouts, response-size limits, content-type checks, and rate controls. Store whether the summary used the API excerpt, the extracted page, or both.</p>
<p>Extraction should remove navigation, related-story modules, and repeated boilerplate while preserving headings, quotations, lists, captions, and table labels. When extraction confidence is low, route the item to a shorter metadata-only summary or manual review rather than presenting a confident full-text synthesis.</p>
<p>The <a href="/website-scraping/">website scraping workflow</a> covers policy checks and extraction controls for pages that do not expose suitable feeds or APIs.</p>
<h2>Deduplicate exact copies and cluster related coverage</h2>
<p>Exact duplicate detection can use canonical URLs, provider IDs, and content hashes. Near-duplicate detection needs additional signals: normalized titles, shared quotations, overlapping lead paragraphs, and semantic similarity. Keep the member records inside a cluster instead of deleting them, because source diversity and publication order may matter.</p>
<p>Related coverage is broader than duplication. Several outlets may report the same event with different interviews, local details, or analysis. Cluster them under one event while preserving article-level distinctions. The cluster should have a time range, entity set, representative title, and member source IDs.</p>
<h3>Avoid counting syndication as consensus</h3>
<p>Ten copies of one wire story do not represent ten independent confirmations. Record likely syndication relationships and repeated text. A summary may say that a report was widely republished, but it should not convert repetition into independent corroboration.</p>
<p>Conversely, do not collapse genuinely different developments simply because they share an entity. A company’s earnings release, executive interview, and product recall may occur on the same day but require separate clusters. Combine semantic similarity with event type and time.</p>
<h2>Rank novelty, importance, and confidence separately</h2>
<p>A single relevance score hides useful distinctions. Novelty asks whether the item adds information not already in the briefing. Importance asks how much the development matters to the monitoring goal. Confidence asks how strong the available evidence and extraction are. Store these as separate features, even if a final ranking formula combines them.</p>
<p>Importance rules should be explicit. Regulatory action, confirmed financial results, signed agreements, and operational incidents may rank above commentary or speculative reports. The rules differ by domain and should be reviewed by subject-matter owners. Model-based ranking can assist, but deterministic filters and source metadata remain valuable.</p>
<h2>Summarize at item and cluster levels</h2>
<p>Generate a compact item record first. Include a neutral headline, one-sentence summary, key facts, named entities, event date, content type, and source ID. Then create a cluster summary from the selected member records. The cluster output should explain the development, identify what is new, note meaningful differences among sources, and list open questions.</p>
<p>Do not ask the model to infer source independence or factual consensus without the metadata needed to support that judgment. Pass cluster membership, timestamps, source labels, and duplicate relationships explicitly. Require the output to cite internal source IDs for each key point.</p>
<h2>Handle corrections and evolving stories</h2>
<p>News changes. A result may be updated, corrected, or contradicted after the first briefing. Keep content hashes and modification signals, refetch important sources according to policy, and compare normalized text. Material changes should create a revision event that can regenerate affected summaries.</p>
<h2>Build a briefing with transparent coverage</h2>
<p>A briefing should show its time window, query scope, languages, and source limitations. Organize clusters by topic or importance, not by the order returned from the API. Each section can include a concise synthesis, source count, earliest and latest publication times, and links to the underlying records.</p>
<p>Include a “notable but uncertain” area for high-relevance items with weak evidence. Suppressing them entirely may hide emerging developments, while placing them in the main list may overstate confidence. Explicit uncertainty is more useful than pretending every selected item has the same status.</p>
<p>The <a href="/news-api-feed-summary/">news API feed summary page</a> offers sample fields for daily, weekly, and event-driven briefings.</p>
<h2>Evaluate against editorial outcomes</h2>
<p>Create a test corpus from real monitoring periods. Label which stories were material, which were duplicates, which clusters should have formed, and which facts belonged in the final briefing. Evaluate retrieval recall, false-positive rate, cluster quality, source diversity, factual support, and reader usefulness.</p>
<p>Review errors by stage. A missing story may be a query problem, provider-coverage problem, ranking problem, or timing problem. A wrong summary may originate in extraction or clustering rather than generation. Stage-specific diagnosis prevents endless prompt tuning for failures caused upstream.</p>
<h2>Operate within rate, cost, and licensing limits</h2>
<p>APIs impose request quotas, pagination rules, and usage terms. Schedule queries to match the briefing need and use incremental windows with overlap to avoid gaps. Cache responses where allowed, deduplicate before full-text extraction, and summarize only candidates that survive initial filters.</p>
<p>Track cost per retrieved candidate, accepted item, cluster, and delivered briefing. These ratios reveal where resources are spent. A large increase in candidates with no increase in useful clusters may indicate a query drift or provider change.</p>
<p>Licensing and attribution requirements should be modeled as data. Store the source display name, original URL, and any required notice with the article record so the rendering layer can comply consistently.</p>
<h2>A staged implementation plan</h2>
<p>Start with one narrow topic, one language, and a daily schedule. Retrieve results, preserve raw responses, normalize fields, and build a manual review table. Add deterministic deduplication and item summaries. Once reviewers understand the error patterns, introduce event clustering and cluster-level synthesis.</p>
<p>Next, add source enrichment, importance rules, and revision handling. Create a benchmark briefing period and run regression tests when queries, providers, models, or prompts change. Only after the system can explain why an item was retrieved and how a statement was supported should it send unattended alerts.</p>
<h2>Conclusion</h2>
<p>A news API is the discovery layer, not the finished intelligence product. Useful feed summaries require a monitoring specification, provider-neutral records, explicit query logic, careful enrichment, duplicate-aware clustering, separate novelty and importance signals, and traceable synthesis.</p>
<p>When those components are visible and testable, the same pipeline can support fast alerts, daily briefings, research archives, and editorial dashboards without turning a large result set into an unreviewable stream of generated prose.</p>
]]></content:encoded>
    </item>
    <item>
      <title>RSS vs Atom vs JSON Feed for AI Summarization Pipelines</title>
      <link>https://feedsummary.com/blog/rss-atom-json-feed-comparison/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/rss-atom-json-feed-comparison/</guid>
      <pubDate>Sun, 03 Nov 2024 12:00:00 +0000</pubDate>
      <description>A developer-focused comparison of RSS, Atom, and JSON Feed for ingestion, normalization, and AI feed summary systems.</description>
      <category>Feed Formats</category><category>RSS</category><category>Atom</category><category>JSON Feed</category>
      <content:encoded><![CDATA[<p>RSS, Atom, and JSON Feed all move collections of entries from publishers to subscribers, yet they make different tradeoffs around metadata, extensibility, content representation, and parser complexity. For an AI summarization pipeline, the best format is not necessarily the newest or the easiest to read. The important question is which format delivers stable identity, enough source context, and predictable content for the publishers you need to monitor.</p>
<p>This comparison focuses on downstream work: discovery, parsing, normalization, deduplication, extraction, and summary generation. A robust system should accept all three formats and convert them into one internal record model, but understanding their differences helps you avoid losing information during that conversion.</p>
<h2>The shared job of a web feed</h2>
<p>All three formats describe a feed and a sequence of items. A feed usually has a title, a home-page link, an update time or description, and entries with titles, links, identifiers, dates, authors, and content. Consumers retrieve the document periodically or through an update mechanism, compare entries with prior state, and process what is new or changed.</p>
<p>That shared shape makes normalization possible. An internal item can have fields such as <code>source_feed_url</code>, <code>item_id</code>, <code>canonical_url</code>, <code>title</code>, <code>summary</code>, <code>content_blocks</code>, <code>authors</code>, <code>published_at</code>, <code>modified_at</code>, <code>tags</code>, and <code>attachments</code>. The parser’s job is to map source fields into those slots without erasing the original representation.</p>
<h2>RSS: broad adoption with flexible conventions</h2>
<p>RSS 2.0 is widely published and supported. Its basic structure is straightforward, and many sites expose an RSS feed even when they provide no other syndication format. For a summary system, that coverage is a major advantage. A perfect format is not useful if the sources you monitor do not publish it.</p>
<h3>RSS strengths for summarization</h3>
<p>RSS is a good default when source availability matters most. It commonly provides enough metadata to identify an article, order it by time, and fetch the linked page when the feed contains only an excerpt. Its extension ecosystem can carry full content, media, podcast enclosures, and categories.</p>
<p>The challenge is distinguishing a true absence from a publisher-specific location. A generic XML parser may read the document but miss full content stored in a namespaced element. A feed-aware parser should retain unknown namespaced fields, emit warnings, and avoid collapsing <code>description</code>, full content, and media descriptions into one value.</p>
<h2>Atom: stricter identity and explicit semantics</h2>
<p>Atom was designed as a standards-track syndication format with more explicit rules for identifiers, links, content types, authors, and update times. An Atom entry requires an identifier and an updated timestamp, and links carry relation and media-type attributes. Content can be text, HTML, XHTML, or referenced externally, with the representation declared rather than guessed.</p>
<p>The normative definition is <a href="https://www.rfc-editor.org/info/rfc4287/">RFC 4287, The Atom Syndication Format</a>. For an AI pipeline, Atom’s explicit semantics can reduce ambiguity. A parser can distinguish the alternate page link from self links or related resources, and it can process content according to its declared type.</p>
<h3>Atom strengths for summarization</h3>
<p>Stable IDs and required update times make change tracking more predictable. Typed content helps prevent accidental double escaping or unsafe HTML handling. Multiple links can be preserved with their relationship, which is useful when an entry points to a web page, a source document, and an enclosure.</p>
<h2>JSON Feed: familiar structures for application developers</h2>
<p>JSON Feed expresses feed data as JSON rather than XML. Its top-level object describes the feed, and the <code>items</code> array contains entries with IDs, URLs, titles, content, summaries, dates, authors, tags, and attachments. For teams already using JSON APIs, the format can be easier to inspect, validate, and integrate.</p>
<p>JSON syntax does not eliminate content ambiguity, but the format offers clear fields for <code>content_html</code> and <code>content_text</code>. A consumer can choose the richer representation and retain the other. Dates use ISO-style strings, which are generally convenient for modern application stacks. Attachments are structured objects rather than XML extensions.</p>
<h3>JSON Feed strengths for summarization</h3>
<p>The mapping from a JSON Feed item to an internal record is often direct. IDs are required, content fields are explicit, and nested arrays for authors and attachments fit naturally into common data models. Tooling for JSON schema validation, logging, and debugging is familiar to many engineering teams.</p>
<h2>Discovery and content negotiation</h2>
<p>Feed discovery commonly begins with HTML <code>link</code> elements in a page head. RSS and Atom have established media types, and JSON Feed uses a JSON feed media type while some implementations still serve generic JSON. Store the advertised type, the response Content-Type, and the parsed format because they do not always agree.</p>
<h2>Identity and update tracking</h2>
<p>Identity is central to summarization because a repeated item should not create a new briefing entry. Atom and JSON Feed require item IDs, while RSS permits more variation. Even with required IDs, publishers can change values during migrations. Keep a source-scoped ID and supplement it with canonical URLs and content fingerprints.</p>
<p>Track publication and modification separately. An item updated for a spelling correction should not be treated like a new story, while a substantial revision may deserve a new alert or regenerated summary. Store the previous content hash and compare normalized blocks to determine whether the change is material.</p>
<h2>Content representation and sanitization</h2>
<p>RSS descriptions and extension fields often contain HTML fragments. Atom explicitly declares text, HTML, or XHTML. JSON Feed separates HTML and text content. Regardless of format, sanitize active content, resolve relative URLs against the appropriate base, and convert the result into structured blocks before summarization.</p>
<p>Avoid reducing everything to plain text too early. Headings, lists, quotations, code, and table labels guide chunking and improve summary accuracy. Preserve alternative text for meaningful images and record enclosure metadata. When a feed provides only an excerpt, mark it as such so the summary does not imply full-article coverage.</p>
<h2>Authors, tags, and attachments</h2>
<p>RSS author fields may contain email-oriented values or use extensions for richer names. Atom supports person constructs with names and optional details. JSON Feed uses author objects. Normalize authors into a list of display names and source fields, but do not infer identity across feeds solely from a shared name.</p>
<h2>Error handling and parser behavior</h2>
<p>XML feeds require defenses against unsafe entity expansion and extreme nesting. JSON feeds require depth, size, and type validation. Both can include malformed or unexpected values. A production parser should return a partial record plus warnings when safe recovery is possible, and a clear failure state when it is not.</p>
<h2>Performance and storage implications</h2>
<p>For typical feeds, network latency dominates parse time. Format choice rarely determines overall system cost. More important factors include polling frequency, full-page extraction, model calls, and duplicate processing. Conditional requests and content hashes reduce unnecessary work across all formats.</p>
<p>Store raw payloads according to policy, but avoid duplicating large unchanged documents. A source-level hash can identify an unchanged feed, while item hashes identify updated entries. Normalized records should be versioned so parser improvements can be tested against historical payloads without refetching the web.</p>
<h2>Which format should a publisher choose?</h2>
<p>A publisher seeking maximum compatibility will usually offer RSS or Atom, and may add JSON Feed for developer convenience. Atom is attractive when explicit semantics and standards-based identity are priorities. JSON Feed is attractive when the publishing stack and audience are strongly JSON-oriented. Providing more than one format is reasonable if the variants are generated from the same canonical content model.</p>
<p>Publishers should prioritize stable IDs, correct canonical links, reliable dates, complete author data, and a clear distinction between summary and full content. These qualities matter more to downstream summarization than cosmetic format preferences. Document the feed’s update behavior and keep old URLs redirecting when possible.</p>
<h2>Which format should a consumer prefer?</h2>
<p>A consumer should accept the format the source publishes most reliably. When multiple variants exist, score them on content completeness, metadata quality, stability, and update behavior. Do not globally prefer JSON or Atom without testing the specific source. A publisher’s RSS feed may be fuller and better maintained than its newer alternative.</p>
<p>The <a href="/feed-formats/">feed formats hub</a> provides individual implementation pages for RSS, Atom, JSON Feed, and Markdown normalization. In a multi-format system, each parser should produce the same internal record schema and the same warning vocabulary so downstream summarization does not need format-specific branches.</p>
<h2>A normalization checklist</h2>
<p>For every parsed item, confirm that you can answer: What is the source format? Which field supplied the ID? Which link is canonical? Are publication and modification dates distinct? Is the selected content full text or an excerpt? Which authors and tags were present? Were attachments included? Did parsing produce warnings?</p>
<p>Then verify that raw fields remain available, normalized values include provenance, and content blocks preserve structure. This checklist turns format differences into explicit mapping decisions rather than hidden parser behavior.</p>
<h2>Conclusion</h2>
<p>RSS offers broad reach, Atom offers explicit semantics, and JSON Feed offers a developer-friendly representation. None automatically guarantees better summaries. The quality of an AI feed summary depends on stable identity, complete metadata, preserved content structure, and transparent normalization.</p>
<p>Support all three where practical, retain raw payloads, map them into one internal schema, and choose per source based on observed quality. A format-neutral pipeline lets the summarization layer focus on evidence and meaning instead of the syntax that delivered the entry.</p>
]]></content:encoded>
    </item>
    <item>
      <title>RSS Feed Summary: A Practical Guide to Parsing, Cleaning, and Condensing Feeds</title>
      <link>https://feedsummary.com/blog/rss-feed-summary-guide/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/rss-feed-summary-guide/</guid>
      <pubDate>Thu, 27 Jun 2024 12:00:00 +0000</pubDate>
      <description>A step-by-step RSS feed summary guide covering discovery, parsing, normalization, deduplication, extraction, and summary quality checks.</description>
      <category>Feed Formats</category><category>RSS</category><category>Feed Parsing</category><category>AI Summarization</category>
      <content:encoded><![CDATA[<p>RSS is a compact transport format, but a dependable RSS feed summary still requires more than reading the title and description fields. Feeds vary in how they identify entries, represent dates, encode HTML, expose full content, and point to canonical pages. A summarization pipeline must preserve those distinctions before it can safely condense the material for a reader.</p>
<p>This guide follows an RSS item from discovery through final briefing output. It covers feed retrieval, XML parsing, content selection, article extraction, deduplication, summary generation, and quality control. The same sequence can be adapted to Atom and JSON Feed, but RSS has enough implementation variation that explicit normalization rules are especially valuable.</p>
<h2>Discover the intended feed URL</h2>
<p>A site may publish several feeds: a global feed, category feeds, author feeds, podcast feeds, or localized versions. Begin with an explicitly supplied URL whenever possible. If discovery is required, inspect HTML <code>link</code> elements that advertise RSS or Atom resources, then validate the returned content type and document root rather than trusting a filename such as <code>feed.xml</code>.</p>
<h2>Parse XML defensively</h2>
<p>Use a parser designed for XML rather than regular expressions. Disable unsafe external entity behavior, enforce reasonable document-size limits, and handle character encoding explicitly. Real-world feeds may contain namespaces, CDATA sections, embedded HTML, invalid control characters, or minor structural errors. A tolerant parser can recover useful entries, but it should emit warnings instead of silently pretending the document was fully valid.</p>
<p>The <a href="https://www.rssboard.org/rss-specification">RSS 2.0 specification</a> describes the channel and item elements that publishers can provide. In practice, your parser should also be prepared for common extension namespaces. Keep unknown fields in the raw record even if the current summary workflow does not use them; future processing may benefit from media metadata, content modules, or source-specific identifiers.</p>
<h3>Preserve the original item record</h3>
<p>For every item, store the raw identifier, link, title, description, full-content field when present, author, categories, publication date, and enclosure metadata. Do not overwrite one field with another during normalization. Instead, create derived fields such as <code>normalized_title</code>, <code>canonical_url</code>, and <code>selected_content</code> while retaining the source values.</p>
<h2>Establish a stable item identity</h2>
<p>RSS allows an item to contain a <code>guid</code>, but publishers use that field differently. Some values are URLs; others are opaque strings; some change when an article is edited. Build identity from a prioritized set of signals rather than one assumption. Prefer a stable nonempty GUID, then a canonicalized link, and finally a conservative fingerprint based on source, normalized title, and publication time.</p>
<p>Avoid using the title alone. Headlines are edited, reused, and occasionally blank. URL normalization should remove obvious tracking parameters while preserving parameters that select real content. Keep the original link, normalized link, and any canonical URL discovered on the destination page so duplicate detection can be revised without losing evidence.</p>
<h3>Handle publication and modification dates separately</h3>
<p>A feed may provide no date, a publication date, an update date, or an ambiguous local time. Parse dates into a standard time zone while preserving the original string and the parser’s confidence. Never substitute retrieval time for publication time without labeling the substitution. A briefing sorted by a guessed date can surface old content as new.</p>
<p>When an item reappears with the same identity and changed content, record it as a revision. Decide whether the briefing should show the update, replace the prior summary, or create an alert only when material facts changed. This behavior should be a product rule, not an accidental consequence of the database upsert.</p>
<h2>Choose the best available content</h2>
<p>Many RSS feeds include only a teaser. Others include full HTML in a namespaced content field, while some repeat the same text in several fields. Create a transparent selection policy. For example: prefer a sufficiently long full-content field; otherwise use the description; if both are short and the destination is permitted, fetch and extract the linked article.</p>
<p>Do not assume longer always means better. Full-content fields may contain navigation, sponsorship messages, image captions without images, or duplicated paragraphs. Clean the selected content and measure meaningful text length after removing boilerplate. Keep a flag showing whether the summary used feed content, page content, or a combination.</p>
<p>The <a href="/article-feed-summary/">article feed summary page</a> covers destination-page extraction in more depth. The important RSS principle is to treat fetching the article as an enrichment step, not as a replacement for the feed record. The feed often supplies the most reliable publication metadata even when the page supplies the most complete body text.</p>
<h2>Normalize HTML into structured blocks</h2>
<p>Descriptions and content fields frequently contain HTML. Sanitize it, resolve relative URLs, and convert meaningful elements into ordered blocks. Headings, paragraphs, list items, quotations, code, and tables should remain distinguishable. Remove scripts, styles, hidden elements, repeated social buttons, and empty containers.</p>
<h2>Detect duplicates and syndicated copies</h2>
<p>First remove exact duplicates within the same feed by item identity and content hash. Then compare canonical URLs and normalized titles across feeds. Near-duplicate detection can use text fingerprints or semantic similarity, but set thresholds carefully: two updates about the same event are related, not necessarily interchangeable.</p>
<h2>Define the summary output before prompting</h2>
<p>A useful item summary usually needs more structure than one paragraph. Consider fields such as <code>headline</code>, <code>one_sentence_summary</code>, <code>key_points</code>, <code>entities</code>, <code>event_date</code>, <code>content_type</code>, and <code>source_id</code>. For an editorial workflow, add <code>why_it_matters</code> and <code>questions_to_verify</code>. For a research workflow, add methods, findings, limitations, and cited documents.</p>
<h3>Use the feed title and description as context, not truth</h3>
<p>The channel title, item title, and description are valuable signals, but they may be promotional or incomplete. Ask the summary process to compare them with the selected body content. If the headline overstates what the article supports, the summary should follow the body and can note the mismatch for review.</p>
<p>Likewise, categories may be publisher-specific labels rather than universal taxonomy. Normalize them only after preserving the originals. A mapping table can group “AI,” “Artificial Intelligence,” and “Machine Learning” for navigation while keeping the source category available for traceability.</p>
<h2>Verify summary facts against the item</h2>
<p>Automated checks should confirm that every summary references an existing source record and that structured fields match the expected schema. Extract numbers, dates, currencies, and named entities from the summary, then look for corresponding evidence in the normalized content. A missing match does not always prove an error, but it is a strong review signal.</p>
<p>Human review should display the summary beside the exact content used, not merely the live article page, which may have changed. Highlight evidence blocks for key facts when possible. Reviewers can then correct the output and classify the failure as extraction, grouping, prompting, or model behavior.</p>
<h2>Build a useful briefing layer</h2>
<p>Item summaries become more valuable when grouped by topic, source, or time window. A briefing should state its coverage period and source scope. Within each section, rank items by relevance and novelty rather than publication count. Include links to internal item records or original pages and show publication times in a consistent zone.</p>
<p>Avoid creating a second summary that simply repeats every item summary. Cluster-level synthesis should explain what changed, where sources agree, and which questions remain open. Preserve the ability to expand from the synthesis to each item. The <a href="/rss-feed-summary/">RSS feed summary hub</a> outlines common briefing formats for monitoring, research, and editorial teams.</p>
<h2>Monitor feed health over time</h2>
<p>Track successful retrievals, response times, item counts, parse warnings, date failures, content length, and duplicate rate per feed. Alerts should focus on meaningful changes: a feed returning HTML, a sudden drop to zero items, repeated stale timestamps, or a large shift from full content to excerpts.</p>
<p>Use conditional requests with ETags and Last-Modified headers when supported, and respect reasonable polling intervals. Backoff prevents a temporary server error from becoming unnecessary load. Store the last successful retrieval separately from the last attempt so operations staff can see whether a feed is stale or simply quiet.</p>
<h2>Implementation checklist</h2>
<p>A production-ready RSS summary workflow should be able to answer these questions: Which feed URL produced this record? What was the raw item identifier? Which content field was selected, and why? Was the linked page fetched? How was the canonical URL determined? Which records were treated as duplicates? Which prompt and model version created the summary? Which evidence supports each important fact?</p>
<p>If any answer is unavailable, improve the data model before increasing automation. Good summaries are the visible end of a chain of decisions. Capturing those decisions makes the system easier to test, correct, and scale.</p>
<h2>Conclusion</h2>
<p>RSS is simple enough to start quickly and variable enough to reward disciplined engineering. Preserve raw records, establish stable identity, normalize dates and HTML carefully, enrich from destination pages only when needed, and deduplicate before synthesis. Then request structured summaries and verify them against the exact content used.</p>
<p>With that foundation, an RSS feed summary can remain concise without becoming opaque. Readers get a fast briefing, while operators retain the metadata and evidence required to understand how every line was produced.</p>
]]></content:encoded>
    </item>
    <item>
      <title>How to Build an AI Feed Summary Workflow That Preserves Context</title>
      <link>https://feedsummary.com/blog/ai-feed-summary-workflow/</link>
      <guid isPermaLink="true">https://feedsummary.com/blog/ai-feed-summary-workflow/</guid>
      <pubDate>Wed, 14 Feb 2024 12:00:00 +0000</pubDate>
      <description>Design an AI feed summary pipeline that keeps source context, separates facts from inference, and produces useful briefings instead of generic blurbs.</description>
      <category>AI Summarization</category><category>AI Summarization</category><category>RSS</category><category>Prompt Engineering</category>
      <content:encoded><![CDATA[<p>An AI feed summary workflow is not simply “send every item to a model and ask for a shorter version.” A useful system has to preserve identity, time, source context, and the difference between what an article states and what the system infers. When those details disappear, a digest may sound polished while becoming harder to trust, search, or act on. The strongest workflows therefore treat summarization as one stage in a larger content pipeline.</p>
<p>This guide describes a practical architecture for teams that monitor RSS, Atom, JSON Feed, news APIs, documents, or scraped pages. It focuses on the decisions that matter before and after a model call: what to collect, how to normalize it, when to group related items, which summary format to request, and how to keep a human-readable path back to the evidence.</p>
<h2>Start with the briefing decision, not the model</h2>
<p>Before choosing a model or prompt, define the decision the summary will support. A morning editorial briefing, a product-monitoring alert, a research review, and an executive digest may use the same sources but require different levels of detail. The output contract should specify audience, cadence, topic boundaries, desired length, and the actions a reader should be able to take after reading it.</p>
<h3>Define the unit of summarization</h3>
<p>Decide whether the system summarizes one item, one topic cluster, one source over a period, or an entire briefing window. Item summaries are straightforward but repetitive when ten publishers cover the same announcement. Cluster summaries reduce duplication but require stronger identity and grouping logic. Period summaries can reveal change over time, yet they also need a clear cutoff so older context is not mistaken for new information.</p>
<p>For most monitoring systems, a two-layer design works well: create a compact record for each item, then produce a second summary for each cluster or briefing section. The item record remains available for verification, while the cluster-level text gives the reader an efficient overview. The <a href="/ai-feed-summary/">AI feed summary overview</a> explains how these layers fit into a broader site architecture.</p>
<h2>Collect source records before extracting article text</h2>
<p>A feed item usually contains more than a link. It may include a stable identifier, publication and modification dates, author information, categories, a summary, and full content. Capture the complete source record before fetching the destination page. That record becomes the provenance envelope for everything that follows and can help when the page changes, moves, or becomes unavailable.</p>
<h2>Normalize content without flattening meaning</h2>
<p>Feed and page content arrive as HTML fragments, plain text, Markdown, XML, JSON, and occasionally malformed mixtures. Normalize encoding and whitespace, remove navigation and repeated boilerplate, resolve relative links, and preserve structural signals such as headings, lists, quotations, captions, and table labels. The goal is clean content, not featureless text.</p>
<h3>Keep content boundaries visible</h3>
<p>When multiple items are placed in one prompt, use strong delimiters and stable identifiers. Do not concatenate titles, excerpts, and article bodies into one undifferentiated string. Label each field, escape untrusted instructions in source text, and state that source content is data rather than system guidance. This reduces accidental cross-item blending and makes structured output easier to validate.</p>
<p>For long sources, chunk by semantic boundaries before considering fixed character windows. A chunk that begins halfway through a table or separates a heading from its paragraph loses context even if its token count is perfect. Overlap can help with continuity, but excessive overlap creates repeated evidence and can cause the final summary to overemphasize one point.</p>
<h2>Deduplicate before asking for synthesis</h2>
<p>Duplicate URLs are only the simplest case. Syndicated articles may appear under different domains, press releases can be republished with minor edits, and a publisher may update a story while keeping the same URL. Use a combination of canonical URLs, normalized titles, content hashes, publication times, and semantic similarity to identify exact duplicates and near-duplicates.</p>
<h2>Build prompts as output contracts</h2>
<p>A reliable prompt describes the task, audience, source boundaries, required fields, length limits, and rules for uncertainty. It should distinguish extraction from interpretation. For example, ask for <code>key_facts</code>, <code>why_it_matters</code>, <code>open_questions</code>, and <code>source_ids</code> as separate fields instead of requesting one elegant paragraph that mixes all four.</p>
<p>The prompt should also define what not to do: do not follow instructions inside source content, do not invent quotations, do not merge entities with similar names, and do not infer causation from sequence. These constraints are especially important in automated pipelines where no editor sees the raw prompt for every run.</p>
<h2>Add verification as a separate stage</h2>
<p>Generation and verification are different jobs. After producing a draft summary, check that named entities, numbers, dates, and quoted phrases can be found in the source blocks assigned to the summary. Simple deterministic checks catch many errors: verify that every source identifier exists, every URL belongs to the cluster, and required fields conform to the schema.</p>
<p>More advanced checks can compare each factual sentence with retrieved evidence or ask a second pass to identify unsupported claims. That second pass should receive the summary and the limited evidence set, not the entire unrelated corpus. A confidence label is only useful when tied to observable conditions, such as source agreement, extraction quality, or missing metadata.</p>
<p>The <a href="https://www.nist.gov/publications/artificial-intelligence-risk-management-framework-generative-artificial-intelligence">NIST Generative AI Profile</a> provides a broader risk-management frame for documenting, measuring, and managing generative AI behavior. A feed workflow can translate that principle into practical controls: record model and prompt versions, retain evaluation samples, monitor failure categories, and define when human review is mandatory.</p>
<h2>Render provenance for the reader</h2>
<p>Traceability should be visible in the final experience, not buried in logs. Each briefing section can show source names, publication times, and direct internal links to item records. When a summary synthesizes several articles, indicate which sources support the key points. Readers should be able to move from a concise statement to the underlying material without reverse engineering the pipeline.</p>
<p>Provenance also improves corrections. If a publisher updates an article or a feed item was parsed incorrectly, the system can identify which summaries depended on that record and regenerate only the affected output. A content hash, retrieval time, prompt version, and model version create a practical audit trail without requiring the reader to see technical metadata by default.</p>
<h2>Evaluate with a stable test set</h2>
<p>Create a representative evaluation set before tuning prompts. Include short posts, long reports, duplicate coverage, ambiguous dates, tables, opinion pieces, corrections, and sources with poor markup. Write expected facts and unacceptable errors for each case. A test set should reflect the actual briefing domain rather than generic summarization examples.</p>
<p>Score the system on coverage, attribution, contradiction handling, compression, and readability. Track failure categories separately. A summary that misses one critical number is different from one that is slightly verbose, even if both receive the same aggregate score. Human reviewers can compare versions blindly and record reasons for preference, which is more actionable than a simple thumbs-up.</p>
<p>Regression testing matters whenever the model, extraction library, prompt, or chunking strategy changes. Keep the old output, new output, evidence, and reviewer decision together. Over time, this creates a useful history of what “better” means for the organization rather than relying on intuition after each change.</p>
<h2>Operate the workflow as a system</h2>
<p>Production reliability depends on queues, retries, rate limits, and idempotency as much as on prompt quality. Give each source item and summary job a deterministic key so a retry does not create duplicates. Separate transient failures from permanent ones, and preserve partial results when extraction succeeds but summarization must be retried later.</p>
<p>Monitor volume, latency, extraction success, duplicate rate, token use, schema failures, and human correction rate. Sudden changes often reveal upstream problems: a publisher redesigned its pages, a feed began omitting full content, or a source changed time zones. Operational metrics should therefore be segmented by source and content type rather than averaged into one healthy-looking number.</p>
<h2>A practical implementation sequence</h2>
<p>Begin with a narrow set of well-formed feeds and a single briefing format. Capture complete source records, normalize content into blocks, and generate item-level structured summaries. Add a review screen that shows output beside evidence. Only after the basic path is stable should you introduce clustering, multi-source synthesis, PDF extraction, or website scraping.</p>
<p>Next, create a small evaluation set and automate deterministic checks. Add prompt and model versioning, then monitor corrections. When the workflow can explain where a sentence came from and reproduce the conditions that generated it, scale to more sources and more frequent schedules. The <a href="/prompt-library/">prompt library</a> offers reusable output-contract patterns for that stage.</p>
<h2>Conclusion</h2>
<p>An AI feed summary is trustworthy when the surrounding workflow preserves what the model alone cannot guarantee: source identity, content boundaries, time, evidence, and reviewability. Start with the briefing decision, collect immutable source records, normalize without erasing structure, deduplicate before synthesis, and treat verification as a first-class stage.</p>
<p>The result is not merely shorter text. It is a compact information product that a reader can understand quickly, trace back to its sources, and correct when the underlying world changes.</p>
]]></content:encoded>
    </item>
  </channel>
</rss>
