# ytplayer — Feature Ideas & Enhancement Roadmap > **Status:** Research & Proposed Roadmap > **Target:** Web PWA, Tauri (Windows), zero-native (macOS / Linux) > **Date:** October 2026 --- ## 1. Context & Architecture Baseline `ytplayer` is an ad-free, privacy-preserving media engine with a dual identity: 1. **Ad-Free Media Player & Offline PWA**: Built with vanilla JS on the frontend and Bun + Hono on the backend (libsql SQLite database). It uses `yt-dlp` and InnerTube for direct stream extraction without Google accounts, and caches media locally (OPFS in browser, single-file H.264/HEVC faststart on server, WebRTC P2P mesh between devices). 2. **Live Worship & Stage Performance Tool**: Equipped with **Service Mode** (wake-locked setlist view, auto-scaling lyric fonts, per-song arrangement notes), synchronized LRC lyrics with section/cue tags, and a **Presenter screen** (`/?present=`) with QR pairing. This document synthesizes high-value feature opportunities gathered from research into modern YouTube frontends (FreeTube, ReVanced, SmartTube, Namida), modern music players (Plexamp, Spotube), and live stage tools (Planning Center Music Stand, OnSong, MultiTracks Playback). --- ## 2. Feature Proposals by Domain ### Domain 1: Smart YouTube & Playback Experience #### 1.1 SponsorBlock & Non-Music Segment Skipping * **The Concept**: Automatically skip or visually mark sponsored segments, self-promos, interaction reminders, and non-music sections. * **Why it matters**: Music videos frequently feature skits, prolonged silent pauses, or spoken intros. Skipping `music_offtopic` ensures the music starts immediately. * **Technical Path**: * Free, unauthenticated REST API: `GET https://sponsor.ajay.app/api/skipSegments?videoID=&categories=["sponsor","intro","outro","music_offtopic","selfpromo"]`. * Highlight segments as color-coded spans over the seek bar (`#timeline` / Glass Stage scrubber). * During the playback tick in `frontend/app.js`, if `currentTime` enters a skippable segment and auto-skip is enabled in Settings, seek to the segment end and show an "Unskip" toast. * Server media cache can optionally apply `--sponsorblock-mark` during ffmpeg intake. #### 1.2 Automatic YouTube Chapter Extraction & Interactive Scrubber * **The Concept**: Automatically parse video chapters from YouTube metadata and display chapter splits on the progress bar. * **Why it matters**: Currently, chapters are only created manually. Full albums, sermons, conference talks, and live sets already have timestamps in video descriptions. * **Technical Path**: * In `server/server.js` (`/api/streams`), expose `chapters: [{ start_time, end_time, title }]` directly from InnerTube or `yt-dlp`. * Render tick marks / gaps on the progress scrubber for each chapter boundary. * Display the current chapter title next to the timestamp. * Add keyboard shortcuts: `[` (previous chapter) and `]` (next chapter). #### 1.3 Return YouTube Dislike (RYD) & Quality Rating * **The Concept**: Show community like/dislike ratios and ratings for videos. * **Why it matters**: Helps identify misleading arrangements, clickbait, poor audio rips, or broken videos before playback. * **Technical Path**: * Query `https://returnyoutubedislikeapi.com/votes?videoId=` (public, CORS-enabled). * Display a discreet like ratio bar or percentage badge on the video card and now-playing details. #### 1.4 On-Screen Subtitles & Closed Captions (CC) Overlay * **The Concept**: Render synchronized captions directly over the video playback stage. * **Why it matters**: `ytplayer` currently only uses captions for transcript search or importing into lyrics. Spoken sermons, tutorials, foreign tracks, and non-musical videos need readable on-screen subtitles. * **Technical Path**: * Add a `CC` button on the player controls. * Fetch timed lines from `/api/notes/:id/captions`. * Render an HTML overlay synchronized to `Player.master.currentTime` with settings for font size, background opacity, and positioning. #### 1.5 Silence Skipping (Talk & Sermon Mode) * **The Concept**: Automatically speed up or skip past silent gaps in spoken-word media. * **Why it matters**: Long sermons, podcasts, and talks often have pauses; skipping silence saves 10–20% of listening time without altering speech tone. * **Technical Path**: * Connect an `AnalyserNode` or `AudioWorklet` in the Web Audio graph. * If audio energy (RMS) stays below -45 dB for >800 ms, ramp `playbackRate` to 2.5× until speech resumes. --- ### Domain 2: Audiophile & Music Player Polish #### 2.1 EBU R128 / LUFS Loudness Normalization * **The Concept**: Eliminate jarring volume jumps between tracks in playlists and queues. * **Why it matters**: YouTube master volumes vary widely (-24 LUFS to -8 LUFS). Normalization ensures consistent listening levels. * **Technical Path**: * When generating waveform peaks in `server/media-cache.js`, run ffmpeg's `ebur128` filter once to measure integrated loudness (LUFS). * Store `lufs` in the database and pass it via `/api/streams` and `/api/media/:id`. * In `frontend/app.js`, apply a Web Audio `GainNode` to normalize tracks to a standard -14 LUFS target. #### 2.2 Real-Time Pitch Shifting & Independent Tempo Adjustment * **The Concept**: Transpose playback key (±6 semitones) without altering tempo, or slow down tempo without changing pitch. * **Why it matters**: Singers and worship teams often need to adapt songs to a band's vocal key. Instrumentalists need to slow down fast sections to learn them. * **Technical Path**: * Use an AudioWorklet running a Phase Vocoder or `SoundTouchJS` DSP processor. * Provide stepper controls for semitone transposition and tempo percentage (0.5×–1.5×). #### 2.3 Ambient Glow / Reactive Lighting Mode * **The Concept**: A soft dynamic glow behind the video player that mirrors current video colors (similar to YouTube Ambient Mode or Apple Music dynamic art). * **Technical Path**: * Render video frames onto an offscreen 16×16 `` at ~10 FPS. * Display a blurred canvas (`filter: blur(50px)`) directly behind the player container with smooth CSS opacity. * Auto-disable when `settings.perfMode` is active or under `prefers-reduced-motion`. #### 2.4 Smart Autoplay Radio / Endless Mix * **The Concept**: Keep playing related songs when the active playlist or queue concludes. * **Technical Path**: * Fetch candidate related tracks via InnerTube `next` continuity tokens. * Re-rank candidates using the client's local `StatsTrack` (`playCount`, listening duration, and skips) to favor familiar favorites while avoiding immediate repeats. --- ### Domain 3: Live Worship, Band & Stage Performance Engine #### 3.1 Interactive ChordPro Sheets & Live Transposition * **The Concept**: Display chords inline or above lyrics with 1-tap live transposition and capo calculation. * **Why it matters**: Replaces the need for external music stand apps (Planning Center Music Stand, OnSong) on stage. * **Technical Path**: * Extend `frontend/lyrics-core.js` to parse ChordPro directives (`[G]`, `[D/F#]`, `{key: G}`). * Add a Transpose controller (+1 / -1 semitone, Capo selector) that dynamically recalculates chord symbols in real time. * Add a view toggle: "Lyrics Only" vs. "Chords & Lyrics". #### 3.2 Bluetooth Foot Pedal / Page-Turner Support * **The Concept**: Hands-free navigation for musicians on stage using standard Bluetooth foot pedals (AirTurn, PageFlip, Donner, Stomp). * **Why it matters**: Musicians cannot remove their hands from instruments while playing. * **Technical Path**: * Standard foot pedals map to keyboard keys: `PageDown`, `PageUp`, `ArrowUp`, `ArrowDown`. * Extend the global `keydown` listener in `frontend/app.js` to handle pedal events in Service Mode: * `PageDown` / `PageUp`: Scroll down / up by one lyric section. * Configurable actions: Next/Previous track, trigger A-B loop, or jump to Chorus. #### 3.3 Confidence Monitor & Stage Clock (Presenter Mode) * **The Concept**: A high-visibility stage display mode for the Presenter screen (`/?present=`). * **Why it matters**: Singers and worship leaders need glanceable cues for upcoming lyrics, section names, and remaining time. * **Technical Path**: * In `Presenter` (`frontend/app.js`), provide a **Confidence Monitor** layout: * **Current Line**: Extra-large, high-contrast text. * **Next Line Preview**: Smaller, dimmed text directly underneath. * **Section Badge**: Prominent label (e.g. `# CHORUS 2`). * **Stage Clock & Timer**: Current wall clock plus elapsed/remaining song timer. #### 3.4 Section Quick-Jump Pad * **The Concept**: A grid of buttons representing song sections (`[Intro]`, `[Verse 1]`, `[Chorus]`, `[Bridge]`, `[Outro]`). * **Why it matters**: Worship teams often repeat choruses or spontaneously transition between sections during live services. * **Technical Path**: * Parse `# Section` headers from synced lyrics in `frontend/lyrics-core.js`. * Render an arrangement button strip in Service Mode. * Tapping a section immediately seeks playback to that section's start timestamp. #### 3.5 Visual Metronome & Count-In Click * **The Concept**: Visual flash or gentle audio click count-in before track playback begins. * **Why it matters**: Enables the band to start playing on beat before the recorded track introduces audio. * **Technical Path**: * When `@ 70 BPM` metadata is present in song notes, offer an optional 4-beat visual flash on the stage frame or Web Audio click before playback starts. --- ### Domain 4: Library, Offline & Sync Innovations #### 4.1 Visual Download Manager & Storage Dashboard * **The Concept**: A unified management dashboard in Settings for offline media. * **Why it matters**: Gives clear visibility into queued, active, and completed downloads with storage usage breakdowns. * **Technical Path**: * Show active download tasks with real-time progress bars. * List storage usage grouped by playlist, audio vs. video format, and OPFS vs. server cache. * Add controls: "Pause All", "Resume All", and "Retry Failed". #### 4.2 Smart Auto-Offline Favorites * **The Concept**: Keep a user's most essential songs available offline automatically. * **Technical Path**: * Setting: *"Keep Top 25 Most-Played Songs Offline"* or *"Keep Active Setlist Offline"*. * Automated background routine checks local `playCount` and triggers cache downloads for missing items during idle time. #### 4.3 Self-Contained Offline Playlist Bundling (Zip Export) * **The Concept**: Export a full offline bundle containing playlist JSON plus the saved audio/video files for complete air-gapped device migration. --- ### Domain 5: Collaboration & Watch Parties #### 5.1 Collaborative Setlists & Playlists * **The Concept**: Multiple devices editing a single playlist simultaneously with live sync. * **Why it matters**: Band leaders and team members can collaborate on Sunday setlists from different locations. * **Technical Path**: * Extend playlist sync in `server/db.js` with shared write keys. * Broadcast item reordering and song additions over the existing WebSocket hub in `server/party.js`. #### 5.2 Watch Party DJ Mode & Upvote Queue * **The Concept**: Allow guests in a watch party (`/ws/party`) to submit song requests that the group can upvote. * **Technical Path**: * Add a "Suggested Queue" tab in the watch party drawer. * Upvotes dynamically sort songs; when current playback finishes, the highest-voted song plays next. --- ## 3. Implementation Matrix & Recommended Phases | Phase | Feature | Effort | Prerequisites & Reused Modules | |:---|:---|:---:|:---| | **Phase 1: Quick Wins** | **SponsorBlock & Non-Music Skip** | Low | Free SponsorBlock API, playback tick in `frontend/app.js` | | | **Automatic YouTube Chapter Ticks** | Low | InnerTube metadata in `server/server.js`, timeline scrubber | | | **Bluetooth Foot Pedal Shortcuts** | Low | Keydown event listener in `frontend/app.js` | | | **Section Quick-Jump Pad** | Low | Lyric section parser in `frontend/lyrics-core.js` | | **Phase 2: Stage & Audio** | **EBU R128 LUFS Normalization** | Medium | ffmpeg `ebur128` in `server/media-cache.js`, Web Audio GainNode | | | **ChordPro Display & Transpose** | Medium | `frontend/lyrics-core.js`, chord parser | | | **Confidence Monitor Stage View** | Medium | `Presenter` & `fitLyricLines` in `frontend/app.js` | | | **On-Screen Subtitles (CC)** | Medium | `/api/notes/:id/captions`, overlay renderer | | **Phase 3: Deep Capabilities** | **Pitch Shift & Tempo Worklet** | High | AudioWorklet / `SoundTouchJS` DSP | | | **Ambient Glow Lighting** | Low-Med | Offscreen `` + CSS blur | | | **Smart Autoplay Radio Mix** | Medium | InnerTube `next` API, `frontend/stats-core.js` | | | **Collaborative Setlists** | High | WebSocket hub in `server/party.js` |