Skip to content
bluzernamePublic

About

Read-it-later app that turns shared articles into AI-summarized daily digests. Flutter + Supabase + Claude.

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

ReadZero

Read-it-later for iOS with AI daily digests and podcast playback. Share a link from any app, ReadZero extracts the article, analyzes it with Claude, and each morning delivers a digest of everything you saved. Digests can also be listened to as podcast episodes.

App Store Flutter Supabase Claude CI

Features

  • Save from anywhere: iOS Share Extension writes the URL to an App Group; the app syncs it to Supabase and kicks off extraction.
  • Full content extraction: Mozilla Readability on the Edge Function, Jina Reader as fallback, Unsplash cover image fallback with photographer credit.
  • X and LinkedIn: X posts are fetched through Grok's x_search tool (xAI). LinkedIn and X can also be extracted on-device through an authenticated WKWebView session (features/auth).
  • AI analysis: TL;DR, key points, deeper bullets, topics, sentiment, reading time and content type per article, generated by Claude through OpenRouter.
  • Daily digest: a pg_cron job calls generate-digest every morning; the digest has an overall summary, top themes, per-article highlights and cross-article insights. A local notification fires when it lands.
  • Podcast playback: digests can be turned into audio episodes, played in-app (mini player, just_audio) or subscribed to as a personal RSS feed from any podcast app.
  • Library and archive: reader UI with markdown rendering, archive, delete, mark as read, JSON export of your data.
  • Anonymous accounts: the app signs in anonymously on first launch; no sign-up required.

How it works

iOS Share Extension --> App Group --> Flutter app --> Supabase (Postgres, Auth, Realtime)
                                                          |
                                     trigger: articles insert -> processing_queue
                                                          |
                                                  process-queue (Edge Function)
                                                          |
                                                  extract-article (Edge Function)
                                          Readability / Jina / Grok  +  Claude via OpenRouter
                                                          |
                              pg_cron 08:00 UTC -> generate-digest (Edge Function) -> digests

Repository layout

lib/
  main.dart                        App entry: Supabase init, anonymous sign-in, share channel
  core/
    config/env.dart                Build-time config (dart-define)
    models/models.dart             Article, DailyDigest, PodcastEpisode, UserSettings, ...
    router/app_router.dart         go_router: /, /digest, /settings, /article/:id, /archive
    services/                      Supabase access, local notifications, authenticated extraction
    theme/app_theme.dart           Design system
  features/
    articles/                      Article detail, discover cards, providers
    auth/                          Web login for LinkedIn/X cookie-based extraction
    digest/                        Daily digest screen
    home/                          Library
    podcast/                       Player state and mini player
    settings/                      Settings and archive
supabase/
  migrations/                      Schema, processing queue, cron job
  functions/
    _shared/config.ts              Model ids (CLAUDE_MODEL, GROK_MODEL)
    extract-article/               Extraction + Claude analysis
    generate-digest/               Daily digest generation
    process-queue/                 Drains processing_queue, calls extract-article
ios/
  Runner/, ShareExtension/         App and share extension
  ci_scripts/ci_post_clone.sh      Xcode Cloud bootstrap
  scripts/validate_and_upload.sh   Local archive + App Store Connect upload
website/                           GitHub Pages site (index, support, privacy, terms)
docs/                              Markdown sources for the legal and support pages
test/                              Unit tests (models, restricted domains, config)

Setup

Prerequisites

  • Flutter 3.27.3 (the version pinned in CI and Xcode Cloud)
  • Xcode with an iOS simulator or device
  • A Supabase project
  • API keys: OpenRouter (Claude), Jina (fallback extraction), xAI (X posts). Optional: Tavily, Unsplash.

1. Clone and install

git clone https://github.com/bluzername/ReadZero.git
cd ReadZero
flutter pub get

2. App configuration (dart-define)

The app never reads config from disk. SUPABASE_URL and SUPABASE_ANON_KEY are compiled in with --dart-define.

cp .env.example .env      # fill in your project URL and anon key
flutter run --dart-define-from-file=.env

Debug builds assert with a clear message when the defines are missing; release builds log and run in offline mode. Only put values in .env that are safe to ship inside the app binary (the anon key is public by design; row level security protects the data).

3. Supabase backend

npm install -g supabase
supabase login
supabase link --project-ref YOUR_PROJECT_REF

# Schema (articles, digests, user_settings, processing_queue, triggers)
supabase db push

supabase/migrations/20260205_setup_daily_digest_cron.sql contains <SUPABASE_URL> and <SUPABASE_ANON_KEY> placeholders. Substitute them before running it (or store the key in Supabase Vault as described in the file comment) so the key is never committed.

4. Edge Function secrets and model ids

cp supabase/functions/.env.example supabase/functions/.env   # fill in
supabase secrets set --env-file supabase/functions/.env

supabase functions deploy extract-article --no-verify-jwt
supabase functions deploy generate-digest --no-verify-jwt
supabase functions deploy process-queue --no-verify-jwt
Variable Used by Default
OPENROUTER_API_KEY extract-article, generate-digest required
JINA_API_KEY extract-article required
XAI_API_KEY extract-article required
TAVILY_API_KEY extract-article optional
UNSPLASH_ACCESS_KEY extract-article optional
CLAUDE_MODEL extract-article, generate-digest anthropic/claude-haiku-4.5 (OpenRouter slug)
GROK_MODEL extract-article grok-4-1-fast (xAI model id)

SUPABASE_URL and SUPABASE_SERVICE_ROLE_KEY are injected by the Supabase runtime; do not set them as secrets.

5. iOS

Bundle ID live.bluzername.readzero.app. The Xcode project ships with the Share Extension, App Group and dark-mode icons configured.

  • Xcode Cloud: set SUPABASE_URL and SUPABASE_ANON_KEY as environment variables on the workflow. ios/ci_scripts/ci_post_clone.sh installs Flutter, then runs flutter build ios --config-only with those defines so Generated.xcconfig carries them into the archive.
  • Local release upload: ASC_APP_PASSWORD=... ./ios/scripts/validate_and_upload.sh reads .env the same way, then archives and uploads to App Store Connect.

Development

flutter analyze --no-fatal-infos --no-fatal-warnings
flutter test

CI (.github/workflows/ci.yml) runs the same on every push and pull request. Dependabot keeps pub packages and GitHub Actions current.

License

MIT

About

Read-it-later app that turns shared articles into AI-summarized daily digests. Flutter + Supabase + Claude.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages