Commit Graph

133 Commits

Author SHA1 Message Date
5c31be99b5 feat: wire up subtitle prefetch service to MPV events
Initializes prefetch on external subtitle track activation, detects
seeks via time-pos delta threshold, pauses prefetch during live
subtitle processing, and restarts on cache invalidation.

- Extract loadSubtitleSourceText into reusable function
- Add prefetch service state and initSubtitlePrefetch helper
- Thread onTimePosUpdate through event actions/bindings/main-deps
- Pause prefetch on subtitle change, resume on emit
- Restart prefetch after tokenization cache invalidation
- Query track-list on media path change to find external subs
2026-03-15 13:16:19 -07:00
05fe9c8fdf test: add seek and pause/resume tests for prefetch service 2026-03-15 13:04:50 -07:00
f89aec31e8 feat: add subtitle prefetch service with priority window
Implements background tokenization of upcoming subtitle cues with a
configurable priority window. Supports stop, pause/resume, seek
re-prioritization, and cache-full stopping condition.
2026-03-15 13:04:26 -07:00
6cf0272e7e feat: add unified parseSubtitleCues with format auto-detection 2026-03-15 13:01:50 -07:00
7ea303361d feat: add ASS subtitle cue parser 2026-03-15 13:01:34 -07:00
95ec3946d2 feat: add SRT/VTT subtitle cue parser 2026-03-15 13:01:08 -07:00
d71e9e841e perf: use cloneNode template and replaceChildren for DOM rendering
Replace createElement('span') with cloneNode(false) from a lazily
initialized template span. Replace innerHTML='' with replaceChildren()
to avoid HTML parser invocation on clear. Add cloneNode/replaceChildren
to FakeElement in tests to support the new APIs.
2026-03-15 12:52:56 -07:00
047b349d05 perf: batch annotation passes into single loop
Collapse applyKnownWordMarking, applyFrequencyMarking, and
applyJlptMarking into a single .map() call. markNPlusOneTargets
remains a separate pass (needs full array with isKnown set).

Eliminates 3 intermediate array allocations and 3 redundant
iterations over the token array.
2026-03-15 12:49:08 -07:00
35946624c2 feat: add preCacheTokenization and isCacheFull to SubtitleProcessingController 2026-03-15 12:46:43 -07:00
bb13e3c895 docs: add renderer performance implementation plan
Detailed TDD implementation plan for 3 optimizations:
- Subtitle prefetching with priority window
- Batched annotation passes
- DOM template pooling via cloneNode
2026-03-15 12:42:35 -07:00
36181d8dfc docs: address second round of spec review feedback
Add isCacheFull() method to controller interface for prefetcher
stopping condition, specify pause flag mechanism for live priority,
and clarify replaceChildren() applies to all subtitle root clears.
2026-03-15 12:22:00 -07:00
40117d3b73 docs: address spec review feedback
Clarify frequency rank assignment vs filtering pipeline, add cache
capacity strategy for prefetch, specify seek detection threshold,
document cache invalidation re-prefetch behavior, detail ASS parsing
edge cases, add error handling section, and use replaceChildren().
2026-03-15 12:19:35 -07:00
7fcd3e8e94 docs: add renderer performance optimization design spec
Covers three optimizations to minimize subtitle-to-annotation latency:
subtitle prefetching with prioritized sliding window, batched annotation
passes, and DOM template pooling via cloneNode.
2026-03-15 12:15:46 -07:00
467ed02c80 fix(launcher): default stats cleanup to vocab mode 2026-03-15 00:19:08 -07:00
e68defbedf docs: update stats dashboard docs, config, and releasing checklist
- Update dashboard tab descriptions to include Anime tab and richer session timelines
- Add autoOpenBrowser config option to stats section
- Add subminer stats cleanup command to changelog fragment
- Expand releasing checklist with doc verification, changelog lint, and build gates
2026-03-14 23:11:27 -07:00
c4bea1f9ca feat(stats): redesign session timeline and clean up vocabulary tab
- Replace cumulative line chart with activity-focused area chart showing per-interval new words
- Add total words as a blue line on a secondary right Y-axis
- Add pause shaded regions, seek markers, and card mined markers with numeric x-axis for reliable rendering
- Add clickable header logo with proper aspect ratio
- Remove unused "Hide particles & single kana" checkbox from vocabulary tab
2026-03-14 23:11:27 -07:00
7d76c44f7f feat(stats): add episodes completed and anime completed to tracking snapshot
- Query watched videos count and anime with all episodes watched
- Display in overview tracking snapshot
- Remove efficiency section from trends
2026-03-14 23:11:27 -07:00
5e944e8a17 chore: remove implementation plan documents 2026-03-14 23:11:27 -07:00
06745ff63a feat: add AniList rate limiter and remaining backlog tasks 2026-03-14 23:11:27 -07:00
fcfa323e0f docs: update documentation site for stats dashboard and immersion tracking 2026-03-14 23:11:27 -07:00
5506a75ef8 feat(stats): build anime-centric stats dashboard frontend
5-tab React dashboard with Catppuccin Mocha theme:
- Overview: hero stats, streak calendar, watch time chart, recent sessions
- Anime: grid with cover art, episode list with completion %, detail view
- Trends: 15 charts across Activity, Efficiency, Anime, and Patterns
- Vocabulary: POS-filtered word/kanji lists with detail panels
- Sessions: expandable session history with event timeline

Features:
- Cross-tab navigation (anime <-> vocabulary)
- Global word detail panel overlay
- Expandable episode detail with Anki card links (Expression field)
- Per-anime multi-line trend charts
- Watch time by day-of-week and hour-of-day
- Collapsible sections with accessibility (aria-expanded)
- Card size selector for anime grid
- Cover art caching via AniList
- HTTP API client with file:// protocol fallback for Electron overlay
2026-03-14 23:11:27 -07:00
e374e53d97 feat(stats): add launcher stats command and build integration
- Launcher stats subcommand with cleanup mode
- Stats frontend build integrated into Makefile
- CI workflow updated for stats package
- Config example updated with stats section
- mpv plugin menu entry for stats toggle
2026-03-14 23:11:27 -07:00
6d8650994f feat(stats): wire stats server, overlay, and CLI into main process
- Stats server auto-start on immersion tracker init
- Stats overlay toggle via keybinding and IPC
- Stats CLI command (subminer stats) with cleanup mode
- mpv plugin menu integration for stats toggle
- CLI args for --stats, --stats-cleanup, --stats-response-path
2026-03-14 23:11:27 -07:00
a7c294a90c feat(stats): add stats server, API endpoints, config, and Anki integration
- Hono HTTP server with 20+ REST endpoints for stats data
- Stats overlay BrowserWindow with toggle keybinding
- IPC channel definitions and preload bridge
- Stats config section (toggleKey, serverPort, autoStartServer, autoOpenBrowser)
- Config resolver for stats section
- AnkiConnect proxy endpoints (guiBrowse, notesInfo)
- Note ID passthrough in card mining callback chain
- Stats CLI command with autoOpenBrowser respect
2026-03-14 23:11:27 -07:00
f005f542a3 feat(immersion): add anime metadata, occurrence tracking, and schema upgrades
- Add imm_anime table with AniList integration
- Add imm_subtitle_lines, imm_word_line_occurrences, imm_kanji_line_occurrences
- Add POS fields (part_of_speech, pos1, pos2, pos3) to imm_words
- Add anime metadata parsing with guessit fallback
- Add video duration tracking and watched status
- Add episode, streak, trend, and word/kanji detail queries
- Deduplicate subtitle line recording within sessions
- Pass Anki note IDs through card mining callback chain
2026-03-14 23:11:27 -07:00
ee95e86ad5 docs: add stats dashboard design docs, plans, and knowledge base
- Stats dashboard redesign design and implementation plans
- Episode detail and Anki card link design
- Internal knowledge base restructure
- Backlog tasks for testing, verification, and occurrence tracking
2026-03-14 23:11:27 -07:00
9eed37420e Automate AUR publish in tagged release workflow (#22) 2026-03-14 19:49:46 -07:00
99f4d2baaf Harden subminer-scrum-master pre-handoff policy checks (#20) 2026-03-13 01:40:48 -07:00
f4e8c3feec chore: make verifier script executable 2026-03-13 00:44:00 -07:00
d0b308f340 test: harden agent verification workflow 2026-03-13 00:44:00 -07:00
1b56360a24 feat(yomitan): add read-only external profile support for shared dictionaries (#18) 2026-03-12 01:17:34 -07:00
68833c76c4 Release v0.6.1 and scope workflow write permissions
- Bump package version and changelog to v0.6.1
- Move `contents: write` permission to release job only
- Remove consumed changelog fragment files
v0.6.1
2026-03-11 20:53:52 -07:00
4d7c80f2e4 Add overlay gamepad support for keyboard-only mode (#17) v0.6.0 2026-03-11 20:34:46 -07:00
2f17859b7b Document AUR install flow and add backlog planning artifacts
- Add Arch Linux `subminer-bin` install instructions to README and docs-site installation guide
- Add Hyprland troubleshooting guidance for transparency and global shortcut passthrough
- Add TASK-159..164 backlog records and skill design plans; include changelog fragment
- Apply formatting-only update to `src/release-workflow.test.ts`
2026-03-11 02:08:59 -07:00
9c7e02cbf0 Enforce config example drift checks in CI and release
- add `verify:config-example` script with tests to fail on missing/stale generated config artifacts
- run the verification in CI and release workflows, and document it in release/docs guidance
- fix docs-site Cloudflare Pages watch path to `docs-site/*` with regression coverage
2026-03-10 20:06:41 -07:00
5f320edab5 move docs back repo 2026-03-10 19:47:16 -07:00
f7ce3371a1 chore: finalize v0.5.6 changelog fragments v0.5.6 2026-03-10 18:49:21 -07:00
71805dccd7 chore: bump package version 2026-03-10 02:33:13 -07:00
a13b7352d7 chore: make pretty 2026-03-10 02:32:53 -07:00
ff5ecdaded clean up and add new showcase videos 2026-03-10 02:32:27 -07:00
b32c3cf58c fix: avoid merged dictionary rebuilds on revisits 2026-03-10 02:26:07 -07:00
b791262860 fix: keep jlpt underline stable during Yomitan lookup 2026-03-10 01:37:32 -07:00
29b8c6e02a update agents file and readme 2026-03-10 01:27:05 -07:00
618727d8e8 fix: set canonical userData path during startup 2026-03-09 23:52:50 -07:00
fed60c265d style: restore repo formatting 2026-03-09 18:10:32 -07:00
a34a7489db chore: prep v0.5.5 release v0.5.5 2026-03-09 18:07:01 -07:00
e59192bbe1 Improve startup dictionary progress and fix overlay/plugin input handlin
- show a dedicated startup OSD "building" phase for character dictionary sync
- forward bare `Tab` from visible overlay to mpv so AniSkip works while focused
- fix Windows plugin env override resolution for `SUBMINER_BINARY_PATH`
v0.5.4
2026-03-09 02:35:03 -07:00
e0f82d28f0 Improve startup dictionary sync UX and default playback keybindings
- Add default `f` fullscreen overlay binding and switch default AniSkip skip key to `Tab`
- Make character-dictionary auto-sync non-blocking at startup with tokenization gating for Yomitan mutations
- Add ordered startup OSD progress (checking/generating/updating/importing), refresh current subtitle on sync completion, and extend regression tests
2026-03-09 00:50:32 -07:00
a0521aeeaf fix(tracker): follow active hyprland and visible x11 windows 2026-03-08 23:03:55 -07:00
2127f759ca fix: correct guessit title parsing for character dictionary sync 2026-03-08 23:03:48 -07:00