The Code is here: https://github.com/runecalico/filebot-public
What is my use case?
I shotgun download Anime from a multitude of Release Groups, to the tune of thousands of files a week.
I do not have the desire nor the time to manually sort them, and I ultimately use AniDB to track and sort my Collection (30%+ of AniDB)
Filebot & AMC are great tools, and everything considered work very very well.
I however wanted to use AniDB metadata, and for the initial sorting of the incoming files I have no interest in FILE renaming, just sorting them into the "correct" Series/Season as per AniDB. Movies and OVA/ONA etc included.
AMC in strict mode produces an acceptable amount of "incorrect" matches, but an unacceptable (to me) total amount of what *is* matched.
AMC in Non-Strict mode produces an unacceptable (to me) amount of "incorrect" matches, but matches almost everything.
You can Forget about AniDB for movies, and OVA/ONA/OAD often don't match either.
I needed something to sort the raw incoming files with "high" accuracy (additional stages will be used to prune the files down to what I want to keep or add to AniDB)
What does the script do?
It tries to take the filename and from it, produce an likely match to AniDB (and TVDB), and then perform a rename. The "Default" rename format doesn't rename the file, but places it in a directory that hopefully has the AniDB metadata and AID in the directory name (there are still some issues using TVDB for lookups but expecting AniDB metadata).
Code: Select all
movieFormat = any { movieFormat } { _args.format } { '{ \'movies\' }/\n' +
' { any { db.AniDB.n.replaceAll(/\\\\|\\//, \'\') } { db.AniDB.primaryTitle.replaceAll(/\\\\|\\//, \'\') } { db.TheTVDB.n.colon(\' - \').replaceTrailingBrackets().replaceAll(/\\\\|\\//, \'\') } { n.replaceAll(/\\\\|\\//, \'\') } }\n' +
' { any { if (db.AniDB.id) \'[anidb-\' + { db.AniDB.id } + \']\' } { if (order.airdate.db.AniDB.id) \'[anidb-\' + { order.airdate.db.AniDB.id } + \']\' } { if (order.absolute.db.AniDB.id) \'[anidb-\' + { order.absolute.db.AniDB.id } + \']\' } { \'[tvdb-\' + db.TheTVDB.id + \']\' } { \'[tmdb-\' + tmdbid + \']\' } }\n' +
'/ { fn }' }
Does it work?
It Minimally meets the my initial requirements.
- It supports Series, Specials and Movies
It matches more then AMC Strict, but less the AMC Non-Strict
It has an acceptable number of false matches
It uses AniDB exclusively for Movies, and tries to use TVDB only when I think Filebot can map the data to AniDB (this part needs work)
It also has greatly reduced AniDB usage due to local usage of several files for Title "matching" (Aka I get the AniDB Ban Hammer *less* then with AMC because it only requests episodes for specific series)