v0.4.0 — free & open source · Windows / macOS / Linux

Media extraction and browser automation, entirely on your machine.

Operant is a Manifest V3 extension with a Python native messaging host. It captures streams from the page, hands them to ffmpeg and yt-dlp, and processes everything locally — no accounts, no servers, no telemetry.

Get started
Native messaging · handshake

01

What it does

The browser sandbox cannot spawn native binaries or reassemble heavy streams. Operant bridges that gap with a small, auditable local host.

Stream capture

Detects HLS (.m3u8) and DASH (.mpd) manifests through webRequest, plus images, video and audio in the DOM. Downloads are reconstructed with the real page Referer via ephemeral declarativeNetRequest rules.

Python native host

A standard-library-only daemon talks to the extension over stdio. It manages isolated ffmpeg and yt-dlp binaries under ~/Operant/bin without touching your PATH or system configuration.

Parallel downloads

Chunked range requests with concurrent queues, in-memory ZIP packaging and structured URL export for data pipelines.

ffmpeg pipeline

Remux, compress, resize, extract audio and merge split audio/video tracks — at native speed, outside the browser sandbox.

Side panel UI

A persistent Chromium side panel with grid and list views, filters by dimensions and media type, and live queue status.

Agent-ready

The native host doubles as a local gateway for automation: Playwright, Browser-Use or any Python tooling can drive the active tab without CORS constraints.

02

Three decoupled layers

Strict separation of responsibilities keeps the UI responsive, the interception event-driven and the heavy processing native.

1

Side panel

Vanilla JS · rendered on demand

  • Media detection and filters
  • Download queue manager
  • ffmpeg / yt-dlp console
chrome.runtime port messaging
2

Service worker & content engine

Manifest V3 · event-driven

  • DOM scanner (img, video, srcset, CSS backgrounds)
  • webRequest stream sniffer (m3u8, mpd, fMP4 segments)
  • declarativeNetRequest Referer injection
Native messaging · 4-byte LE framing over stdio
3

Python host daemon

operant_host.py · runs unsandboxed

  • ffmpeg: remux, compress, resize, audio extraction
  • yt-dlp: best video + audio merge
  • Local IPC gateway for automation tooling

03

A self-contained native host

operant_host.py uses only the Python standard library. No pip packages, no virtualenvs, nothing installed outside its own directories.

  • Isolated binariesffmpeg and yt-dlp are managed under ~/Operant/bin, separate from anything already on your PATH.
  • Silent on WindowsLaunched through pythonw.exe via a .bat wrapper, so no console window steals focus from the browser.
  • Integrity checksConcatenated fMP4 streams are validated (moov/mdat) before anything is written to disk.
  • Bidirectional IPC4-byte little-endian framing over stdio, with live download progress reported to the panel.
Registration
# Windows (Chrome / Edge)
native-host\install_host.bat <extension-id>

# Linux / macOS
./native-host/install_host.sh <extension-id>

# Registered paths
manifest: %APPDATA%\Operant\operant_host.json
binaries: %LOCALAPPDATA%\Operant\bin\
output:   ~/Downloads/Operant/

04

Status

Operant was designed to outgrow media capture. This is where it stands.

Shipped

Media core

DOM scanning, HLS/DASH sniffing, parallel downloads, in-memory ZIP export.

Shipped

Native host & ffmpeg

Stdlib Python daemon, managed ffmpeg/yt-dlp binaries, remux and merge pipelines.

In development

Agent deck

Accessibility-tree analysis and autonomous navigation via Browser-Use and local LLMs, dispatched through the native host.

05

FAQ

Direct answers about architecture, security and behavior.

Why does Operant need a native host?

Browser extensions run in a sandbox that cannot execute compiled binaries or access the file system freely. The native host is a thin, auditable bridge that lets ffmpeg and yt-dlp run at native speed with full file system access.

Is the native host safe?

It is written with the Python standard library only and its source is fully auditable. It communicates exclusively over stdio and only accepts messages from the exact extension ID registered on your system — no other program or web page can reach it.

How are HLS and DASH streams captured?

A content script scans media elements in the DOM while a webRequest observer watches for manifest requests (.m3u8, .mpd). When a segmented video is detected it appears in the side panel; from there the host downloads the fragments or lets ffmpeg assemble the stream directly.

Does Operant send any data anywhere?

No. There is no telemetry, no analytics and no intermediary server. Media detection, native messaging and ffmpeg processing all happen on your machine.

How will automation and AI be integrated?

Through the same native messaging channel. The Python host can run Playwright or connect to local LLMs (Ollama or APIs) to receive natural-language instructions from the panel and execute automation tasks on the active tab.

06

Get Operant

Free and open source under GPL-3.0-or-later. Download it, load it, audit every line.

Download for Chrome & Edge

The load-unpackable build of the current release. No build step, no account.

Chrome Web Store

The packaged build, one click from the toolbar.

Soon

Firefox Add-ons

The Firefox port, once the experimental build stabilizes.

Soon

Load it in Chrome

  1. Download the zip and unzip it
  2. Open chrome://extensions and enable Developer mode
  3. Click Load unpacked and select the operant folder
  4. Pin Operant from the extensions menu

Optional: to process media with ffmpeg and yt-dlp, install the native host afterwards.

Not sure where to start? Read the install guide