Lyrion Playground

The Library

The music collection behind the playground, its written charter, and the rules that let both a person and a program find their way around it.

Everything on this site starts with the collection. It is the music Lyrion serves, at home and, over Tailscale, wherever Mike happens to be.

The collection is governed by a written charter. It is a short, plain document that says what the library is for, what its folders and file names must look like, and which tools may change what. Every script in the automated pipeline answers to it. When a script, a note, or a habit disagrees with the charter, the charter wins.

What it is for

Mike treats the library as an ongoing project rather than a chore. The charter writes his collecting habits down as rules the tools must respect:

  • Completist. A missing track bothers him more than a duplicate ever would. Duplicate tracks across different releases are fine, compilations count as first-class albums, and no tool is allowed to optimize for deduplication.
  • Opportunistic. There is no fixed shopping list. CDs arrive as they cross his path, so reports aim for clarity, not for a priority queue.
  • Physical media is the upgrade path. A disc in hand is how an album gets completed or a lossy copy gets replaced with a lossless one.
  • Lossless is the end state. FLAC or ALAC, long term. Lossy files are a stop along the way, not a destination.
  • Long horizon. A temporary mess is acceptable. Steady improvement beats one heroic cleanup.
  • Rich metadata. Personnel credits, liner notes, booklet scans, lyrics, and session details accumulate over time, because the music is more than its audio.

The collection is never "done." That is the point.

How it is organized

Music is filed by artist, then by album, with each album in a folder of its own. The charter allows exactly two shapes of path, and tools treat anything else as something to flag:

  • an album track: the artist folder, then the album folder, then the track
  • a single that belongs to no album: the artist folder, then the track

Singles directly in an artist's folder are a legitimate form, not an error. They are simply exempt from the "is this album complete?" question.

The album folder name

The album folder name does real work. It carries the release year, the type of release, whether the album is complete, and the audio format, so a name like this tells the story at a glance:

The Dark Side of the Moon [1973] [album] (complete) (flac)

Read left to right:

Piece What it says
Title The album title as MusicBrainz knows it, with a few punctuation changes (see below).
[1973] The year of this particular edition. A reissue with a different year is a distinct album on purpose.
[album] Exactly one primary type: album, single, ep, broadcast, or other.
Secondary types Optional extra brackets such as [compilation], [live], [remix], [soundtrack], or [spokenword].
(complete) Completion status: (complete), (7 of 12 tracks), (incomplete), or (unknown).
(flac) The audio format actually in the folder. A mixed folder lists both, as in (aac+mp3).
(xmas) A marker added to Christmas and holiday albums.

MusicBrainz Picard builds the core of these names from fixed rules. The pipeline later adds the format and holiday markers and keeps the completion note current. The charter treats the whole name as the structural truth: a folder name outranks a tag or an inferred guess. Picard's rules also change a few characters Windows dislikes: a colon becomes a spaced dash, a question mark disappears, and a double quote becomes a single quote. A title on disk can therefore differ slightly from the one on MusicBrainz. Ingesting Music shows where those rules come from.

Two small guards keep the names honest. The completion status comes from comparing the files with the release's official tracklist, and tools are not allowed to guess it from tags. And a (disc 2) that appears inside a folder name is just part of a release's title; multi-disc sets show their discs in the track file names, as 1-01, 2-01, and so on.

Category folders

A few folders have an exclamation mark in front. They are categories, not artists, and scripts never treat them as performers:

  • ! Soundtrack for film, television, and game soundtracks, judged at album level.
  • ! Various Artists for multi-artist compilations. Completeness applies to the album, but nothing is averaged per artist.
  • ! VA Christmas for holiday compilations, kept apart so they can be reported on their own.
  • ! Unknown Artist for albums whose artist could not be established.

Picard routes an album in a fixed order: soundtrack first, then Christmas compilations, then other compilations, then the album artist's own folder, then Unknown Artist. A leading "The" is dropped from artist folder names, so the Beatles file under B.

Classical music

Classical is filed by performer, not composer. A soloist or an ensemble gets the folder when one performs throughout. An orchestral work goes under the orchestra, with the conductor optionally appended. An anthology with many performers goes to Various Artists. There is deliberately no "Classical" category folder.

The composer lives in the tags, in the composer field, with the work named in its own field. Those tags are what Lyrion's Composer and Works menus read. So the rule of thumb is: find a performer by folder, find a composer by tag.

Track file names

A track file is 01 - Title, or 1-01 - Title on a multi-disc set. On a compilation, where the track artist differs from the album artist, the artist is appended: 01 - Title - Artist. File names are capped at 75 characters, cut to 72 plus an ellipsis, so paths stay under the Windows limit.

The notebook beside every album

Every album folder carries a small notebook, a file called album-metadata.json. The charter names the Music Manager (LMM) as the one authoritative record of metadata, and this file is how it keeps its records. It holds:

  • every tag from every track, stored as found, so nothing is lost in translation
  • the technical facts: codec, bit rate, sample rate, bit depth, duration
  • what the outside databases said (MusicBrainz, Discogs, lyrics from LRCLIB)
  • corrections the system is proposing, each with a confidence label
  • oddities it has noticed, such as tracks that disagree about which release they belong to
  • a permanent local ID for the album, for each track, and for each musician

Two companions are generated beside it: a readable summary of the same information, and a small record of how the last extraction went. Reports and checks read the notebooks rather than rescanning the disks over and over, which is why a nightly run over a very large library stays quick.

Quality tiers

Audio quality is sorted into tiers that guide the thinking rather than enforce anything:

Tier What it covers Status
Lossless FLAC, ALAC, APE, WavPack, PCM The end state.
High-quality lossy AAC or MP3 at 256 kbps or more An acceptable interim.
Standard lossy AAC or MP3 from 128 to 255 kbps Below acceptable.
Low-quality lossy Anything under 128 kbps A priority to replace.

Should I buy it?

The charter includes a small decision table, and it powers a companion phone app that scans a barcode in a record store and answers "do I need this?" before the cashier does:

What the library holds What to do
Incomplete, and the missing tracks are known Buy it, to complete the album.
Incomplete, but the missing tracks are not known Consider buying it.
Complete and lossless Do not buy it.
Complete, low or standard lossy Upgrade to lossless when convenient.
Complete, high-quality lossy Wait for a lossless upgrade.
Complete, but the encodings are mixed Consider buying it, to fix the format.

Ground rules

The charter keeps a few principles, and the tools are built around them:

  • Never delete or overwrite blindly.
  • Never make the audio worse.
  • Respect the structure a human put there.
  • Prefer clear signals over guesses.
  • Progress beats perfection.

It also settles who may change what. I am the AI librarian. I interpret the data, find gaps, and propose low-risk fixes, but I do not change the files or the audio without direction: the AI advises, and Mike decides. Inside the automated pipeline, a single stage is allowed to write tags back to audio files, and it does so only for changes that are marked ready, with backups and verification. The rest of the pipeline reads, reports, or renames. The Pipeline shows how that works in practice, and AI Assisted Music Management shows where Lyra's judgment fits.

Next: Ingesting Music follows an album from the disc to its place on the shelf.