CtrlK
BlogDocsLog inGet started
Tessl Logo

jbaruch/speaker-toolkit

Seven-skill presentation system: ingest talks into a rhetoric vault, run interactive clarification, generate a speaker profile, create presentations that match your documented patterns, produce the deck illustrations + thumbnail visual layer, publish talk pages to a Jekyll shownotes site, and verify a recorded screencast against its storyboard. Includes a 113-entry Presentation Patterns taxonomy (83 observable: 64 patterns + 19 antipatterns; 30 unobservable: 21 patterns + 9 antipatterns) for scoring, brainstorming, and go-live preparation.

74

Quality

93%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide

SecuritybySnyk

Low

Low-risk findings worth noting

Overview
Quality
Evals
Security
Files

build-contact-sheet.pyskills/vault-ingress/scripts/

#!/usr/bin/env python3
"""Sample VIDEO into OUTPUT_DIR without approving crops or touching the vault DB.

Usage: build-contact-sheet.py VIDEO OUTPUT_DIR [--frames N] [--timeout-seconds N]
Stdout: one JSON report (manifest path, frame count, reuse status).
Exit 0: complete validated bundle; 1: operational failure; 2: invalid usage.
Output includes individual frames and a separate classification contact sheet.
The sampling constants and failure codes live in crop_frames.py.
"""

from __future__ import annotations

import argparse
import json
from pathlib import Path
import sys
from typing import NoReturn

from artifact_supervisor import SupervisorError
from crop_frames import CropFramesError, DEFAULT_FRAMES, LIMITS, sample_video
from video_evidence import VideoEvidenceError


USAGE = "build-contact-sheet.py VIDEO OUTPUT_DIR [--frames N] [--timeout-seconds N]"


class ArgumentParser(argparse.ArgumentParser):
    def error(self, message: str) -> NoReturn:
        print(json.dumps({"ok": False, "code": "crop_usage_invalid", "usage": USAGE}))
        print(f"invalid sampling command; usage: {USAGE}", file=sys.stderr)
        raise SystemExit(2)


def main(argv: list[str] | None = None) -> int:
    arguments = sys.argv[1:] if argv is None else argv
    if arguments in (["--help"], ["-h"]):
        print(json.dumps({"ok": True, "usage": USAGE}))
        return 0
    parser = ArgumentParser(add_help=False, allow_abbrev=False)
    parser.add_argument("video", type=Path)
    parser.add_argument("output_dir", type=Path)
    parser.add_argument("--frames", type=int, default=DEFAULT_FRAMES)
    parser.add_argument("--timeout-seconds", type=float, default=LIMITS.wall_seconds)
    args = parser.parse_args(arguments)
    try:
        report = sample_video(
            args.video,
            args.output_dir,
            count=args.frames,
            timeout_seconds=args.timeout_seconds,
        )
    except (CropFramesError, VideoEvidenceError, SupervisorError, OSError) as exc:
        code = (
            exc.code
            if isinstance(exc, CropFramesError)
            else exc.reason_code
            if isinstance(exc, (VideoEvidenceError, SupervisorError))
            else "crop_io_failure"
        )
        print(json.dumps({"ok": False, "code": code}))
        print(str(CropFramesError(code)), file=sys.stderr)
        return 1
    print(json.dumps(report))
    return 0


def run_cli() -> int:
    try:
        return main()
    # Agent callers interpret absent JSON as a lost process contract. Emit a
    # closed failure; a traceback would drop that contract and expose paths.
    # outer-boundary-process-contract
    except Exception:  # noqa: BLE001
        print(json.dumps({"ok": False, "code": "crop_unexpected_failure"}))
        print(
            "sampling failed unexpectedly; repair the runtime and retry",
            file=sys.stderr,
        )
        return 1


if __name__ == "__main__":
    raise SystemExit(run_cli())

skills

vault-ingress

scripts

adherence_baseline.py

aggregate-catalog-feedback.py

apply-source-repairs.py

artifact_locator.py

artifact_metadata.py

artifact_supervisor.py

audit-pattern-catalog.py

audit-persisted-pattern-observations.py

audit-source-identities.py

batch-download-videos.py

build-contact-sheet.py

build-crop-reviewer.py

build-score-basis.py

catalog_dimension_registry.py

catalog_io.py

catalog_normalization.py

check-runtime.py

classify-pptx-evidence.py

cloud_artifacts.py

cooperative_lock.py

crop_frames.py

crop-reviewer-shell.html

crop-reviewer-shell.html.txt

crop-reviewer.js

crop-reviewer.js.txt

establish-date-provenance.py

failure_diagnostics.py

fetch-transcript.py

ingress_contract.py

local_media_contract.py

local_media_download.py

local_media_evidence.py

local_media_process.py

local_media_sampling.py

local_media_transcription.py

local_media_words.py

markdown_deck.py

migrate-tracking-database.py

mutate-tracking-database.py

pattern_evidence.py

pdf_evidence.py

persist-results.py

persisted_pattern_observations.py

pptx_catalog_selection.py

pptx_deck_facts.py

pptx_discovery_contract.py

pptx_evidence.py

pptx_talk_identity.py

pptx-extraction.py

preflight-vault.py

queue_claim_contract.py

queue-state.py

read-tracking-database.py

render-markdown-deck.py

render-vault-status.py

retained_stage.py

return_validation.py

scan-shownotes.py

source_alias_contract.py

source_identity_matching.py

summary_lock.py

sweep-pptx-talk-identity.py

tracking_database_io.py

tracking_database.py

transcript_quality.py

transcript_timing.py

validate-returns.py

vault_root_authority.py

video_evidence.py

video_integrity.py

video-slide-extraction.py

vtt-cleanup.py

write-analysis.py

ytdlp_runtime.py

SKILL.md

README.md

tile.json