No description
  • TypeScript 96.2%
  • Nix 2.6%
  • CSS 0.8%
  • Dockerfile 0.2%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Martí Comas Canal 2ad961d68d
All checks were successful
ci / check (push) Successful in 59s
Merge pull request 'develop' (#41) from develop into main
Reviewed-on: reaf/reaf#41
2026-11-25 19:00:49 +01:00
.agents/skills/run-reef refactor!: rename newsrss to reef 2026-11-24 23:52:57 +01:00
.forgejo/workflows refactor!: rename newsrss to reef 2026-11-24 23:52:57 +01:00
apps feat: keep a downloaded video's captions, and show them in the player 2026-11-25 17:30:45 +00:00
docs feat: keep a downloaded video's captions, and show them in the player 2026-11-25 17:30:45 +00:00
e2e refactor!: rename newsrss to reef 2026-11-24 23:52:57 +01:00
nix build: ship yt-dlp and ffmpeg with reef 2026-11-25 15:19:25 +00:00
packages/shared feat: keep a downloaded video's captions, and show them in the player 2026-11-25 17:30:45 +00:00
.dockerignore build: add npm workspaces, TypeScript base config, Biome and lefthook 2026-11-17 19:55:43 +01:00
.editorconfig chore: initialize repository 2026-11-17 19:55:33 +01:00
.env.example feat: keep a downloaded video's captions, and show them in the player 2026-11-25 17:30:45 +00:00
.envrc chore: initialize repository 2026-11-17 19:55:33 +01:00
.gitattributes chore: initialize repository 2026-11-17 19:55:33 +01:00
.gitignore feat(api): download YouTube videos with yt-dlp for the app's own player 2026-11-25 15:07:22 +00:00
AGENTS.md docs: describe downloaded videos, and record why 2026-11-25 15:19:27 +00:00
biome.json build: add npm workspaces, TypeScript base config, Biome and lefthook 2026-11-17 19:55:43 +01:00
bun.lock refactor!: rename newsrss to reef 2026-11-24 23:52:57 +01:00
bunfig.toml build: install, run and bundle with Bun instead of npm and Node 2026-11-24 00:18:56 +01:00
CLAUDE.md docs: add AGENTS.md and a run-newsrss agent skill 2026-11-17 20:14:04 +01:00
compose.prod.yaml refactor(api)!: keep a downloaded video as long as its entry 2026-11-25 15:43:26 +00:00
compose.yaml refactor!: rename newsrss to reef 2026-11-24 23:52:57 +01:00
flake.lock build: add a Nix flake with the development shell 2026-11-17 19:55:43 +01:00
flake.nix build: ship yt-dlp and ffmpeg with reef 2026-11-25 15:19:25 +00:00
lefthook.yml build: install, run and bundle with Bun instead of npm and Node 2026-11-24 00:18:56 +01:00
package.json refactor!: rename newsrss to reef 2026-11-24 23:52:57 +01:00
README.md refactor!: rename newsrss to reef 2026-11-24 23:52:57 +01:00
tsconfig.base.json build: add npm workspaces, TypeScript base config, Biome and lefthook 2026-11-17 19:55:43 +01:00

reef

A self-hosted, multi-user RSS reader with AI summaries, in the spirit of Miniflux: follow sites, read in a calm three-pane reader, and ask an AI model for a short brief of any article through an AI endpoint each user chooses.

Status: 0.1, feature complete for daily reading; not yet run in production.

Features

  • RSS, Atom, RDF and JSON Feed. Paste any page of a site and its feed is found: declared feed links, feed-looking links in the page, the usual paths of blog engines, then the site's home page.
  • YouTube: paste a channel (@handle, /channel/, /c/) or a video and you follow the channel's videos, without Shorts. Videos play inline.
  • Several users on one server. Feeds are fetched once however many people follow them; read and starred state is each person's own.
  • AI summaries through any OpenAI-compatible endpoint (OpenAI, OpenRouter, LiteLLM, Ollama, vLLM, llama.cpp). Each user sets their own endpoint, key and model in the web app; keys are stored encrypted.
  • A daily brief: at a time each user picks, the AI reads the brief's own feeds (kept apart from the ones they follow), keeps the stories that match their interests (optionally after a first pass by a decision model such as TypeSafe's Jev), groups the outlets covering the same one, and sums each up in a line or two.
  • Listening: any entry read aloud, and the daily brief as a short radio show (a presenter, the headlines, a section per interest, jingles and a music bed), through any speech model on OpenAI's /audio/speech (OpenAI, or a local Kokoro or Speaches server). The music is synthesized in the browser.
  • Full-article extraction (Mozilla Readability) for feeds that only send a teaser, used automatically before summarizing one.
  • Categories, full-text search, unread counts, OPML import and export, keyboard shortcuts (j k s m b v /), light and dark themes.
  • First-run setup makes the first account the admin; registration stays closed unless an admin opens it.

Stack

  • TypeScript everywhere, on Bun: runtime, workspaces, bundler and test runner
  • API: Fastify 5, Zod, Drizzle ORM, Postgres 18, TanStack AI (@tanstack/ai-openai), feedsmith, sanitize-html, Readability
  • Web: React 19, Vite, TanStack Router, Query and Form, Tailwind 4, daisyUI 5, Radix primitives, Tabler Icons
  • Tests: bun test with real Postgres, Testing Library with happy-dom and MSW, Playwright
  • Tooling: Biome, lefthook, Nix flake, Docker, Forgejo Actions

Quick start

Docker

cp .env.example .env
sed -i "s/^APP_SECRET=.*/APP_SECRET=$(openssl rand -hex 32)/" .env
docker compose --profile app up --build

Open http://localhost:8080 and create the admin account. That is the production image; docker compose --profile all up --build runs the dev servers with hot reload instead (web on http://localhost:5173).

Local tooling (Bun 1.4+, Docker for Postgres)

bun install
cp .env.example .env
sed -i "s/^APP_SECRET=.*/APP_SECRET=$(openssl rand -hex 32)/" .env
docker compose --profile db up -d --wait
bun run db:migrate
bun run dev

Open http://localhost:5173. bun run seed adds admin and reader (password password123) if you would rather skip setup. Without Docker, any Postgres 18 works: point DATABASE_URL at it (see docs/installation.md).

Nix

nix develop          # Bun, Postgres 18, Biome, Playwright's Chromium
bun install
# then the same steps as the local tooling path

nix build produces the reef, reef-migrate and reef-admin programs, and nixosModules.default runs them on NixOS (docs/deployment.md).

Configuration

Every variable is in .env.example with its default. The ones you will set:

Variable What it is for Example
DATABASE_URL Postgres connection postgres://reef:reef@localhost:5434/reef
APP_SECRET Encrypts the stored AI key; 64 hex chars openssl rand -hex 32
COOKIE_SECURE Secure session cookie; on by default in production true
TRUST_PROXY Behind a reverse proxy true
FETCH_INTERVAL_MINUTES How often each feed is fetched 30
FETCH_ALLOW_PRIVATE_NETWORKS Allow feeds on the LAN or localhost false
ENTRY_RETENTION_DAYS Days before read, unstarred entries are pruned 90

The AI endpoint, key, model, summary language and instructions are not environment variables: each user sets their own in Settings -> AI.

Commands

Command Does
bun run dev API and web dev servers, with reload
bun run build Web bundle, API bundle
bun run test API tests (needs Postgres) and web tests
bun run test:e2e Build, then the Playwright path
bun run lint / bun run format Biome check / write
bun run typecheck tsc in every workspace
bun run db:generate SQL migration from a schema change
bun run db:migrate Apply migrations
bun run seed Development users
bun run admin reset-password <name> Account recovery

bun run test, not bun test: each app's tests need its own setup, which its bunfig.toml preloads.

Layout

apps/api/          Fastify API, feed fetcher, migrations (drizzle/)
apps/web/          React single-page app
packages/shared/   Zod schemas used by both
e2e/               Playwright test and the stack it runs against
nix/               Nix package
docs/              Installation, development, deployment, architecture

Documentation