Skip to main content

Marcarr

marcar: to mark.

Marcarr is a self-hosted service that runs next to Plex. It looks at each film or episode once and records what is in it: camera cuts, subtitle lines, scenes, measured signals, faces, cast and tags ("christmas", "rain", "a cave"). Other apps ask Marcarr instead of analysing the file again.

Its first two clients are FansCut, which builds cuts from tagged scenes, and Doblarr, which dubs and needs to know where a line is said and who is on screen.

On its own

You don't need FansCut or Doblarr to use Marcarr. Point it at your Plex server and it gives you:

  • Scene search across your library: every rain scene, every Christmas dinner, every scene with a given actor, with the film and the time it starts.
  • Plex labels and collections: films with a tag get a label (marcarr:christmas), so a Kometa or smart-collection rule can build a "Christmas scenes" row.
  • A review page: accept, fix or reject what the AI proposed, scene by scene.
  • Tools for AI clients: an MCP server, so an assistant can ask "where does this happen?" or tag a scene itself.
  • An API and one JSON file per video: for any other tool that wants to know what is in a file without decoding it.

Install

Marcarr needs ffmpeg (the Docker image and the Windows bundle include it) and, for analysis, access to the same video files Plex sees. It listens on port 7470; the first run opens a setup page for Plex.

Docker (Linux, macOS, Windows, NAS)

mkdir -p config && chown -R 1000:1000 config      # the container runs as uid 1000
docker run -d --name marcarr -p 7470:7470 \
  -v ./config:/config \
  -v /path/to/media:/data:ro \
  ghcr.io/jhd3197/marcarr:latest

Or with Compose: download docker-compose.yml, edit the media path and MARCARR_PLEX_URL, then docker compose up -d. Open http://localhost:7470.

First start (0.2.0+): the setup screen makes Marcarr's admin key, shown once, and signs your browser in. Docker's port forwarding makes your browser count as another machine, so the screen asks for the setup code printed in docker logs marcarr. Or set MARCARR_ADMIN_KEY, or run docker exec -it marcarr marcarr admin-key. See SECURITY.md. Upgrading from 0.1.x? Read the CHANGELOG first.

  • /config holds config.yaml and Marcarr's data (database, caches, face models, log).
  • Mount your media where Plex sees it (the compose file uses /data), or map Plex's paths to the container's in Settings > Plex.
  • Secrets can come from the environment: MARCARR_PLEX_TOKEN, MARCARR_AI_API_KEY, MARCARR_TMDB_API_KEY (each also as ..._FILE for Docker secrets).
  • Marcarr answers only to host names that cannot be someone else's domain: localhost, LAN IPs, single-word names like marcarr and LAN names like nas.local. Behind a reverse proxy or on a public IP, list the name in MARCARR_ALLOWED_HOSTS (comma-separated), or you get HTTP 421.
  • Images are linux/amd64 and linux/arm64. Tags: latest, 0.2.0 and 0.2 for each release. To build it yourself: docker compose up -d --build.

Windows (portable)

Download Marcarr-<version>-windows-x64.zip from the latest release, unzip it, and double-click Marcarr.bat. Python and ffmpeg are inside; your settings and data stay in the config folder next to it. No installer, nothing to uninstall. (There is a .sha256 file next to the zip to check the download.)

pip / pipx (any OS)

pipx install "marcarr[all]"        # or: pip install "marcarr[all]"
marcarr serve                      # http://127.0.0.1:7470

The extras:

Install What you get
marcarr the shared parts other apps build on (marcarr.common, marcarr.client, marcarr.api); light, no video libraries
marcarr[analysis] what marcarr serve and marcarr analyse need: numpy, Pillow, Prompture (media + OpenAI)
marcarr[faces] who is on screen (OpenCV)
marcarr[mcp] marcarr mcp
marcarr[all] all of the above: the full app, as in the Docker image and the Windows bundle

Without [analysis], marcarr serve and marcarr analyse stop and say what to install.

Install ffmpeg first (winget install Gyan.FFmpeg, brew install ffmpeg, apt install ffmpeg). Config is ./config.yaml, or the path in $MARCARR_CONFIG.

From source

python -m venv .venv && .venv/Scripts/pip install -e ".[all,dev]"   # or bin/pip
cd ui && npm install && npm run build && cd ..
marcarr serve                      # http://127.0.0.1:7470

Settings are in config.yaml (see config.example.yaml); the Settings page edits it.

Other commands: marcarr scan (read Plex once), marcarr analyse <file> (one file, no Plex), marcarr mcp (MCP server on stdio), marcarr status.

For UI work without Plex: python scripts/seed_demo.py --config demo/config.yaml video.mp4, then marcarr --config demo/config.yaml serve, and npm run dev in ui/ (proxies /api to port 7470).

Layout

  • marcarr/stages/: the analysis code taken from FansCut (subtitles, scenes, signals, cast, faces, the tagger and its prompts, the 130-tag list).
  • marcarr/pipeline.py: the seven steps per video, states, staleness, cost.
  • marcarr/routes/: the v1 API. ui/src/api/types.ts is the contract.
  • ui/: React + Vite, built from the design in docs/design/.

Connecting FansCut and Doblarr: docs/CLIENTS.md. Building on Marcarr: docs/API.md (embedding) and docs/COMMON.md (shared infrastructure). The plan: docs/PLAN.md.

Releases

Everything is automatic from a GitHub release. Bump __version__ in marcarr/__init__.py, merge dev into main, then publish a release tagged v<version>:

  • publish.yml uploads the package to PyPI (needs the PYPI_TOKEN secret).
  • release.yml pushes the Docker images to GHCR (ghcr.io/jhd3197/marcarr) and attaches the Windows zip to the release. To also publish to Docker Hub, add the DOCKERHUB_USERNAME and DOCKERHUB_TOKEN secrets. GHCR creates the package as private the first time: set it to Public in the package settings.

ci.yml runs on every pull request and on pushes to dev and main: ruff and pytest (Linux Python 3.11 and 3.12, Windows 3.12), mypy (once, on Linux 3.12), the web UI typecheck, tests and build, a Docker build with a start-up check, and a full build and start-up check of the Windows bundle.

Metadata

Release files for marcarr 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for marcarr 0.2.0
File Size Uploaded Provenance Actions
marcarr-0.2.0.tar.gz 492.5 kB Without provenance Details for marcarr-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for marcarr 0.2.0
File Interpreter ABI Platform Actions
marcarr-0.2.0-py3-none-any.whl Python 3 none any Details for marcarr-0.2.0-py3-none-any.whl

Total release size: 961.4 kB

Release files / marcarr-0.2.0.tar.gz

Download URL marcarr-0.2.0.tar.gz
Size 492.5 kB
Tags Source
SHA-256 checksum
How to use checksums
51c868f7dec16c84a83af08a06e2b4cc85be40c7fadfa1d15ed5430f253860b8
BLAKE2b-256 checksum
How to use checksums
d9f61452610f6a6c96628f9596d14b118e16ac39d0607604d234647ed2f0da23
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Release files / marcarr-0.2.0-py3-none-any.whl

Download URL marcarr-0.2.0-py3-none-any.whl
Size 469.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7118a981bb9a82df386b19890dffb46b455c16a9a108b418919951dd8b3b80fe
BLAKE2b-256 checksum
How to use checksums
9129f1c3012e4492b95d96eb109428b9d46b5e91307219f44f11896b3f4d177d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Security for marcarr 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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