Module acoustid

Source
Expand description

AcoustID: what a recording is, asked of its sound.

Deliberately no network, like crate::musicbrainz and crate::coverart: this module builds the address to ask and reads the answer somebody else fetched. Reaching it is the client’s job.

§What it answers, and what it cannot

Shown a fingerprint and a length, AcoustID answers with recordings — MusicBrainz recording identifiers, with a score saying how sure it is. A recording is a performance, not a release: the same recording appears on an album, a compilation and a deluxe reissue, so the answer identifies what is playing and not which pressing this file was ripped from.

That is the right answer for the question this feature exists to ask — “what is this untagged file?” — and the wrong one for “which edition do I own”, which the tags answer better than any fingerprint could.

§The score is kept, and it is not a certainty

Everything here arrives as crate::sources::Confidence::Matched, never Identified. A fingerprint match is a strong guess about a performance and is wrong in ways that are easy to picture: two masterings of one recording fingerprint alike, a live version and its studio original sometimes do, and a silent or very short track matches a great deal. The score comes back with the record so that a reader can see what they are being told.

§It identifies; it never corrects

Nothing here writes a tag, because nothing in Aède writes into an audio file. What the service says is filed beside the tags, in the attributed layer, and shown next to them — so a file whose audio and tags disagree is reported rather than quietly rewritten. Retagging is the user’s tagger’s job, and this is not one.

Structs§

Heard
What the service says one file is.

Constants§

KEY_VARIABLE
The environment variable holding the application key.
REQUEST_INTERVAL
The minimum recommended wait between two AcoustID requests.
SOURCE
The name records from this service carry in sources.json.
WEB_SERVICE
Base address of the lookup endpoint.

Functions§

best
The best thing the service said, or nothing.
key
The key this machine holds, when it holds one.
lookup_url
Where to ask about one fingerprint.
no_key
What to tell somebody who has no application key.
refused
true when the service reported a failure rather than an empty answer.