Skip to content

docs: handoff β€” quality profiles, what's left, and the ground truth - #57

Merged
rancur merged 2 commits into
mainfrom
docs/handoff
Aug 10, 2026
Merged

docs: handoff β€” quality profiles, what's left, and the ground truth#57
rancur merged 2 commits into
mainfrom
docs/handoff

Conversation

@rancur

@rancur rancur commented Aug 10, 2026

Copy link
Copy Markdown
Owner

Pausing the quality-profile work here. This adds docs/HANDOFF.md so a fresh agent can pick it up without re-deriving anything, and points the README at it.

Where it stands

Live on v2.17.0, parity 94.93% (5,163/5,439).

Built and shipped: the Radarr-style profile (floor / cutoff / target) with a settings UI, tiered search that descends hi-res β†’ 24-bit β†’ lossless β†’ 320k, the rechecker that hunts above what a track already has, and the relocator that swaps the file and re-points Lexicon's Track.location.

Deliberately off: relocation_enabled=0. Finding an upgrade nothing can install is worse than not looking β€” _lexicon_find_or_import short-circuits on the existing lexicon_track_id, so the better file would land on disk unreferenced while Lexicon keeps playing the worse copy. With the flag off, no hunts are queued at all.

What's left

  1. Turn on automatic upgrades β€” the last mile, and the highest-risk step remaining. The relocator has never executed a real write. Step-by-step sequence is in the doc.
  2. Score the existing library β€” 4,978 tracks have no quality_tier; the rechecker can't evaluate what it can't see.
  3. The remaining errors β€” 129 wrong_version, 57 no_tidal_match, 70 other.
  4. Phase 3 UI β€” not started; planned in detail.

Why the ground-truth section exists

Several facts in it contradict what the code previously assumed, and each cost real time:

  • Lexicon's API refuses location, bpm and dateAdded β€” direct SQLite writes only.
  • A location-only write preserves cues, grids and cloud links (verified, not assumed).
  • WaxFlow stores lexicon_track_id as TEXT while Lexicon's Track.id is INTEGER β€” comparing them raw matches nothing and silently degrades to path matching.
  • ffprobe reports AIFF bit depth in bits_per_sample; without the fallback all 974 AIFFs drop a tier.
  • Schema DDL is duplicated across two files, and a CREATE INDEX on a new column in the same executescript silently skips every statement after it.

The most useful part is the failure pattern: four separate times, code that passed tests and deployed cleanly did nothing at all. Each was caught by querying production after deploying β€” never by the test suite.

πŸ€– Generated with Claude Code

https://claude.ai/code/session_01HmUiLHPmKoz215WAWV5eHe

rancur and others added 2 commits August 10, 2026 10:15
Captures where the quality-profile work stands, what is deliberately switched
off and why, and the ground-truth facts that were expensive to establish --
several of which contradict what the code previously assumed.

The section worth reading twice is the failure pattern: four separate times in
this work, code that passed tests and deployed cleanly did nothing at all
(coverage measuring 1000 of 5612 tracks; the quality floor placed at a stage the
pipeline never reached; a duration gate on two of four matching paths; a health
row that 500'd the dashboard). Each was caught by querying production after
deploying, never by the test suite.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HmUiLHPmKoz215WAWV5eHe
The worker's tests generate and probe REAL audio files -- that is deliberate,
since the bugs they guard (AIFF bit depth in bits_per_sample, VBR bitrate needing
max(stream, format)) are all metadata-reading bugs that a mocked probe would hide.

The worker image installs ffmpeg; the GitHub runner does not.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HmUiLHPmKoz215WAWV5eHe
@rancur
rancur merged commit b0efbcb into main Aug 10, 2026
6 checks passed
@rancur
rancur deleted the docs/handoff branch August 10, 2026 17:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant