A command-line tool that hands a video to a multimodal model and makes one
structured-generation call per requested analysis mode. Each mode pairs a
theoretical prompt with a Pydantic schema, attached to the call as a JSON schema
for structured output, so the model must return JSON conforming to that shape;
responses are parsed with model_validate_json and raise on failure. Output goes
to a formatted terminal view, a JSON file, or a local SQLite archive.
Model access goes through a provider registry with three adapters, selected by flag. The default uploads the video file to Gemini and polls until it is processed. An OpenRouter adapter compresses the video, optionally strips its audio, and sends it to a hosted model. An Ollama adapter extracts a fixed number of frames with ffmpeg and sends them as images to a local model, with the mode’s schema passed as the structured-output format. The analysis modes run on any of the three; the numeric chart modes are Gemini-only.
Twenty-eight modes are selectable by flag. Four are descriptive: captions, paragraph, key moments, table. The rest are analytical, most named for the theorist whose framework the prompt and schema encode — Levinas, Baudrillard, Foucault, Virilio, Žižek, Barthes, Benjamin, Rancière, Sontag, Haraway, Marks, Chion, Bazin, Eisenstein, Greenberg, Ngai — alongside modes for affect, rhythm, the gaze, the sublime, camera kinetics, epistemic truth-claims, hauntology, and a sizzle mode that reads footage the way an editor on deadline would. Three further chart modes return numeric per-scene series. The schemas are specific rather than decorative: a Žižek moment carries a parallax enum, a Lacanian register, the ideology at work, an optional obscene supplement, and the gap between; a hauntology moment carries temporal pathology, capitalist realism, smoothness, and booleans for whether suffering is individualized and whether the achievement-subject is present.
An optional local pass computes a numeric chaos index before the model call, on a 1–10 scale derived from the footage’s cut density and scene-change scores, and prepends it to the prompt as context, so the model’s qualitative read of “chaotic” footage is anchored to a measured signal. A flag strips the audio track before upload to reduce token cost.
The archive is a SQLite database with a videos table, one dedicated table per heavily-schematized mode, a generic fallback table for the rest, project tables, and an FTS5 virtual table for full-text search across everything analyzed.
A FastAPI web UI serves timecode-synced reading over the archive. A separate documentary directory holds hand-authored shot lists, voiceover scripts, and an edit-decision list, plus a script driving ffmpeg to cut and concatenate timecoded clips — a manual downstream step that consumes the archive.