Repository navigation
feat(media-use): your own voice recording is a voice line, and speed applies to it - #7377
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Verdict: REQUEST CHANGES · 2 blocker · 0 important · 1 nit · head 98237123
- blocker CI "Skills: manifest in sync" fails:
skills-manifest.json is out of date — a skill changed without regenerating it. Runbun run --cwd packages/cli gen:skills-manifestand commit the result. - blocker The Comments check fails: the header block at
audio.mjs:2grew to 41 lines, over the 40-line limit, because of the new example-line comment. Cut a line, or move the recording example intoreferences/audio.md, which already documents it. - nit
media-record.mjs:62: a recording line is still written to the manifest assource: "generated". You note the credits line comes next; worth fixing there too.
Scope
Read audio.mjs, recording.mjs and the media-record.mjs diff. The atempo chain, word scaling and the provider skip for recording-only runs look right. The "fails without the fix" line names two tests. I didn't run them locally; the verdict rests on the CI failures.
…eader at its limit
Collaborator
Author
|
Pushed aa8e47e.
|
Contributor
There was a problem hiding this comment.
Verdict: APPROVE — 3 resolved, 0 open, 0 new · 98237123 → aa8e47e0. The manifest is regenerated, the header is back to 38 lines with the example in references/audio.md, and keeping source as an agent source is justified and pinned by the new media-record test. CI is green.
Merged
4 of 5 tasks
3 of 4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The voice step takes your own recording as a line:
{ "id": "01", "audio": "take.m4a", "words": [{ "text", "start", "end" }] }inaudio_request.json. The file is converted to the engine's wav,speedtime-stretches it with the pitch kept, and the given word timings are scaled the same, so the words still land on the audio. Withoutwords, the recording is transcribed (the existing path). The voice inaudio_meta.jsoncarriessource: "recording", and a run of only recording lines needs no TTS provider and no HeyGen sign-in.Why
Discord, "Use your own voice recording": the voice step only worked with HeyGen voices; with your own recording the speed setting was ignored. Root cause:
audio.mjsonly accepted text lines and sentspeedto the TTS provider alone (synthesizeHeygenbody.speed, Kokoro--speed), so there was no path where a recording could be stretched or its timings scaled.Related work
Refs the same Discord report as #7366 (merged: transcribe error). The credits line that names the real voice source is the next PR.
How
New
skills/media-use/audio/scripts/lib/recording.mjs(ffmpegatempochain for 0.1 to 3x, word parsing, word scaling).audio.mjsroutes a line withaudiothrough it and only picks a TTS provider when some line has text.media-record.mjsincludes recording lines in the voice paths and the media manifest.lib/tts.mjsis untouched. Searched for an existing stretch helper in skills: none (grep -rn atempo skills); the engine'sbuildAtempoFilteris TypeScript inside the render package, not reachable from these standalone scripts.Test plan
skills/media-use/audio/scripts/recording.test.mjs"scaleWords moves words by 1/speed" and "a recording at speed 2: the file is stretched and the words still land on the audio" (both fail with the word scaling removed).audio.mjsfor real, and checks with ffmpegsilencedetectthat the tone starts where the scaled word says (within 80 ms), and the file is 1 s long.wordsomit that line with the reason instead of crashing.node --teston recording, media-record and audio tests on a remote box: 26 passed, 0 skipped;oxfmt --checkandoxlintclean on the four files.skills/media-use/references/audio.md)