agentleFS
kajisho5kajisho5/audio-production-skill/CLAUDE.md

audio-production-skill

CLAUDE.md7 starsChanged 11 days agoMITView on GitHub

Read this first; do not rely on conversation history. Current state and next tasks: docs/STATE.md. A deterministic audio production execution Skill of the kajisho5 video production ecosystem (README "What it is, and what it is not"). It executes a typed operation graph (GAIN, TRIM, CUT, SILENCE_REMOVE, FILLER_REMOVE, FADE_IN/OUT, NORMALIZE, LOUDNESS_SET (several delivery loudness versions), MIX (with duck), STEMS (stem files that sum to the mix), CONCAT, MONO, STEREO, DOWNMIX, NOISE_REDUCTION, DYNAMICS, VOICE_CLEANUP, AUTOMIX (gain-sharing mix of microphone inputs), MIX_TRACKS (pan…

  • Installs packages

The file

We split this CLAUDE.md into the rules it gives an agent

5 rules. About 0 are common, 1 is distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Read this first; do not rely on conversation history.

    line 3
  2. Very specific:

    No shell, no ffmpeg call of its own, no filter strings, no request field may name a command / argv / executable (model.FORBIDDEN_KEYS).

    line 15
  3. Very specific:

    No production defaults (target_lufs, true_peak_db, silence ranges, the filler lexicon are always explicit), no silence detection, no speech …

    line 17
  4. Very specific:

    Never claim an operation the code cannot run: gaps go to model.UNSUPPORTED_OPERATIONS with the reason.

    line 55
  5. Distinctive:

    Commit messages and PR bodies follow the existing ones.

    line 62

≈ “Common” is an estimate: at least 1 in 5 of the 29,248 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
CLAUDE.md

audio-production-skill — guide for a future session

Read this first; do not rely on conversation history. Current state and next tasks: docs/STATE.md.

What this repository is

A deterministic audio production execution Skill of the kajisho5 video production ecosystem (README "What it is, and what it is not"). It executes a typed operation graph (GAIN, TRIM, CUT, SILENCE_REMOVE, FILLER_REMOVE, FADE_IN/OUT, NORMALIZE, LOUDNESS_SET (several delivery loudness versions), MIX (with duck), STEMS (stem files that sum to the mix), CONCAT, MONO, STEREO, DOWNMIX, NOISE_REDUCTION, DYNAMICS, VOICE_CLEANUP, AUTOMIX (gain-sharing mix of microphone inputs), MIX_TRACKS (pan per input, language-tagged tracks), MIX_AT (inputs placed at start times: a cue sheet's effects)) through ffmpeg-skill's public contract (any version that declares the tools and flags it uses) and reports validated artifacts with provenance. It is not an agent, not a measurement skill, not ffmpeg-skill.

Boundaries that must hold

  • Sample arithmetic in this process only in pcm.py (AUTOMIX, MIX_TRACKS pan, MIX_AT starts; stdlib, on 16-bit PCM WAV ffmpeg-skill wrote, ADR-29 / ADR-30).
  • No shell, no ffmpeg call of its own, no filter strings, no request field may name a command / argv / executable (model.FORBIDDEN_KEYS); one subprocess.Popen in adapter.py; allow-listed ffmpeg-skill scripts only.
  • No production defaults (target_lufs, true_peak_db, silence ranges, the filler lexicon are always explicit), no silence detection, no speech recognition (FILLER_REMOVE cuts at caller-supplied word timings), no decisions, no conference / speaker vocabulary in code or contract (tested).
  • Inputs are never modified; outputs stay inside --workspace; failed runs leave no partial output.
  • Everything the contract says is derived from model.OPERATION_TYPES, executor.TOOL_FOR, adapter.FLAGS_USED, errors.ERROR_TABLE, contract.CAPABILITY_IDS; audio-production contract --check proves it.

Layout

src/audio_production/: model (request schema, operation parameter schemas), fillers (FILLER_REMOVE matching / range arithmetic, pure), security (path policy), graph, timeline, adapter (ffmpeg-skill boundary), executor, doctor, contract, contract_check, cli, errors, canonical, pcm (in-process sample arithmetic). tests/: unit, security, contract (with tests/contract/contract.json pinned), integration (real audio through the real ffmpeg-skill; nothing skipped). docs/: architecture, security, ffmpeg-skill (observed behaviours and gaps), contract (pinned blocks / drift), testing, decisions (ADRs), STATE.

Commands

pip install -e . pytest pyflakes mypy
export AUDIO_PRODUCTION_FFMPEG_SKILL_DIR=/path/to/ffmpeg-skill      # or clone it as ../ffmpeg-skill / vendor/ffmpeg-skill
python -m pytest -q                                                 # ~90 s with real ffmpeg
python -m pyflakes src tests && python -m mypy src/audio_production --ignore-missing-imports
audio-production doctor --json
audio-production contract --check tests/contract/contract.json --json
python contract/generate.py --check                                 # contract/contract.json is current

contract/contract.json is the contract as a committed file (byte for byte the contract --json output), so any tag's contract can be read with git show <tag>:contract/contract.json without running the code. Regenerate it with python contract/generate.py; tests/test_contract_file.py fails when it is stale, and the release workflow regenerates it after the version bump.

Rules for changes

  • A contract change inside the pinned blocks (docs/contract.md) is breaking for video-production-agent's pin: bump VERSION (src/audio_production/__init__.py and pyproject.toml), regenerate tests/contract/contract.json and contract/contract.json, and note in the PR that the agent must re-pin. Additive keys are fine within a version.
  • Never claim an operation the code cannot run: gaps go to model.UNSUPPORTED_OPERATIONS with the reason.
  • New ffmpeg-skill features: verify the real behaviour first (docs/ffmpeg-skill.md records measurements), then detect the capability from the contract (FLAGS_USED if required, OPTIONAL_FLAGS_USED + takes_flag() if the older behaviour still works). Never gate on the ffmpeg-skill version number and never add an upper bound (ADR-15).
  • CI runs every cell against ffmpeg-skill commit 336e0c4 (0.12.2) and against main in .github/workflows/tests.yml; runners ship FFmpeg 6 (Ubuntu) and 8 (macOS, Windows), which behave differently for AAC trim boundaries (docs/ffmpeg-skill.md).
  • Commit messages and PR bodies follow the existing ones; PRs are squash-merged; the branch cannot be deleted through the git proxy (delete it in the GitHub UI).
  • .github/workflows/release.yml (ADR-14) tags and releases automatically on push to main, resolving the next version from PR labels unless pyproject.toml's current version is already ahead of the latest tag (a manual bump per the rule above is always respected, never overwritten). Label a PR major/breaking, minor/feature/enhancement, or patch/fix/bug (.github/workflows/autolabel.yml usually does this from the title/branch/files automatically); unlabeled defaults to patch. A push whose pull requests are all labelled only chore/ci/documentation/docs/test releases nothing, and the release commit is tested before it is pushed (ADR-28). On a Dependabot PR a major/minor-level label counts only when a person applied it (ADR-22). Don't hand-edit CHANGELOG.md — the release workflow generates it from git log every run.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.