Skip to content

FEAT: publish kit (one whole-video SRT and chapters from the render) and youtube_upload --check - #211

Merged
ConalMullan merged 2 commits into
mainfrom
feat/publish-kit
Nov 12, 2026
Merged

ConalMullan merged 2 commits into
mainfrom
feat/publish-kit

Conversation

@ConalMullan

Copy link
Copy Markdown
Collaborator

Publish kit: tools/publish_kit.py

The render's audio is transcribed once and aligned to the scene scripts, which gives:

  • out/publish/video.srt: one subtitle file for the whole video, spelled as the scripts spell it and timed to the render (no scene offsets to add up).
  • out/publish/chapters.txt: a chapter at each scene's cut (the middle of the pause before its first word), titled from project.json scenes[].title or the file names, under YouTube's rules (first at 0:00, three or more, 10 s each; a short scene joins the one before).

Every part is optional: no scene scripts means raw-transcript subtitles and no chapters; --no-captions / --no-chapters skip one. Re-runs reuse the saved transcript, so renaming chapters is free. Cost: Scribe at $0.40 an audio hour (about $0.01 for 90 s), or --engine whisper locally.

youtube_upload.py --check

Read-only, about 1 quota unit: the channel a login belongs to, its scopes, and whether the Data and Analytics APIs are on, with the fix for each problem (a login command, or the Cloud Console page that switches the API on). youtube_stats.py prints the same page instead of a bare accessNotConfigured.

/publish runs the check first, then the kit, and passes the SRT as --captions and the chapters into the description.

Tested

  • 10 new tests (chapter rules, titles, script order, project number, enable link); 209 OK.
  • On Made with itself (93 s): 100% of script words heard, $0.0103; subtitles within ~40 ms of the hand-made file; every chapter within 0.5 s of the real cut (the first word alone ran 1-3 s late, so the kit uses the pause).
  • --check live on two logins: one ready (channel, four scopes, both APIs on), one with an expired token (reported with the login command); after re-login it showed both logins are the same channel.

🤖 Generated with Claude Code

ConalMullan and others added 2 commits November 10, 2026 12:39
…ich scopes it has and whether the Data and Analytics APIs are on, with the fix for each, and youtube_stats links the page that switches Analytics on

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… each scene's cut from a single transcription of the render, and /publish checks the setup, runs the kit and passes both to the upload

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ConalMullan
ConalMullan merged commit 17274db into main Nov 12, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant