corpus: self-hosted ListenBrainz and Last.fm frontend

Overview
corpus is a self-hosted frontend that collects scrobbles, enriches metadata, and caches cover art so you can explore your listening history without handing it off to a third party. It includes an interactive PureScript frontend for digging into habits, DuckDB-based storage for analytics, and tooling to keep everything reproducible. Tired of feeding your music life to opaque algorithms? This is the sort of project that answers back: “keep it local.”
Tech and features
The project leans on DuckDB for schema and analytical queries, a PureScript client for interactive exploration, and Nix + just for development and deployment workflows. It stores scrobbles and metadata, supports cover-image caching (S3 or S3-compatible endpoints), and can fall back to Last.fm or Discogs when needed. Environment variables control everything from API keys (Last.fm, Discogs, cosine.club) to metrics exposure and backup behavior — fine-grained, and frankly reassuring for power users.
Deployment and per-user control
Per-user configuration is baked in: URL slugs, ListenBrainz and Last.fm usernames, per-user DuckDB files, initial sync options, and toggleable cover-cache and backup settings. Backups can be scheduled (backupIntervalHours), cover caching can target S3 or MinIO-compatible storage, and a Prometheus metrics endpoint is optional. The repo docs include an architecture deep dive, DuckDB schema notes, and commands for building and running (just shell, nix build/run, npm + spago for PureScript).
Why it matters
Self-hosting is more than a flex; it’s a privacy play and an analytic playground for anyone who wants ownership of their listening data. it has been reported that a live demo is reachable at scrobbler.mtmn.name, and the full project is available on GitHub: https://github.com/mtmn/corpus. If you care about control — and like poking at raw data with SQL instead of letting charts tell you what you like — this one’s worth a look.
Sources: github.com/mtmn, Lobsters
Comments