Summary briefing layer: Today pre-summarized, /a is the canonical read

Make summaries the core reading experience (summary-first, source-forward):
- Cycle pre-warms summaries for Today's 7 (idempotent → only new ones hit the LLM).
- /api/brief items carry their cached summary; Today cards (hero + tiles) show it
  inline, so Today reads as a calm briefing.
- Card title/image now open the /a summary page (the canonical artifact), with a
  visible "Full story" link straight to the source on every card (the escape hatch).
- /a gains related-grouping chips + a Copy-link/share control.
- Tighten the summary prompt: original, factual, no quotations / no close paraphrase.
Long tail stays lazy+cached. No article bodies stored. 129 tests pass.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
jay
2026-06-04 19:48:32 +00:00
parent 3924d927aa
commit cfde4e22db
6 changed files with 80 additions and 14 deletions
+5 -4
View File
@@ -26,10 +26,11 @@ _TAGS = re.compile(rb"<[^>]+>")
_WS = re.compile(r"\s+")
_SYSTEM = (
"You write a short, original summary of a news story for a calm, constructive news "
"site. Use your own words — never copy sentences from the source. 2 to 4 plain "
"sentences: what happened and why it's encouraging. No preamble, no markdown, no "
"headline — just the summary."
"You write a short, ORIGINAL summary of a news story for a calm, constructive news "
"site. Summarize the underlying FACTS in your own words. Do NOT quote, and do not "
"closely paraphrase the article's sentences — no lifted phrases. 2 to 4 plain "
"sentences covering what happened and why it's encouraging. No preamble, no markdown, "
"no headline, no opinion — just the factual summary."
)