Re: FreeDB Search
Ian McEwen <[email protected]>
| Newsgroups | gmane.comp.audio.musicbrainz.devel |
|---|---|
| Message-ID | <[email protected]> |
On Sat, Jul 05, 2014 at 12:03:53PM +0530, Abhinav Jangda wrote: > Hello all, > > I am working on "Add MusicBrainz Support to EasyTAG" in GSoC 2014. I have to replace the current CDDB code with new MusicBrainz code. In CDDB code there is a feature through which you can generate a discid and then search over the FreeDB or CDDB data base using there portal. I have a few tracks selected and generate the FreeDB DiscID and a query string which will be used to search over the FreeDB server. > I am using MusicBrainz FreeDB Gateway and search with the following query, here DiscID is 24028103: > > http://freedb.musicbrainz.org//~cddb/cddb.cgi?cmd=cddb+query+24028103+3+150+17850+34875+641&hello=noname+localhost+EasyTAG+2.2.1&proto=6%20HTTP/1.1 > > I get 211 results. You get a 211 *code*, i.e., inexact matches. I only see 39 results. Still more than below, as I'll explain there. > > Now if I use WebInterface of MusicBrainz, i.e. the following URL: > > http://musicbrainz.org/ws/2/freedb?query=discid:24028103 > This is searching freedb itself -- not, as the musicbrainz freedb gateway, searching the musicbrainz data using a freedb-like protocol. > I got just one result. > This is because freedb only has one result: try the same discid on http://www.freedb.org/freedb_discid_check.php The /ws/2/freedb search endpoint only searches actual freedb data, not musicbrainz's data at all, so that's not in fact using musicbrainz, except for our search indexes :) > Can anyone please help me and tell me how can I use WebInterface of MusicBrainz for FreeDB search? > If you'd like to use musicbrainz properly with disc-based IDs, you'll want to use MusicBrainz DiscIDs, rather than FreeDB ones. There's a variety of tools that will generate them, perhaps most notably and usefully libdiscid: https://musicbrainz.org/doc/libdiscid -- there are also bindings to libdiscid in a variety of languages, depending on what EasyTAG's codebase is written in. MusicBrainz DiscIDs look like I5l9cCSFccLKFEKS.7wqSZAorPU- -- that is, 28 characters that are base-64 encoded. I'd recommend using a binding such as libdiscid, but if you're curious about the details of DiscID calculation, they're available from https://musicbrainz.org/doc/Disc_ID_Calculation. MusicBrainz DiscIDs also include more information than a CDDB one, and throw away less, thus resulting in a better matching. DiscIDs can then be looked up using the /ws/2/discid endpoint, e.g. http://musicbrainz.org/ws/2/discid/I5l9cCSFccLKFEKS.7wqSZAorPU-. Please also look at the documentation for that endpoint, at http://musicbrainz.org/doc/Development/XML_Web_Service/Version_2#discid, since there are details about the inclusion of CDStubs (you may or may not want to include them -- they're included by default) and the ability to provide a 'toc' parameter, which allows for fuzzy lookup (which is almost certainly desirable -- the FreeDB gateway uses a similar fuzzy lookup to produce the results you saw there). If you'd like to go a step further than only CD/DiscID based matching, integration of AcoustID (https://acoustid.org/) or metadata-based lookups via the rest of our web service, as documented for the current version at http://musicbrainz.org/doc/Development/XML_Web_Service/Version_2 -- but I don't know the exact details of your GSoC project, of course :) Good luck! > Thank You, > Abhinav > > _______________________________________________ > MusicBrainz-devel mailing list > [email protected] > http://lists.musicbrainz.org/mailman/listinfo/musicbrainz-devel _______________________________________________ MusicBrainz-devel mailing list [email protected] http://lists.musicbrainz.org/mailman/listinfo/musicbrainz-devel
signature.asc
(application/pgp-signature, 198 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iEYEARECAAYFAlO3pfQACgkQq+0avXExp28oHwCgkOo0r3lGKYdzi7NHOwfpYROK nNsAoKNbDK/hMgfrL/wFXZVZZAAKD66z =oOik -----END PGP SIGNATURE-----