[Rel] HTTP Anidb Metadata Agent (HAMA)

As an example of how AniDB is unique, what other database will tell you that if you’ve watched episode 1 of Suzumiya Haruhi no Yuuutsu (2009), then you’ve also watched episode 2 of Suzumiya Haruhi no Yuuutsu, which aired in 2006.

Or that if you’ve watched Area 88 Gekijouban, then you’ve also watched the first 2 episodes of Area 88.

What databases have episode level tags, so that you can go from the Christmas tag and then in the Anime you can go to the episode level tagging for that series to see which episodes have a Christmas event.

@Kyomujin
Thanks for the insight in how the AniDB database differs from other databases. I knew it didn’t use seasons like other databases, but I didn’t know it used ed2k hashes on files. Does this mean that HAMA could in theory do checksum comparisons on files and match with AniDB, or would that be too resource intensive or complicated for a scanner\metadata agent (whichever does the work)?

I tried getting Filebot to add the anidb-id during rename, but I had trouble manipulating the results from the variable. It has a variable named “series” which returns the anidb-id as “anidb::idnumber”, but when trying to remove the colons it just blanks the whole value. I will try fixing the expression, in which case that would be my solution to this for now. It will look kinda ugly to have a third party ID in the folder name, but if it works, it works :slight_smile:

@Kyomujin added double ids support hope i didn’t miss anything… can you please check?

@ZeroQI You missed brackets for list comprehension, but I’ve attached a version that appears to function correctly. I just added brackets at 4 places for list comprehension to enable the change you made

@rogergh
http://jmediamanager.org/ does just that and it seems to have a channel plugin for plex. Don’t know how good/bad it is, but it hashes files to identify where they belong, meaning you could in theory just dump all files in a single directory and it would still identify everything correctly. The downside is that it only works with anime.

As for using this logic in plex I wouldn’t know as I haven’t bothered to figure out the undocumented API, but the important thing would probably be if you can operate on a file level or a folder level. Though working on a file level with hashing has its downsides. e.g. with my library of around 2000 series or 7.7TB, would take at least a day to hash (assuming a constant 100MB/s read rate). Plex simply isn’t built for the anidb hashing logic, so even if it might be possible to coerce it to file logic, it probably wouldn’t be a nice solution.

As for renaming, most AniDB clients can do automatic moving of files into a desired folder structure, it would be a lot slow than your Filebot, as it would have to hash and move every single file, but you could try AniSub or one of the other clients stickied on the AniDB Forum

AniDB agent does that but slow as hell… You need to calculate the checksum for each file…
Source: https://forums.plex.tv/discussion/37750/anidb-metadata-agent/p1

Does this not work with os x sierra? I’ve been unable to get it to load and work on os x sierra but it was working fine before I upgraded to this OS.

The agent works with Ples Media Server, is written in python so OS agnostic, apart for logs location…
Please read the read-me and follow the troubleshooting steps and attach logs listed…
Link is in my signature

@ZeroQI said:
The agent works with Ples Media Server, is written in python so OS agnostic, apart for logs location…
Please read the read-me and follow the troubleshooting steps and attach logs listed…
Link is in my signature

Never mind I figured that part out. I get the absolute scanner, no hama to chose. I’ll keep working on it. I just wanted to make sure the now OS was supported.

Check troubleshooting section. Check rights and agent system logs answer is in there

Having issues with renaming larger series like Naruto.with every season it shows in the screen it attaches the metadata from the beginning of the first season of the series.As you can see in the attachments.Please help me fix the issue.Thank You.





Need scanner log if forcing ids (tvdb2/anidb2 modes for examples).
Need agent logs. Please READ the readme https://github.com/ZeroQI/Hama.bundle and attach logs (specified in T/S section)

Thank You for Responding.Here are the logs

After reading your post, I changed the name of the folder and forced tvdb id.Now its Working fine.I think the issue was the scanner taking the episode names from anidb even if the episodes are renamed with season numbers.Since anidb uses absolute numbering instead of season wise numbering this issue has arised.Thank you ZeroQl for making such a great add-on for plex

@loks1234 you are right there is an issue and will correct. hama should have know there was seasons and any serie in abs mode in mapping file with seasons is affected

https://github.com/ZeroQI/Hama.bundle/issues/103 created fix uploaded will fix many series

HAMA Can’t pull posters from anidb if its adult content.

@Munchkin_ did you tick “Include adult content” in the agent settings ? if yes include hama log

@ZeroQI Yes.

. . . . . . .

Updated to the latest version available on github today and Hama no longer downloading any metadata, don’t know if this is related to the above mentioned problem on adult content metadata.

When downgrading to the only other version I still seem to have a backup on (Feb 2016) metadata downloads just fine and seems significantly faster then the latest version. It appears that on the latest version it goes into a loop when trying to download the metadata. Since it won’t allow me to attach logs, Ive uploaded them to google drive. See link below

https://drive.google.com/drive/folders/0B0p08Avg8EvUN0RZVUs5OHlITHM?usp=sharing