Skip to content

[codex] Trigger prosodic nods from vocal speech timing#28

Closed
meekmachine wants to merge 2 commits into
mainfrom
codex/697-prosodic-nod-inherit
Closed

[codex] Trigger prosodic nods from vocal speech timing#28
meekmachine wants to merge 2 commits into
mainfrom
codex/697-prosodic-nod-inherit

Conversation

@meekmachine

@meekmachine meekmachine commented Jun 4, 2026

Copy link
Copy Markdown
Owner

Summary

Refs meekmachine/LoomLarge#697.

This keeps speech-time head nods owned by Polyester's prosodic expression agency. The speech/vocal agency now triggers prosodic start, word-boundary pulses, and stop; the prosodic agency remains responsible for loading, scheduling, fading, and playing the head-nod snippets.

What changed

  • VocalService accepts a prosodicService dependency and calls:
    • startTalking() when a sentence/timeline is scheduled
    • pulse(wordIndex) on word boundaries
    • stopTalking() when the speech snippet stops or cleans up
  • TTSService passes its optional prosodicService config through to VocalService, so Web Speech, SAPI, Azure, and external word-boundary paths can use the same agency bridge.
  • Prosodic snippet normalization preserves inherit flags instead of dropping them.
  • Bundled headNodSmall and headNodBig speaking snippets now use inherited AU53/AU54 anchors.
  • AGENTS.md now documents that speech-time prosody belongs in Polyester, not LoomLarge call sites.

Why

The previous LoomLarge-side nod scheduling was the wrong boundary. LoomLarge should configure/pass agencies. Polyester owns speech timing, prosodic pulse handling, and animation scheduling. This PR fixes the inherited-keyframe issue inside the owning agency path and wires speech timing to that agency.

Validation

  • npm exec vitest run src/vocal/__tests__/service.test.ts src/animation/__tests__/snippetPreloader.test.ts src/prosodic/__tests__/prosodicService.test.ts
  • npm run typecheck

@meekmachine meekmachine changed the title [codex] Preserve inherited prosodic nod keyframes [codex] Trigger prosodic nods from vocal speech timing Jun 4, 2026
@meekmachine

Copy link
Copy Markdown
Owner Author

Closing this draft for now. The current goal is to avoid changing Polyester and first verify whether the prosodic/head-nod animation data should be updated in stored animation data rather than package code.

@meekmachine meekmachine closed this Jun 4, 2026
@meekmachine meekmachine deleted the codex/697-prosodic-nod-inherit branch June 4, 2026 15:07
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