Skip to content

Story timelines

A story’s page shows how the news developed: the first report, then each source that picked it up, by day (SI-553). Follow a story, and coverage that joins it later is marked new, in the stream and on its page, until you look at it again. Stories come from the dedupe stage (dedupe.md). Code: services/story-timeline.ts, the pages under routes/(app)/stories.

The timeline

Open it from a card’s +2 sources list (Story timeline at its end), from the reader’s list, or from Stories in the rail (4; on phones under Settings → Pages).

  • Items: the story’s items you can see, oldest first, grouped by the day they were published. You see what the stream would show you: from sources you follow and haven’t paused, not filtered out by the gate or muted, not split from the story. So the timeline has as many items as the card’s story size.
  • First report: the first of them. The others say how they joined: Same link (the same canonical URL) or Same story (jev’s check).
  • Coverage by source: each source, with how many of its items are in the story and when it first reported it.
  • The title is the first item’s you can see, not the one stored with the story: that one may come from a source only another user follows.

A story you see none of the items of is “not in your stream” (404).

Following a story

Follow story on its page. From then on:

  • New means an item joined the story after you last looked at its page. Following starts with nothing new.
  • The stream’s card shows “1 new” next to “+2 sources”. The card stays the story’s earliest item, as before, so a story you read already doesn’t come back in the Unread view; Stories lists it under Following, those with new coverage first.
  • Opening the story’s page marks what’s there as seen. The marks stay on the page you opened, and are gone next time.
  • Unfollow on the same page.

Following is yours alone. A follow goes when the story does.

“Joined” is when the dedupe stage put the item into the story, not when it was published: feeds backdate items, and an item can join a story a day after it was published.

Stories

Stories (/stories) lists:

  • Following: the stories you follow, those with new coverage first, then the most recently changed.
  • This week: stories two of your sources or more report, by the day their first item was published, the most covered first, at most 10 a day. Days are counted in your time zone (Settings → Costs).

Data

story_follows (user_id, story_id), followed_at, seen_at: when you last looked at the story. Cascades with the user and the story
items.story_joined_at When the item joined its story. Set by joinStory(), for the item that starts a story too. Items grouped before SI-553 got their created_at

Migration 0030_story_follows.

API

SDK
GET /api/v1/stories stories() { timeZone, followed, days: [{ date, stories }] }. Each story: { storyId, title, leadItemId, startedAt, updatedAt, size, sourceCount, unread, following, newCount }
GET /api/v1/stories/:id story(id) { storyId, title, startedAt, updatedAt, following, followedAt, seenAt, newCount, entries, sources }. Each entry: { itemId, title, url, sourceId, sourceTitle, sourceSiteUrl, publishedAt, joinedAt, match, readAt, starredAt, summary, first, isNew }. Changes nothing. 404 when you see none of its items
PATCH /api/v1/stories/:id { following?, seen? } updateStory(id, patch) Follows the story or stops; seen: true says you looked at it, and changes nothing for a story you don’t follow. Answers { following }. 404 when you follow or unfollow a story you see none of the items of

Stream items and GET /api/v1/items/:id carry:

Field
storyId The item’s story; null in no story, or split from it
storyFollowed You follow the item’s story
storyNew Of a story you follow: its items you can see that joined since you last looked. 0 otherwise

Not yet

  • Follow-ups and corrections. Every item after the first counts the same. jev’s same-story command can also say whether an item is a new development or adds facts (development, addition, dedupe.md); the stage doesn’t ask yet, and nothing tells a correction apart.
  • Notifications. New coverage is marked in the app only: no push or email.
  • A longer global timeline. Stories covers the last 7 days; older stories are reached through their items.