-
-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
/get
endpoint does not return the best match to the query
#26
Comments
recording-2024-10-22_14.11.24.mp4That's the widget I mentioned, you can see how it depends on correct timestamps. |
Your song album name is The track ID After normalizing, these became The best way to resolve this in my opinion is resubmitting the correct lyrics for your song's metadata, for example with LRCGET:
|
How come does it match album In addition to this, neither the track name nor the duration returned by the I was wondering how does the matching/comparison logic work internally; which fields are prioritised for the comparison? |
It just retries one more time, ignoring the album name parameter. The ID lrclib/server/src/routes/get_lyrics_by_metadata.rs Lines 51 to 54 in 0f567bc
|
I was aware of the duration comparison, but it's surprising to me that the difference in the Do you reckon we could prioritize exact matches here? |
I would be more than happy to contribute! |
Unfortunately it is not really exact, because of the extra word "volume". LRCLIB doesn't deduplicate the metadata, it is a very difficult matter that also requires contribution from community, and someone else does this better already (musicbrainz). Even if it could, there might be still minor syncing issue because of differences between CD rips and musics downloaded from digital/streaming platform. I know it sucks, I hate the fact that there are usually multiple duplicated lyrics records for the same song in LRCLIB. But this issue is almost impossible to resolve.
All of the strings are normalized (converting to lowercase, removing special characters and accents from accented character). In your case:
So they are considered an exact match. The part of the code that does the normalization is here: Lines 7 to 20 in 0f567bc
|
I'd love to have your contribution! But, we need to come to an agreement on the best way to address this first. |
This makes a lot of sense. My last straw then is the |
Hi @tranxuanthang, following your suggestion under beetbox/beets#5406 I now attempt to find matching lyrics using the
/get
endpoint, and only perform/search
if they could not be found.Thanks to synced lyrics availableion this database, the other day I added lyrics display in my music widget, which depends on accurate timestamps, and I noticed that lyrics are out of sync for some tracks.
One of them was this track:
Artist: Armin van Buuren Feat. Laura V
Title: Drowning (Avicii Remix)
Album: A State Of Trance Classics 14
Duration: 473.0
I checked and found its lyrics were fetched using the
/get
endpoint:Note that I receive the same data when I provide the
duration
field:When I perform the search for the artist and title
I see the following data
The lyrics I'm after are under id
12429604
, and it seems like it should be the closest match to my query. I can provide more examples if required.The results ranking algorithm I added in beetbox/beets#5406 picks up the correct lyrics.
The text was updated successfully, but these errors were encountered: