Multiple mbid for the same track?

Hello everyone!

I’m trying to use AcousticBrainz and MusicBrainz to do a machine learning university project. My intention is to loop through playlists, retrieve the mbid of each track from MusicBrainz and then use it to fetch the data I need from AcousticBrainz.

My problem is that there are multiple mbid for the same track(I used the Black crowes example for testing) and only one of those mbids maps to the data in acousticbrainz. Am I doing something incorrectly? Thank you for any help

When entities in MusicBrainz’ database are merged, all MBIDs are retained so old metadata in files will continue to point to the relevant MusicBrainz entity. So that you are seeing multiple MBIDs on one track (though I think you are talking about the recording, not the track) is perfectly normal.

See for more information the documentation about MBIDs and merging.

2 Likes

Thanks @mfmeulenbelt .

I read the links you attached but it remains unclear how to figure out programatically which mbid is the “correct” one. Is there a way to do it ?

Do a lookup of either id in the musicbrainz database.
The results will contain the new id as one of the fields in the output.
It does not matter if you picked the old or new id both will contain the new id in the results.

2 Likes

Others have pointed out how MBIDs can merge together, but I’m wondering: what do you mean by “the same track”? Is that “same track name by the same artist” (ie., a recording)? Or is it the “same track on the same release”? If you’re not using precise (MusicBrainz) terminology, it can be hard to be sure we correctly understand your issue. :slight_smile:

If you mean the first case, there may be multiple Recordings of the same name by the same Artist that may or may not be candidates for merging. However, unless/until an editor looks over those Recordings and sees if there’s evidence enough to merge them, they’re going to stay as separate entities.

Also keep in mind that AcousticBrainz only covers a subset of all Recordings known to MusicBrainz. (As I’m writing this, AB reports 3,995,817 unique recordings while MB has 20,258,129 ones. And AB will have a number of duplicates as well, as recordings having been merged in MB isn’t reflected in AB yet (I didn’t find a separate ticket for this, but AB-115 touches on it).)

1 Like

Thanks I will try this shortly.

Hello @Freso Yes I meant the same recording, not the same track, the difference was just cleared out to me.

So basically the only solution, unless @dns_server suggestion works out is to do a bulk lookup on all the mbids of the same recording?

You still didn’t detail your concept of “sameness”, but most probably, yes. At least until MBS-3946 gets implemented, which you could then use to “group” Recording MBIDs:

Oh, and I kind of noted this before too, but AcousticBrainz has a number of duplicate Recording MBIDs that hasn’t gotten merged into their canonical MBID on the AB side. This may also result in some Recordings not getting a hit on the AB side of the merge target’s MBID didn’t have any submissions for it, so MBS-3946 could also be useful to check whether “old” AB submissions might be relevant.

1 Like

By sameness I mean same recording.

Thank you for your help, I got what I have to do.