jellyfin-archive / jellyfin-plugin-anime

Anime Metadata Provider for Jellyfin
https://jellyfin.org
GNU General Public License v2.0
58 stars 24 forks source link

[suggestion] use anitomy to parse media titles #84

Open robertgzr opened 4 years ago

robertgzr commented 4 years ago

It seems to me that one of the biggest issues with detecting the actual titles from filenames is the often unpredictable naming scheme used by releases.

How about using anitomy to hand off this task? There seems to be a csharp port around that could be used if wrapping is not an option...

Rassilion commented 3 years ago

Also https://github.com/erengy/anime-relations (same owner) can be used for fixing absolute numbering issues. They created a season map table for anime shows, like "x anime 12-24 => x anime S2 1-12" or "y anime 13 => y anime OVA episode 0"

senritsu commented 3 years ago

This sounds like a great idea, I will try to see if I can get a proof of concept running if I find some time.

senritsu commented 3 years ago

Just as a heads up: initial testing looks good, but there is still a lot of work to do. Some of the providers are not exactly in a fully functional state, which complicates things a bit. Anitomy on its own might not yield massively improved recognition, but should improve some edge cases. I am not completely sure how it would work to integrate the anime-relations list, but I assume I should have a clearer idea some time soon.

GNY-001F2 commented 3 years ago

Would this also help fix episode numbers being incorrectly identified? For the life of me I have been unable to automagically identify any episode greater than 100. Plus there are SO MANY series where every episode gets plastered with the metadata for the first episode...

Oh, and some kind of NCOPED detection would also be nice.

senritsu commented 3 years ago

Believe me when I say, I certainly hope so 😩 I also have tons of issues (with emby previously, but mostly unchanged with jellyfin) with duplicates of episode 1 and all kinds of weird things.

At the very least I hope it is possible to relegate the NCOPED to Specials, and it would be great if it works out to fix absolute episode numberings properly, as well as large numbers. While I have a pretty good grasp of how the anime plugin works after reading the code for a while, unfortunately there are still lots of things that I don't get about how jellyfin works internally, especially if it is possible to "change" the series or season of a file away from its containing folder via the plugin. From documentation and everything it always seems like the preferred method is "just change your folder structure/filenames", but I would much prefer if that wouldn't be necessary.

senritsu commented 3 years ago

@GNY-001F2 Just to let you know, https://github.com/jellyfin/jellyfin/pull/5043 was just merged in core jellyfin, which should improve handling for episode numbers greater than 100.

GNY-001F2 commented 3 years ago

@GNY-001F2 Just to let you know, https://github.com/jellyfin/jellyfin/pull/5043 was just merged in core jellyfin, which should improve handling for episode numbers greater than 100.

I'm trying to set up shokofin to get around the problem as of this time.