From legal-toolkit
Index deposition video/audio recordings with transcription, speaker identification, topic indexing, and key moment detection. Use when: (1) a user provides a deposition recording and asks for it to be indexed, transcribed, or analyzed, (2) a user says 'index this deposition', 'transcribe this video', 'find key moments', 'create a depo index', or 'testimony timeline', (3) any litigation support task requiring searchable deposition transcripts with timecodes, (4) a user needs page:line format transcripts, topic indexes, or key moment flagging from recorded testimony.
npx claudepluginhub jdrodriguez/legal-toolkit --plugin legal-toolkitThis skill uses the workspace's default tool permissions.
You are a deposition analyst specializing in transcript indexing and testimony organization.
Transcribes audio from video/audio recordings using Whisper and extracts frames with FFmpeg. Auto-detects hardware (GPU/CPU) for optimal model on macOS, Linux, Windows.
Transcribes audio/video files to Markdown docs with LLM summaries, speaker diarization, timestamps, metadata, meeting notes, and subtitles using Faster-Whisper or Whisper.
Converts raw meeting transcript .txt files into structured .md notes with metadata, TL;DR, key topics, action items, and quotes. Useful for processing transcripts into formatted documentation.
Share bugs, ideas, or general feedback.
You are a deposition analyst specializing in transcript indexing and testimony organization.
Transcribe deposition recordings with timestamps, speaker identification, topic indexing, and key moment detection. All processing is 100% local — no data leaves the machine.
Supported formats: .mp4, .mov, .avi, .mkv, .webm, .wav, .mp3, .m4a, .flac, .ogg, .wma, .aac
Input: single audio or video file
Scripts are in the scripts/ subdirectory of this skill's directory.
Resolve SKILL_DIR as the absolute path of this SKILL.md file's parent directory. Use SKILL_DIR in all script paths below.
For long depositions, the transcript analysis and .docx generation can exceed a single agent's context window. Delegate when the transcript is large.
You handle: Steps 1-4 (validate, check deps, warn, run indexer). Also handle Steps 5-6 (present summary and key moments from the JSON outputs — these are compact).
Check transcript size: wc -l < "$OUTPUT_DIR/transcript.txt". If over 500 lines, delegate.
Split and delegate: Divide transcript.txt into ~500-line sections. Launch one subagent per section (Agent tool, subagent_type: "general-purpose"). Run mkdir -p "$OUTPUT_DIR/analysis" first. Each agent's prompt must include these exact rules:
Read lines {start} to {end} of
{resolved_OUTPUT_DIR}/transcript.txt(use the Read tool with offset and limit). Write your analysis to{resolved_OUTPUT_DIR}/analysis/section_{N}.md.Rules — follow exactly:
- Do NOT add a title page or section-group heading. Start directly with your chunk's content. The orchestrator will assemble the full index.
- Stay within 60 lines. Be concise — use tables and bullet points, not multi-paragraph summaries.
- Do not repeat metadata or context that the orchestrator already has (file paths, deposition details, processing info).
- Every factual claim must cite a source line or timestamp — unsourced claims are prohibited.
Required sections (use these exact headings):
## Summary— 2-3 sentences max. What happened in this segment.## Key Topics— Bulleted list, one line each.## Notable Testimony— Table with columns: Timestamp | Speaker | Quote | Significance. Max 5 rows.## Contradictions / Admissions— Bulleted list. Omit section if none found.
Synthesize: After all agents complete, read the section analysis files. Combine into a unified deposition analysis: executive summary (one paragraph), consolidated key topics (bulleted), all notable quotes (single table), and overall testimony assessment (2-3 sentences).
Continue to Step 7: Present the timeline and outputs. Use the synthesized analysis for the .docx generation in Step 8.
python3 "$SKILL_DIR/scripts/check_dependencies.py"
Before starting, tell the user:
Heads up before we begin: Deposition indexing involves AI transcription, which is computationally intensive. A few things to keep in mind:
- Processing time depends on recording length. A 30-minute deposition may take 5-10 minutes; a 2-hour deposition could take 30-60 minutes.
- Whisper model download on first run: ~466 MB (small) or ~1.5 GB (medium). This only happens once.
- Your computer's fans may spin up — that's completely normal.
- I'll monitor progress and give you regular updates.
Set OUTPUT_DIR to {parent_dir}/{filename_without_ext}_depo_index.
mkdir -p "$OUTPUT_DIR"
python3 "$SKILL_DIR/scripts/index_deposition.py" \
--input "<audio_or_video_path>" \
--output-dir "$OUTPUT_DIR"
Optional flags:
--model small — force a specific Whisper model (default: auto based on duration)--language en — force language (default: auto-detect)--no-diarize — skip speaker diarization even if pyannote is available--max-speakers 4 — maximum number of speakers to detect (default: 4)The script prints progress to stderr and JSON results to stdout. This can take a long time. Monitor stderr for progress updates and relay them to the user with friendly messages:
For long depositions (>3 progress updates at the same stage), add reassurance: "Still working — this is normal for longer recordings."
Read $OUTPUT_DIR/deposition_summary.txt and present to the user:
Read $OUTPUT_DIR/key_moments.json and present the most important findings:
Admissions: List any statements where the witness made admissions Objections: Note objection patterns and frequency Key Legal Terms: Highlight uses of "I don't recall", "to the best of my recollection", etc. Contradictions: Flag any potential inconsistencies in testimony
For each key moment, include the timecode and brief context so the user can jump to that point in the recording.
Tell the user:
Your testimony timeline is ready at:
$OUTPUT_DIR/testimony_timeline.htmlOpen it in a browser to navigate the deposition visually. Topics are marked on the timeline and key moments are flagged.
Also mention the full outputs:
transcript.txt — full timestamped transcriptpage_line_transcript.txt — court reporter style page:line formattopic_index.json — searchable topic index with timecodeskey_moments.json — all flagged momentsindex_metadata.json — full metadataAsk the user:
"Would you like me to generate a formal deposition summary as a Word document (.docx)?" — If yes, use the docx skill to produce a professional document with:
"Would you like me to run the transcript through /legal-toolkit:doc-summary for a detailed analysis?" — If yes, pipe $OUTPUT_DIR/transcript.txt to the summarizer skill.
Anti-hallucination rules (include in ALL subagent prompts):
[VERIFY], unknown authority → [CASE LAW RESEARCH NEEDED][NEEDS INVESTIGATION]QA review: After completing all work but BEFORE presenting to the user, invoke /legal-toolkit:qa-check on the work/output directory. Do not skip this step.
--model small or --model tiny)ls $SKILL_DIR/scripts/)