Dark Factory — Video Intake
Overview
Claude cannot read video or audio natively (the Read tool handles images, PDFs, and
notebooks only). This skill decomposes a video into things Claude can read — a
timestamped transcript and sampled frames — then guides turning that into
Dark Factory requirements via df-product-owner and df-data-transform-lens.
Two phases: Intake (mechanical, a script) → Extract (judgment, you + the DF skills).
When to Use
- The user hands you a video/recording/demo/walkthrough and wants it summarized, documented, or turned into requirements.
- "Can you watch / process / consume / transcribe this video?"
- "Extract requirements from this demo recording for the dark factory build."
- A screen-recorded SME/customer walkthrough that should become a PO requirements package.
Prerequisites
ffmpeg (+ ffprobe) — brew install ffmpeg (macOS) / apt install ffmpeg (Debian).
whisper-cpp — brew install whisper-cpp (provides the whisper-cli binary). The
ggml model auto-downloads to ~/.cache/whisper-cpp on first run and is reused after.
- On Apple Silicon whisper-cli uses Metal/GPU automatically (≈24 s for a 9-min clip).
If a tool is missing the script prints the exact install command and exits — install, then re-run.
Phase 1 — Intake (run the script)
One command does probe → audio → transcript → frames:
bash "${CLAUDE_PLUGIN_ROOT:-$HOME/.claude/skills/df-video-intake}/scripts/extract-video.sh" "<path/to/video.mp4>" [interval_seconds] [model]
interval_seconds (default 12) — one frame every N seconds. ~9 min → ~45 frames.
model (default small.en) — base.en (faster, ~148 MB) · small.en (best
quality/speed) · medium.en (slower, more accurate).
Output lands in <video-dir>/<video-basename>-extract/:
probe.txt, audio.wav, transcript.txt, transcript.srt (timestamped), frames/iv_NNNN.jpg.
Frame ↔ time: iv_NNNN.jpg ≈ (NNNN-1) × interval seconds in. This is the join key
back to the SRT.
Why fixed-interval, not scene detection
For screen recordings, ffmpeg scene-change detection (select='gt(scene,0.3)')
fails — the UI changes gradually (scrolling, inline edits), so it yields ~0 frames.
Fixed-interval sampling guarantees coverage and clean timestamp alignment. (Scene
detection is still fine for edited video with hard cuts — not the usual demo case.)
Phase 2 — Extract (read, then turn into DF requirements)
- Read
transcript.txt in full. For a narrated demo it carries ~80% of the
semantics and is cheap (text). The .srt gives you [mm:ss] timestamps to cite.
- Read frames selectively, guided by the transcript. Each image costs context, so
don't bulk-read all 45 — jump to the timestamps where the narration references a
screen/state (
iv_NNNN ≈ time/interval). The transcript says intent; the frame is
ground truth (demos often narrate one thing while showing another — frames catch it).
- Invoke the DF lens + PO skills — this skill ends where they begin:
df-data-transform-lens — name the data nodes (origin/authority/governance)
and transforms (pure|effect) the demo reveals.
df-product-owner — produce Vision + Requirements (data contracts + validation
rules) + Test Scenarios from the transcript+frames.
- Tag every claim
Confirmed (stated/shown) · Inferred · Assumption · Open.
A demo is one person's narration — never silently promote a guess to a requirement.
- Cite evidence inline:
[mm:ss] for narration, ivNNNN for the frame that proves it.
- Flag effects — any ask that sends/charges/notifies/writes-external or reads PHI
(e.g. "test against a real chart") so the SA assigns idempotency + compensation.
Output artifact convention
- Write the extraction as a new, source-derived doc next to the video (e.g.
requirements-docs/<name>-requirements-extraction.md), with frontmatter marking it
status: source-derived (NOT canonical).
- Do not silently mutate governed
docs/po/ docs. If the repo already has a PO
package, add a short "Relationship to existing docs/po" table mapping each extracted
requirement to existing scenarios (Inferred), and offer a separate reconcile/gap-check.
- End with an Open questions list — the things a cold Solution Architect would need
answered before designing (the
df-product-owner exit-gate test).
Verification
Worked example
A ~9-minute product demo, run through this skill end to end (intake script →
transcript+frames → df-product-owner), yielded a dozen requirements and several
state-change test scenarios in PO format. Keep your own worked examples in your
organisation layer, next to the artifacts they cite.
Troubleshooting
| Problem |
Cause |
Fix |
ffmpeg/whisper-cpp missing |
not installed |
run the printed brew install … line |
| Transcript empty / garbled |
non-English audio, or .en model on non-English |
use small / medium (no .en suffix) |
| Too many / too few frames |
interval wrong for length |
pass a larger interval for long videos, smaller for short |
| Wrong/garbled words for jargon |
acronyms/domain terms |
normal — confirm against frames; keep a glossary, tag Inferred/Open |
| Frames unreadable (tiny text) |
downscaled source |
zoom into the frame region, or lower interval near the key moment |
Resources
scripts/extract-video.sh — the intake pipeline (executed, not loaded into context).
- Pairs with:
df-data-transform-lens, df-product-owner (and downstream df-solution-architect).
1---2name: df-video-intake3description: Parse a video (mp4/mov/webm) into a transcript + timestamped frames so Claude can consume it, then extract context — specifically Dark Factory requirements — from it. Use when given a recording, demo, app walkthrough, screen recording, or "video" to summarize or turn into requirements/specs; when asked to "watch", "process", "consume", or "transcribe" a video; or to extract requirements/context from a demo for a dark factory build (PO vision, data contracts, validation rules, test scenarios).4---56# Dark Factory — Video Intake78## Overview9Claude cannot read video or audio natively (the Read tool handles images, PDFs, and10notebooks only). This skill decomposes a video into things Claude *can* read — a11timestamped **transcript** and sampled **frames** — then guides turning that into12**Dark Factory requirements** via `df-product-owner` and `df-data-transform-lens`.1314Two phases: **Intake** (mechanical, a script) → **Extract** (judgment, you + the DF skills).1516## When to Use17- The user hands you a video/recording/demo/walkthrough and wants it summarized, documented, or turned into requirements.18- "Can you watch / process / consume / transcribe this video?"19- "Extract requirements from this demo recording for the dark factory build."20- A screen-recorded SME/customer walkthrough that should become a PO requirements package.2122## Prerequisites23- `ffmpeg` (+ `ffprobe`) — `brew install ffmpeg` (macOS) / `apt install ffmpeg` (Debian).24- `whisper-cpp` — `brew install whisper-cpp` (provides the `whisper-cli` binary). The25 ggml model auto-downloads to `~/.cache/whisper-cpp` on first run and is reused after.26- On Apple Silicon whisper-cli uses Metal/GPU automatically (≈24 s for a 9-min clip).2728If a tool is missing the script prints the exact install command and exits — install, then re-run.2930---3132## Phase 1 — Intake (run the script)3334One command does probe → audio → transcript → frames:3536```bash37bash "${CLAUDE_PLUGIN_ROOT:-$HOME/.claude/skills/df-video-intake}/scripts/extract-video.sh" "<path/to/video.mp4>" [interval_seconds] [model]38```3940- `interval_seconds` (default **12**) — one frame every N seconds. ~9 min → ~45 frames.41- `model` (default **small.en**) — `base.en` (faster, ~148 MB) · `small.en` (best42 quality/speed) · `medium.en` (slower, more accurate).4344Output lands in `<video-dir>/<video-basename>-extract/`:45`probe.txt`, `audio.wav`, `transcript.txt`, `transcript.srt` (timestamped), `frames/iv_NNNN.jpg`.4647**Frame ↔ time:** `iv_NNNN.jpg` ≈ `(NNNN-1) × interval` seconds in. This is the join key48back to the SRT.4950### Why fixed-interval, not scene detection51For **screen recordings**, ffmpeg scene-change detection (`select='gt(scene,0.3)'`)52fails — the UI changes gradually (scrolling, inline edits), so it yields ~0 frames.53Fixed-interval sampling guarantees coverage and clean timestamp alignment. (Scene54detection is still fine for edited video with hard cuts — not the usual demo case.)5556---5758## Phase 2 — Extract (read, then turn into DF requirements)59601. **Read `transcript.txt` in full.** For a narrated demo it carries ~80% of the61 semantics and is cheap (text). The `.srt` gives you `[mm:ss]` timestamps to cite.622. **Read frames selectively, guided by the transcript.** Each image costs context, so63 don't bulk-read all 45 — jump to the timestamps where the narration references a64 screen/state (`iv_NNNN ≈ time/interval`). The transcript says *intent*; the frame is65 *ground truth* (demos often narrate one thing while showing another — frames catch it).663. **Invoke the DF lens + PO skills** — this skill ends where they begin:67 - `df-data-transform-lens` — name the data nodes (`origin`/`authority`/`governance`)68 and transforms (`pure|effect`) the demo reveals.69 - `df-product-owner` — produce **Vision + Requirements (data contracts + validation70 rules) + Test Scenarios** from the transcript+frames.714. **Tag every claim** `Confirmed` (stated/shown) · `Inferred` · `Assumption` · `Open`.72 A demo is one person's narration — never silently promote a guess to a requirement.735. **Cite evidence** inline: `[mm:ss]` for narration, `ivNNNN` for the frame that proves it.746. **Flag effects** — any ask that sends/charges/notifies/writes-external or reads PHI75 (e.g. "test against a real chart") so the SA assigns idempotency + compensation.7677### Output artifact convention78- Write the extraction as a **new, source-derived doc** next to the video (e.g.79 `requirements-docs/<name>-requirements-extraction.md`), with frontmatter marking it80 `status: source-derived (NOT canonical)`.81- **Do not silently mutate governed `docs/po/`** docs. If the repo already has a PO82 package, add a short "Relationship to existing docs/po" table mapping each extracted83 requirement to existing scenarios (Inferred), and offer a separate reconcile/gap-check.84- End with an **Open questions** list — the things a cold Solution Architect would need85 answered before designing (the `df-product-owner` exit-gate test).8687---8889## Verification90- [ ] `transcript.txt` is non-empty and coherent (skim `whisper.log` if not — bad audio,91 wrong model, or a non-English track needs a non-`.en` model).92- [ ] Frame count ≈ `duration / interval`; spot-read one mid frame for legibility.93- [ ] Every requirement in the output carries a tag + at least one `[mm:ss]`/`ivNNNN` cite.94- [ ] Effects and Open questions sections are present.9596## Worked example97A ~9-minute product demo, run through this skill end to end (intake script →98transcript+frames → df-product-owner), yielded a dozen requirements and several99state-change test scenarios in PO format. Keep your own worked examples in your100organisation layer, next to the artifacts they cite.101102## Troubleshooting103| Problem | Cause | Fix |104|---|---|---|105| `ffmpeg/whisper-cpp missing` | not installed | run the printed `brew install …` line |106| Transcript empty / garbled | non-English audio, or `.en` model on non-English | use `small` / `medium` (no `.en` suffix) |107| Too many / too few frames | interval wrong for length | pass a larger interval for long videos, smaller for short |108| Wrong/garbled words for jargon | acronyms/domain terms | normal — confirm against frames; keep a glossary, tag `Inferred`/`Open` |109| Frames unreadable (tiny text) | downscaled source | `zoom` into the frame region, or lower interval near the key moment |110111## Resources112- `scripts/extract-video.sh` — the intake pipeline (executed, not loaded into context).113- Pairs with: `df-data-transform-lens`, `df-product-owner` (and downstream `df-solution-architect`).