Skip to main content

SeaDexArr

Actions License

SeaDexArr

SeaDexArr is designed as a tool to ensure that you have Anime releases on the Arr apps that match with the best releases tagged on SeaDex. SeaDexArr supports both Sonarr and Radarr.

For Sonarr, it works by scanning through series, matching these up via the TVDB or IMDb IDs to AniList mappings via the PlexAniBridge-mappings and ultimately finding releases in the SeaDex database. For Radarr, this works much the same but instead using the TMDB and IMDb IDs.

SeaDexArr will then do some cuts to select a "best" release, which can be pushed to Discord via a bot, and added automatically to a torrent client. This should make it significantly more hands-free to keep the best Anime releases out there.

There are then two options for how SeaDexArr will filter releases to grab:

Against existing files (default; use_torrent_hash_to_filter = False):

SeaDexArr will attempt to match these releases to release groups in Sonarr/Radarr, and for Sonarr will also try to parse filenames to check against individual episodes. SeaDexArr also checks against filesizes, to attempt to catch when release groups put out updated releases, or those at higher quality.

Against torrent hashes (use_torrent_hash_to_filter = True):

SeaDexArr will match releases to torrent hashes in the cache. This will ensure that if releases get updated then they will be grabbed. However, if you already have an existing library then this could result in torrents being downloaded again, and will grab multiple overlapping results if you aren't in interactive mode.

By default, SeaDexArr will not check a particular release again unless SeaDex has updated recently. You can override this behaviour by setting ignore_seadex_update_times to True in the config (see config section below).

[!TIP] If you make changes to your config, you should probably remove your cache. You can do so by CLI, use seadexarr cache remove (see below for more details).

Installation

SeaDexArr is available as a Docker container. Into a docker-compose file:

services:

  seadexarr:
    image: ghcr.io/bbtufty/seadexarr:latest  # or seadexarr:main for the cutting edge
    container_name: seadexarr
    environment: 
      - SCHEDULE_TIME=6  # How often to run, in hours
    volumes:
      - /path/to/config:/config
    restart: unless-stopped

And then to run on a schedule, simply run docker-compose up -d seadexarr. If you want to run one Arr one time, you can instead run like docker-compose run seadexarr run single --radarr --sonarr.

SeaDexArr can also be installed via pip:

pip install seadexarr

Or the cutting edge via GitHub:

git clone https://github.com/bbtufty/seadexarr.git
cd seadexarr
pip install -e .

CLI

SeaDexArr features a command-line interface, with a number of modules. If running in Docker mode, to run these simply add a docker run before the command below.

seadexarr run

There are two options here, run scheduled and run single. Scheduled is the default mode, and will run if you just enter seadexarr into the command line, which will run every few hours (default 6) to keep things up to date automatically. Single will just run once and be done. For the single run, pass --sonarr or --radarr to run the Sonarr or Radarr modules. Scheduled runs automatically for both

seadexarr config

To generate a blank config file, simply enter config init. You can then populate to your liking.

seadexarr cache

There are a number of cache commands: cache backup will rename cache.json to cache.backup.json, cache restore will restore this backup, and cache remove will remove the cache file. This can be useful if you've changed the config and want to do a fresh run.

Scripting

To run SeaDexArr in a Python script, the code is simple:

from seadexarr import SeaDexSonarr, SeaDexRadarr

sds = SeaDexSonarr()
sds.run()

sdr = SeaDexRadarr()
sdr.run()

On the first run, the code will generate a config file in your working directory. This should be populated to your own preference, and then run the code again.

How SeaDexArr chooses a release

SeaDexArr performs a number of cuts to get to a single best release for you. First, it will filter out all torrents that have any tags as defined in ignore_tags. Then, it will filter out all torrents coming from trackers that haven't been specified (if you haven't been more granular, this will be all public trackers and potentially all private trackers; see trackers). Then, if you only want public torrents (public_only), it will filter out anything from a private tracker. Next, if you only want to grab releases marked by SeaDex as "best" (want_best), it will down-select any torrents marked as "best", as long as there's at least one. Finally, if you want dual audio (prefer_dual_audio), it will down-select any dual-audio torrents, as long as there's at least one. If this is instead set to False, it will do the opposite, filtering out any dual-audio torrents (so long as there's at least one not tagged as dual-audio). By doing this, SeaDexArr should generally find a single best torrent, though if you're in interactive mode (interactive) and there are multiple options that match your criteria, it will give you an option to select one (or multiple).

Config

There are a number of configuration settings to play around with. These should be self-explanatory, but a more detailed description of each is given below.

Arr settings

  • sonarr_url: URL for Sonarr. Required if running SeaDexSonarr

  • sonarr_api_key: API key for Sonarr (Settings/General/API Key). Required if running SeaDexSonarr

  • ignore_movies_in_radarr: If True, will not add releases found in Sonarr (movie specials) if they already exist as movies in Radarr. Defaults to False

  • radarr_url: URL for Radarr. Required if running SeaDexRadarr

  • radarr_api_key: API key for Radarr (Settings/General/API Key). Required if running SeaDexRadarr

Torrent settings

  • qbit_info: Details for qBittorrent. This requires a host URL, username, and password to be set. Required if using qBittorrent
  • sonarr_torrent_category: Sonarr torrent import category, if you have one. Defaults to None, which won't set a category
  • radarr_torrent_category: Radarr torrent import category, if you have one. Defaults to None, which won't set a category
  • torrent_tags: Tags to add to the torrent when added to a client. Defaults to None, which won't add any tags
  • max_torrents_to_add: used to limit the number of torrents you add in one run. Defaults to None, which will just add everything it finds

Private tracker settings

  • ab_passkey AnimeBytes passkey. Can be found in profile → account.

Discord settings

  • discord_url: If you want to use Discord notifications (recommended), then set up a webhook following this guide and add the URL here. Defaults to None, which won't use the Discord integration

SeaDex filters

  • public_only: Will only return results from public trackers. Defaults to True
  • prefer_dual_audio: Prefer results tagged as dual audio, if any exist. If False, will instead prefer Ja-only releases. Defaults to True
  • want_best: Prefer results tagged as best, if any exist. Defaults to True
  • ignore_tags: Can filter out based on SeaDex tags. Some examples:
    • Dolby Vision
    • Misplaced Special
    • Deband Required
  • trackers: Can manually select a list of trackers. Defaults to None, which will use all the public trackers and private trackers if public_only is False. All trackers with torrents on SeaDex, and whether they are supported are below.
    • Public trackers
      • Nyaa (supported)
      • AnimeTosho (supported)
      • AniDex
      • RuTracker (supported)
    • Private trackers
      • AB (supported)
      • BeyondHD
      • PassThePopcorn
      • HDBits
      • Blutopia
      • Aither

Advanced settings

  • ignore_seadex_update_times: If True, will not check against the update times in the cache to decide whether to search for a release. Defaults to False
  • use_torrent_hash_to_filter: Can either try and filter by release groups in Sonarr/Radarr (False), or by torrent hashes in the cache (True). Defaults to False. See a more detailed description above
  • sleep_time: To avoid hitting API rate limits, after each query SeaDexArr will wait a number of seconds. Defaults to 2
  • cache_time: The mappings files don't change all the time, so are cached for a certain number of days. Defaults to 1
  • interactive: If True, will enable interactive mode, which when multiple torrent options are found, will ask for input to choose one. Otherwise, will just grab everything. Defaults to False
  • anibridge_v3_mappings: Can provide custom AniBridge mappings here. Otherwise, will use the PlexAniBridge mappings. Set to False to disable AniBridge mappings entirely. The general user should not set this. Defaults to None
  • log_level: Controls the level of logging. Can be WARNING, INFO, or DEBUG. Defaults to "INFO"
  • nyaa_host: Configures an alternative hostname to use when connecting to nyaa. Defaults to "nyaa.si"

Roadmap

  • Support for other mappings between TVDB/TMDB/IMDb and AniList IDs
  • Support for other torrent clients
  • Support for more torrent sites

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

seadexarr-1.0.0.tar.gz (173.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

seadexarr-1.0.0-py3-none-any.whl (61.0 kB view details)

Uploaded Python 3

File details

Details for the file seadexarr-1.0.0.tar.gz.

File metadata

  • Download URL: seadexarr-1.0.0.tar.gz
  • Upload date:
  • Size: 173.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for seadexarr-1.0.0.tar.gz
Algorithm Hash digest
SHA256 e477f66efc73c0dbf98a98234bec015ace2aedada8469ce90bf585cf456f9d6b
MD5 b997b5322ccb4c79f6bf437d864f477b
BLAKE2b-256 d377ef79e66fe7b4a960b958f12c8a4727dcf0a7343ec33ca8d3d01b10bc268f

See more details on using hashes here.

File details

Details for the file seadexarr-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: seadexarr-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 61.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for seadexarr-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 edaee3cfd3a22a4e778bdd7916962f322a616731888c8164e3ca879610205618
MD5 5e3938e9b936f135a88f359d57e74a78
BLAKE2b-256 8c2b29a71306bf82f6981a225e852007bf71503c10bd401944536406eb6e09f8

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 files

0.9.0

2 files

0.8.1

2 files

0.8.0

2 files

0.7.0

2 files

0.6.0

2 files

0.5.0

2 files

0.4.1

2 files

0.4.0

2 files

0.3.0

2 files

0.2.0

2 files

0.1.0

2 files

0.0.3

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page