/premiere-skills:srt-fastfrom Premiere Skills(無音カット & 字幕)
Generates SRT subtitles from WAV/video audio via single-pass GPU transcription (mlx-whisper), then splits fulltext at semantic pause points and parallelizes line-breaking with subagents for fast Japanese talk-video subtitles.
Ships in Premiere Skills(無音カット & 字幕). Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
単一パスGPU転写(mlx-whisper・Apple Silicon対応)で高品質文字起こしを行い、取得した fulltext をポーズ位置で意味的にN分割し、サブエージェント等で改行工程のみを並列処理して高速にSRT字幕を生成するスキル。
/srt-fast <音声または動画ファイルのパス>
カット点同期XMLがある場合は、アライメント時に --xml "<XMLのパス>" を渡すことでカット後のタイムラインと完全同期可能。
# プラグイン本体の場所を決める(この順で探し、最初に見つかったものを使う)
# Claude Code は ${CLAUDE_PLUGIN_ROOT} をプラグインの実パスに展開する。Codex / Antigravity は展開しない。
ROOT="${CLAUDE_PLUGIN_ROOT:-/nonexistent}"
if [ ! -f "$ROOT/scripts/whisper_to_srt.py" ]; then
# 同じプラグインの複数版がキャッシュに残ることがあるので、更新の新しいものを選ぶ
HIT="$(find "$HOME/.claude/plugins" "$HOME/.codex/plugins/cache" "$HOME/.gemini/config/plugins" \
-maxdepth 8 -type f -name whisper_to_srt.py -path '*premiere-skills*' -print0 2>/dev/null \
| xargs -0 ls -t 2>/dev/null | head -1)"
[ -n "$HIT" ] && ROOT="$(cd "$(dirname "$HIT")/.." && pwd)"
fi
[ -f "$ROOT/scripts/whisper_to_srt.py" ] || { echo "premiere-skills のスクリプトが見つかりません。プラグインを入れ直してください"; exit 1; }
SCRIPTS_DIR="$ROOT/scripts"
PREPARE_SCRIPT="$SCRIPTS_DIR/chunk_tools/prepare_text_parts.py"
WHISPER_SCRIPT="$SCRIPTS_DIR/whisper_to_srt.py"
RULES_FILE="$ROOT/references/srt_runtime_rules.md"
echo "premiere-skills: $ROOT"
OUT_ROOT="$(dirname "<入力ファイルの絶対パス>")"
ffmpeg(導入済み確認: command -v ffmpeg)mlx-whisper または faster-whisperpython3 "$PREPARE_SCRIPT" "<入力ファイルの絶対パス>" --repo "$OUT_ROOT"
実行後、標準出力に MANIFEST: <path> として <stem>.parts.json が出力される。
<stem>.parts.json の内容を読み込み、各パート(parts[i])に対して改行タスクを実行する。
パート数 n > 1 の場合はサブエージェント(invoke_subagent)を同一ターンでN体並列起動する。
パート数が1(n == 1)の場合は、起動オーバーヘッドを避けるためメインエージェントが直接改行して書き込む。
全パートの lines_out が揃ったら、結合してアライメントを実行する:
cd "<out_dir>" && python3 -c "
from pathlib import Path
import json
m = json.loads(Path('<stem>.parts.json').read_text())
lines = []
for p in m['parts']:
lines += [l.strip() for l in Path(p['lines_out']).read_text().splitlines() if l.strip()]
Path(m['lines_out']).write_text('\n'.join(lines)+'\n')
print(len(lines), 'lines')
" && SRT_QA_JSON=1 python3 "$WHISPER_SCRIPT" \
--from-text "<stem>.fast.lines.txt" --segments "<stem>.segments.json" -o "<stem>.fast.srt"
※カットXMLがある場合は --xml "<XMLパス>" を付与。
出力の QA_JSON で over25(25字超)や head_ng(文頭助詞等)が検出された場合、<stem>.fast.lines.txt の該当行をルールに従って分割・調整し、whisper_to_srt.py --from-text ... を再実行(約0.1〜1秒で再アライメント完了)。
不要になった一時パートファイルを削除:
rm -f "<out_dir>/<stem>".part*.txt "<out_dir>/<stem>".part*.lines.txt
報告フォーマット:
<stem>.fast.srt)What SKILL.md sets; muted values are Claude Code's defaults
2 skills in this plugin
npx claudepluginhub fuuuuuuma/premiere-skills --plugin premiere-skillsOther plugins' skills for the same job