mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-11-18 07:50:13 +00:00
cb8e02e8264bd6994de29a024a6f320ce21654e7
19
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
acd5c30e60 |
feat(cli): read audio stems through your HeyGen account (#6993)
* feat(cli): audio --read organises the reading by stem Measures where each stem is heard, leaves the drums' recurring hits to the music while it plays, names the stem of each remaining effect, writes a voice-free mix next to the stems, and describes each audible stem and the whole recording with Gemini. * feat(cli): audio --read reads stems as vocals, drums, bass and melodic Piano, guitar and other are mixed into melodic.wav next to the stems; levels, spans, descriptions, effects and pieces are read per group, and a group heard for under two seconds or 5% of the recording is left out of the reading. * feat(cli): audio --read describes the six stems and writes a BGM prompt from them Stems are read one by one again; a stem heard under two seconds or 5% of the recording is still left out. Each stem's description gives the times of its changes and names the effects it hears. The overall and the BGM prompt are written from those descriptions and the measured spans, not by listening to the mix again; the BGM prompt orders the arrangement without seconds. * fix(cli): audio --read writes no BGM prompt for a recording without music Foley and effects in a rhythm are not music; the reading says so instead of a prompt that would make a remix generate a track the reference never had. * fix(cli): audio --read prompts name no example sounds * fix(cli): describe audio through HeyGen and keep effects measured * docs(cli): document measured effect events without sound kinds * fix(cli): clear audio description review checks Use portable stem path assertions and simplify response validation. Keep auth-derived URLs out of cache hashes and trim redundant comments. — Jerrai --------- Co-authored-by: Xuanru Li <157947275+xuanruli@users.noreply.github.com> |
||
|
|
de6ec3811e |
fix: cache paths follow HYPERFRAMES_CACHE_DIR (#6716)
* fix: cache paths follow HYPERFRAMES_CACHE_DIR Every place HyperFrames keeps downloaded or built files now takes its folder from one helper, hyperframesCacheDir() in @hyperframes/core. The default stays ~/.cache/hyperframes; HYPERFRAMES_CACHE_DIR moves it. * fix: register the cache-dir subpath for bun and node, and build inspector from core source * test: the cache-dir override test uses a folder that is absolute on every platform * fix: the opencv cache follows HYPERFRAMES_CACHE_DIR * fix(cli): npm installs run in their staging dir, so no cache path reaches a command line * fix(cli): whisper.cpp is cloned inside its build dir, so no cache path is a git argument * test(cli): the whisper clone test finds no system whisper on Windows either |
||
|
|
4fa5f54519 |
fix(cli): audio windows read beats off the whole clip; beats snap to the signal and mark silence (#6692)
* fix(cli): audio windows read beats off the whole clip; beats snap to the signal and mark silence A film query that covers part of a clip measures beats, downbeats, bpm and sections on the whole clip and cuts them to the window, as #6653 did for kind, so a window under 6 s still has its beats. One step after every provider ladder moves a provider's beats and downbeats onto the signal's own beats within a quarter beat (the snapping api did alone) and marks each with `silent`, true where the beat falls in silence. Beats are marked, never dropped; the JSON change is the additive `silent` array. — Jerrai * fix(cli): beats with no pulse are unheard; a window with none answers no steady beat Review fixes for #6692: - The per-beat flag is now `unheard` (renamed from `silent`, not released): true in silence or where no onset falls within 50 ms of the beat, so hiss, room tone or a held pad no longer pass as beats. - A window keeps the whole clip's beats only when at least two of its beats are heard; otherwise it answers "no steady beat" as before, with no downbeats and no bpm. - A window's bpm is the tempo of its heard beats, never the whole clip's. - Comment lines trimmed so analyze.ts, run.ts and api.ts are at or under main's share. — Jerrai * fix(cli): a beat is unheard only where two beats in a row have no onset Scored on the ground-truth set, flagging every onset-less beat also flagged heard beats the onset detector misses: the drop downbeat after a snare roll, single beats under narration, quiet beats late in a fade. A pulse gap now needs two onset-less beats in a row; hiss, room tone and held pads span many beats and stay flagged, and silence is flagged as before. — Jerrai * fix(cli): a window with no pulse on the clip's grid reads its own beats, as before Genesis found a window over a section far under the clip's loudest part answered "no steady beat" where main, reading the window alone, found every beat: the clip's grid and onsets skip a section that quiet (from about 40 dB under, for clicks). When a window keeps fewer than two heard beats from the clip's grid, its beats, downbeats and bpm now come from the window alone, as they did on main. Hiss still answers "no steady beat" on its own. The hiss test's noise() repeats every 10,466 samples (0.22 s at 48 kHz), which the window's own reading took for a pulse; that test now uses a xorshift generator. — Jerrai * fix(audio): unheard comes from level-free rhythm evidence, so quiet music stays heard A beat was flagged by an absolute -50 dBFS silence and by onsets under 10% of the clip's loudest hit, so music 30 dB or more under the loudest part read as unheard. Now: - core localBeatEvidence reads the cached standardised onset curve over the 6 s around each beat: the tracker's steady-beat confidence there (clarity at the local beat lag times the beat's own lift) and the beat's lift over the span's mean. - A beat is unheard in digital silence (-80 dBFS), or when its span keeps no steady beat (confidence under 0.15) and its own onset does not stand out (lift under 1.5). Lift alone keeps beats under narration heard, where syllables lower the span's clarity. - A window keeps the clip's beats when at least two, and at least half, of them are heard. — Jerrai |
||
|
|
1df31d8717 |
fix(audio): a sound is voice only with a voice-range pitch, judged on the whole clip (#6653)
* fix(audio): a sound is voice only with a voice-range pitch, judged on the whole clip Two ways the kind guess called a non-voice sound voice: - A short hit, click or whoosh can have a speech-shaped envelope. classify() now also measures the share of 40 ms frames with a 70-500 Hz fundamental (YIN, moved from the CLI into core) and calls a sound voice only when that share reaches 0.15. Speech measured 0.22-0.43; impacts, clicks and whooshes 0. - A range query judged a clip's kind on the slice it covered, so 1.7 s of a music bed read as voice. A film clip's kind is now judged on all of the clip that plays. Even-paced speech (a 64 s TTS take) moves less at syllable rate and was called music; with no beat and a voiced share of 0.25 or more it is now voice. * chore(audio): keep each touched file's comment share at or under its base The Comments check failed on run.ts, targets.ts and audioAnalysis.ts because the PR added comment lines to files whose share may only go down. Drops the added doc comments; no code change. — Jerrai * fix(audio): preserve clip evidence and stereo pitch during analysis * fix(audio): bound and cache whole-clip kind analysis * fix(audio): retain native-rate kind evidence when available --------- Co-authored-by: Jerrai <jerrai@heygen.com> |
||
|
|
cfef528d3a |
fix: phone videos with an undecodable first audio track check, preview and render (#6551)
* fix: phone videos with an undecodable first audio track check, preview and render * fix(engine): a rate-lane clip bakes its ramp from the decodable audio track * test: phone-clip tests end ffprobe options before the input |
||
|
|
cf04452c0d |
fix(cli): audio --read reads music onsets, effect peaks, pauses and voice against music (#6546)
* fix(cli): audio --read starts music where its sound is sustained A run of the bed is split where sound fills less than half of the surrounding 2 s, so a short tone and scattered clicks that bridge into the music no longer pull its start earlier. Sparse stretches are left to effects. * fix(cli): audio --read finds effects in each stem and levels them from the mix A sound ends where the next one starts, so a run of kicks is not one long riser. Effects are searched in the drums and in the bed outside music, each on its own, so a click inside a tone is still found. Each effect's peak is read from the decoded mix in dBFS, and the music reference is taken next to the effect rather than under it, where its own leakage sits. * fix(cli): audio --read measures the recording through each pause Pauses carry the whole recording's level so the read can say what keeps playing while the voice stops. * feat(cli): audio --read prints peaks, what plays in pauses, voice vs music Effect lines print the absolute peak and name the reference of the relative figure; pause lines keep the pause kind and list the effects, music and ambience under them; sentences over music print voice and music loudness and which is louder. Read schema version 4. * fix(cli): audio --read finds bed effects on the whole bed, not a blanked one Blanking the bed wherever music or ambience played made every blanked stretch that ended while sound was still audible look like a sound rising out of silence. Fades and quiet bridges then printed as dings, hits and whooshes. The bed is now searched whole, and each source carries the spans it plays music or ambience in. A sound whose onset-to-peak overlaps one of those spans belongs to it, so it is not an effect. The drums and the bare mix carry no spans. — Jerrai --------- Co-authored-by: Jerrai <jerrai@heygen.com> |
||
|
|
87baff8842 |
fix(cli): audio --read reports noise beds as ambience, not music (#6536)
* fix(cli): audio --read reports noise beds as ambience, not music A stretch of the non-voice stems counted as music whenever it was above -55 dB, so room tone and engine rumble separated into "other" printed as a music piece. A stretch is now music only with a beat, clear tonal chroma or more than one leading instrument; otherwise it is ambience with its level in dBFS, called quiet under -45 dBFS, and breaks lie only between two runs of music. The header lists only stems that carry sound, with their level, instead of the separator's six fixed names. * refactor(cli): audio --read gate carries its meaning in names, not comments * fix(cli): keep ambience out of downstream music measurements * fix(cli): measure music beat evidence within each stretch |
||
|
|
ec866ed1c5 | fix(cli): keep audio timings when trimming long recordings (#6375) | ||
|
|
66f55ffb9b |
fix(cli): audio describe builds its Apple helper with a module cache an agent's sandbox can write (#6102)
* fix(cli): audio describe builds its Apple helper with a module cache an agent's sandbox can write * chore(cli): shorten the module cache comment |
||
|
|
2c1d9d50d2 |
feat(cli): read a whole recording as voice, effect and music lines (#6056)
* feat(cli): read a whole recording as voice, effect and music lines
`hyperframes audio <file> --read` turns an episode or reference video into
time-stamped lines an agent can read or grep: sentences with rate, pitch and
ending; pauses; sound effects grouped by identical sound, with band, attack,
tail and level over the music; and the music bed split at its cut-outs into
pieces that start, resume, return or are new.
Effects and music come from stems separated by the service at
HYPERFRAMES_AUDIO_STEMS_URL (vocals, drums, bass, guitar, piano, other).
Without stems, effects are read from the mix outside speech; with neither
stems nor a transcript, voice and effects are not read, and each case is
reported in a warning. Results are cached per file content.
* refactor(cli): name the service error parse instead of commenting it
* fix(cli): call HeyGen's audio services with the CLI's HeyGen credential
Stems for `audio --read` and the `api` analysis provider only ran when
HYPERFRAMES_AUDIO_STEMS_URL / HYPERFRAMES_AUDIO_API_URL and
HYPERFRAMES_AUDIO_API_KEY were set, so someone with HEYGEN_API_KEY or a saved
`hyperframes auth login --api-key` still got "not set" and had to know the
internal route.
Both now default to /v3/audio/stems and /v3/audio/analysis on the HeyGen API
(HEYGEN_API_URL when set) with the credential the other HeyGen commands use.
The URL variables still point at another service, which then needs its own
HYPERFRAMES_AUDIO_API_KEY, so the HeyGen credential never goes to a host it was
not issued for.
* fix(cli): keep audio on the machine unless --quality best is asked for
`hyperframes audio` defaulted to --quality best, so anyone with a HeyGen
credential uploaded their audio, and could be billed, for an ordinary beats or
--read run. tts, transcribe and remove-background never leave the machine
unasked.
The default is now local for both measuring and --read. best is unchanged and
still uploads to /v3/audio/analysis and /v3/audio/stems. When a capability goes
unanswered because a service was left out, or --read reads without stems, the
warning says --quality best would add it.
* fix(cli): bound stem transfers and preserve recording timestamps
* fix(cli): an empty audio service URL keeps the service off
HyperFrames Desktop blanks HYPERFRAMES_AUDIO_API_URL and its key while
the analysis route is behind a flag, but gives runs HEYGEN_API_KEY and
HEYGEN_API_URL for its gateway. Falling back to that credential would let a
run that passes --quality best reach the route anyway. An empty URL now turns
the service off, whatever credential is present.
* fix(ci): capture package name in release-age exclusion
(cherry picked from commit
|
||
|
|
ab2e939558 |
fix(cli): audio and timeline find media the way preview and render load it (#5846)
audio and timeline joined a clip's src to its composition's folder by hand, so a project-root asset used from a nested scene, or a percent-encoded file name, was "not found" although preview, check and render load it. resolveAuthoredAssetFile now owns that lookup (the sub-composition rewrite, then the decoded project-root resolve), and audio, timeline and media-treatment all use it. |
||
|
|
eab6ca15b1 |
fix(cli): timeline lists clips nested in a timed element and lint flags ones that never show (#5732)
* fix(cli): timeline lists clips nested in a timed element and lint flags ones that never show * docs(lint): wrap the nested-clip entries * docs(skills): format the nested-clip note and refresh the skills manifest * fix(cli): keep timeline edits from colliding with a clip's own wrapper * fix(cli): cut clips nested in a wrapper at their sub-composition's in-point * refactor(lint): split the nested-clip visibility checks to keep the audit green * style(cli): restore the timeline test's formatting |
||
|
|
34776f3def | fix(cli): analyze finalized audio assets after direct upload (#5647) | ||
|
|
124492e427 |
feat(cli): the api provider speaks the HeyGen audio analysis contract (#5641)
* feat(cli): the api provider speaks the HeyGen audio analysis contract
The api rung now sends its key as x-api-key, a new Idempotency-Key on each
request, and 16 kHz mono 16-bit WAV: the channels are averaged and resampled
with a windowed sinc whose cutoff sits under 8 kHz, so nothing folds back in.
It reads the answer from a { "data": ... } envelope, or bare. Times stay in
seconds, and the answered times still snap onto beats measured on the signal
as decoded. The response type gains time_resolution_seconds.
* fix(cli): reject redirects from audio analysis requests
* fix(cli): preserve audio when stereo downmix cancels
|
||
|
|
8e340d220e |
feat(cli): audio answers beats, downbeats, bpm, sections and describe through a provider ladder (#5632)
* feat(cli): audio answers beats, downbeats, bpm, sections and describe through a provider ladder Beats and downbeats try api, apple-mu, beat-this, then signal; sections try api, apple-mu, then signal; describe tries api, then apple-sound. bpm is read off whichever provider placed the beats. Each provider says whether it can run here and why not, and the ladder warns when it passes one over. The signal rung is a TypeScript tracker: log-band spectral flux, autocorrelation tempo with a log-normal prior, Ellis dynamic-programming beats with a windowed local tempo, a low-band bar phase, and Foote novelty sections snapped to beats. It reports no steady beat when the onsets do not repeat. The api rung posts the audio to HYPERFRAMES_AUDIO_API_URL with HYPERFRAMES_AUDIO_API_KEY and moves each answered time onto the nearest signal beat within a quarter beat, reporting what moved and what did not. beat-this runs Beat This! from a configured Python and local weights and never downloads. apple-sound runs macOS's sound classifier through a Swift helper. apple-mu reports that Music Understanding needs macOS 27. words are no longer accepted: they come from hyperframes transcribe. * docs(cli): audio's beats, downbeats, bpm, sections, describe and their provider ladder * fix(cli): remove redundant audio context comment * fix(core): keep flat audio novelty in one section * fix(cli): honor BPM provider pins before analysis |
||
|
|
bb49858b8a |
feat(cli): hyperframes audio measures where sounds land, in film time (#5602)
* feat(cli): hyperframes audio measures where sounds land, in film time Adds @hyperframes/core/audio-analysis: an energy envelope, spectral-flux and energy onsets, the moments a sound lands (onset, steepest rise, peak, tail end), BS.1770 loudness with true peak, silence spans and a first guess at sfx/voice/music, all pure functions of PCM. Each capability runs through a provider ladder so model or service providers can join later. The radix-2 FFT moves out of audioCarve so both share it. `hyperframes audio` decodes with FFmpeg and analyzes files, or the film's own audio and video clips by element, second, range or boundary, reading only the part of each file that plays. Timeline rows now carry `mediaStart`, moved by an in-point host's cut, so file time maps to film time. * feat(cli): audio placements carry the element's own data-start, local to its composition * feat(cli): audio placements carry the element's own data-start, local to its composition * feat(cli): audio places a file with --place-at, drops --boundary --start becomes --place-at and --media-start becomes --skip-file-seconds, which only goes with --place-at, refuses to skip the whole file, and warns when the skipped part held the file's loudest moment. --boundary is gone: --at and --range cover the sounds a cut touches. * fix(cli): pass a sound file to ffprobe as a file, on every platform ffprobe treated a name starting with a dash as an option because the argument list never ended the flags. The path check compared a Windows drive path to a POSIX string, and a new timeline comment raised that file's comment share. * fix(cli): hear a reversed stereo channel, and warn when its peak was skipped Averaging the channels cancelled a reversed one, so a real hit was reported as silence. The skip warning also compared against the decode margin, so a peak just before the kept window produced no warning. |
||
|
|
3091dcb787 |
feat(cli): route media search through media-use (#4230)
* feat(cli): move media-use engine into the CLI * fix(cli): replace media-use compatibility asset * fix(cli): replace moved media-use tree * fix(cli): copy moved media-use files cleanly * fix(cli): copy media-use engine files individually * fix(cli): keep audio helper compatibility import * fix(cli): clear copied skill destinations * test(cli): preserve moved media-use test paths * fix(cli): preserve media-use script compatibility imports * fix(cli): preserve media-use telemetry shim * fix(cli): resolve packaged media-use LUT assets * fix(cli): resolve packaged bundled SFX assets * chore(skills): regenerate media-use manifest * fix(cli): preserve media-use parity coverage * fix(cli): cover relocated media-use tests * chore(skills): regenerate media-use manifest * fix(cli): format bundled media provider * fix(ci): run relocated media-use tests with node * fix(ci): preserve fallow script exemptions * fix(ci): scope media-use fallow exemption * refactor(cli): trim media-use essay comments * feat(cli): index media-use assets for catalog search * feat(catalog): commit media-use search vectors * chore(catalog): track media vector metadata * fix(catalog): validate media vector row order * fix(catalog): validate media artifact freshness * fix(catalog): cover media metadata and credits * fix(cli): reject malformed media rows * fix(catalog): compare complete media rows * feat(cli): route media search through media-use * refactor(cli): trim relocated media-use comments * fix(cli): make media search runtime-safe * fix(cli): preserve sfx fallback diagnostics * fix(cli): probe sfx fallback provider explicitly * chore(skills): regenerate manifest * refactor(cli): keep typed media ranker source * fix(cli): align media search checks with local-first flow * fix(cli): scope vector audit exceptions * fix(cli): ship resolver registry beside skill * fix(cli): keep media-use skill scripts standalone * test(cli): cover local vector validation * test(cli): correct media vector fixtures * fix(cli): prefer exact media keys * fix(cli): stem exact media keys * test(cli): skip media lint for snippets without media * fix(cli): align skills test discovery Keep the CI skills job's bash discovery as the single source of truth so its empty-list guard covers the exact files Node executes. Make hasMediaVectors private because it has no external callers and needs no Fallow suppression. * fix(cli): close media-use review gaps Prioritize literal ids before stemmed ids and cover the collision alongside the plural regression. Add command seam tests for engine discovery, actionable failure, and argv passthrough. Add a deterministic parity check for standalone media-use copies, with documented allowlists for the standalone media-fetch shim and self-contained npx resolver. Keep the bash-discovered skills test list as the CI source of truth. * fix(cli): lower parity check complexity Split missing-copy and unallowlisted-drift checks so the parity guard keeps its behavior without a threshold CRAP score. * fix(cli): close media-use review seams Run the parity test in the skills job so skills-only edits exercise the same check. Export the verb mapping and inject command dispatch for direct coverage. Keep missing-copy diagnostics separate from drift reads. |
||
|
|
8c3590a90e | feat(cli): parakeet ASR engine for transcribe (--engine) + HYPERFRAMES_PYTHON override | ||
|
|
54cab331d0 |
feat(cli): shared TTS/BGM auth preflight + caption and skill-workflow fixes (#1697)
* fix: handle caption skin workflow * docs(skills): simplify the finalize step across video workflows - Drop --strict-layout; all skills use plain `hyperframes inspect` - Add the caption text_box_overflow false-positive note to faceless-explainer - On a failed check, the orchestrator makes the cheapest safe edit itself (no worker re-dispatch / Step 3 backtrack language) - Snapshot: glance at the stitched contact-sheet.jpg and move on Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * feat(auth): onboarding-first `auth status` + shared TTS/BGM preflight When no HeyGen credential is configured, `hyperframes auth status` now prints registration-first guidance instead of a terse error: - Interactive / agent-driven sessions get sign-in guidance led by `hyperframes auth login` (the OAuth step that also creates an account and is shared with heygen-cli), and never steer users to a per-repo `.env`. CI / non-interactive runs get a terse note. Exit 1 is kept so the "am I logged in?" `$?` contract still holds. - It probes which local engine voice/music will fall back to (Kokoro / MusicGen, mirroring the skill resolution order) and whether their Python deps are installed, with a pip hint when missing. `--json` exposes `recommended_action` + `offline_engines` for skills to branch. - `doctor` gains matching "TTS (Kokoro)" / "BGM (MusicGen)" checks via the same shared probe (findPython/hasPythonModules extracted to tts/python.ts; provider resolution in audio/providers.ts). Every TTS/BGM workflow now relays this at Step 0 (setup) instead of improvising its own "missing key" prompt: pr-to-video, product-launch- video, faceless-explainer, website-to-video, music-to-video. The canonical behavior + key-priority table live once in hyperframes-media. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * feat(pr-to-video): scale recommended video length to PR change size Step 0 led with a fixed ~60-90s length default. Now the recommended length is derived from the PR's diff stat (lines added+deleted, nudged by file count) on a tier scale (trivial ~20-40s → large ~110-180s, hard cap ~3 min), reusing the same PR peek already done to infer the angle. The agent states the basis when proposing it, and a huge PR with one headline change still stays tight. User can always override. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * fix(captions): embed brand fonts whose files use separators brandFontFaces() matched font files by stripping only whitespace, so an underscore/hyphen-named file (TT_Norms_Pro_Bold.woff2) never matched the family key "ttnormspro" — captions shipped with no @font-face, the font_family_without_font_face bug. Now both family and filename normalize away all non-alphanumerics; families match longest-key-first so a parent family can't swallow a more specific one's files (TT Norms Pro vs Mono); each file is claimed once; "demibold" ranks before "bold"; and when nothing matches it warns loudly at build time instead of returning "". Also: parseFonts() falls back to h1/h2/title/hero display roles, and the frame-worker + caption authoring docs spell out that only shipped font files render — no system CJK/Devanagari families on the headless renderer. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * fix(hyperframes-media): enforce sign-in preflight on standalone BGM/TTS A one-off "generate me a BGM" request went straight to local MusicGen without recommending sign-in: bgm.md/tts.md framed the no-credential path as an automatic fallback, so the generation path bypassed the Preflight stop, and the preflight used a bare `hyperframes auth status` that isn't on PATH in a fresh `npx skills` project. - Preflight now applies to one-off generation as well as workflows, uses `npx hyperframes auth status`, and says: if the CLI can't run, still recommend signing in and STOP — never treat "no credential" as a silent green light for local generation. - bgm.md and tts.md point at the Preflight before generating, reframing local generation as the fallback the user opts into, not a default. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * docs(auth): add Authentication & API keys guide Document signing in, the keys each capability (voice, music, capture) uses, their resolution priority, and the fully local fallback. Add the guide to the nav and cross-link it from the cloud deploy note and the CLI env-var reference. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * fix(lint): strip HTML comments in a fixpoint loop (CodeQL) Single-pass <!-- --> removal can re-form a complete comment from adjacent markers (e.g. `<<!-- -->!-- ... -->`), letting a decoy <template> survive and hijack the template-boundary match. Loop to a fixpoint, mirroring the captions.mjs precedent; add a regression test that fails on single-pass (2 root findings) and passes on the loop. Also wrap the build-frame.mjs node:fs imports to satisfy oxfmt — the new copyFileSync import pushed the line past the width limit, which was the sole cause of the Format / Preflight CI failures. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * fix(lint): strip HTML comments with a linear scan (CodeQL ReDoS) The fixpoint loop still ran a /<!--[\s\S]*?-->/ regex per pass, which backtracks O(n^2) on inputs with many unterminated "<!--" — CodeQL js/polynomial-redos (high). Looping the same regex (the prescribed fix) never addressed this; only the regex itself does. Replace it with an indexOf-based linear strip in utils.ts (stripHtmlComments), kept in a fixpoint loop so markers that re-form when a comment is removed are still stripped. 200k unterminated "<!--" now strips in ~3ms instead of quadratic time; behavior is otherwise unchanged — unterminated comments are kept verbatim, as the old regex left them. The re-forming regression test still guards it. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * fix(auth): make TTS/BGM sign-in guidance accurate and runnable From team review of the not-signed-in onboarding: - OAuth is a `hyperframes auth login` feature only. The separate `heygen` CLI is API-key-only — `heygen auth login` stores a pasted key, it is not OAuth and does not create an account. Stop presenting the two CLIs as the same OAuth/sign-up step. - Use `npx hyperframes` in every imperative and runtime hint. Bare `hyperframes` is not on PATH on a fresh machine (command not found); only `npx hyperframes` is guaranteed. Also updates the JSON recommended_action. - Drop `heygen auth login` from the terminal/skill onboarding: it needs its own install and there is no `npx heygen`, so it was a command-not-found trap. The shared-credential fact stays in the reference docs. Covers the `auth status` guidance + tests, the Authentication docs, the shared hyperframes-media preflight (SKILL, requirements, tts, error hints), and the `npx hyperframes auth status` preflight in every TTS/BGM workflow (pr-to-video, product-launch-video, faceless-explainer, website-to-video, music-to-video). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> |