Skip to content

Add prosody model; bump spec to v0.2.0 - #1

Merged
mikkel-bergmann merged 1 commit into
mainfrom
add-prosody
Jul 2, 2026
Merged

Add prosody model; bump spec to v0.2.0#1
mikkel-bergmann merged 1 commit into
mainfrom
add-prosody

Conversation

@mikkel-bergmann

Copy link
Copy Markdown
Owner

Summary

Adds a core prosody model to the Podscript spec and bumps the spec to v0.2.0 (minor, backward-compatible).

Prosody is how a line is spoken. A new prosody control carries the three continuous acoustic correlates — rate (tempo), pitch (semitone shift), volume (vocal intensity) — as a per-voice baseline and a per-line override, merged per attribute. The remaining prosodic dimensions map onto constructs that already exist:

Prosodic dimension Control
Rate / pitch / volume prosody rate 1.15 pitch +2st volume 1.1 (new)
Stress / focus *emphasis*
Rhythm / pausing ..., {break Nms}
Intonation contour sentence punctuation
Emotion / attitude (direction)

Design highlights

  • Synthesis-only, deterministic-safe: prosody never enters resolver timing — the resolver bakes the effective (per-attribute merged) value onto the IR clip and omits natural defaults. start/dur/end are unaffected.
  • Advisory / best-effort: a deliberate exception to fail-closed (§15.4) — core vocabulary, but engines drop attributes they can't honour (like (direction)), degrading expressiveness, not mix correctness. rate is near-universal; pitch/volume vary. Grounded in what real engines actually expose (ElevenLabs has no SSML/per-word rate; only a whole-request speed).
  • volumegain: vocal effort at synthesis vs. mix fader level in dB — kept explicitly distinct.

Versioning

  • Adopt three-part semver; spec → 0.2.0. PATCH optional (0.10.1.0, still valid input).
  • Normalized every bundled example/fixture stamp to 0.2.0 (stamp-only, pre-1.0 housekeeping — no script's meaning changes).
  • New CHANGELOG.md.

What's included

  • SPEC: §1.5 SEMITONES token, §2.3 voice prosody, §5/§5.5 clause + full model, §10 AST types, §11/§11.1 IR, §14.3 cache key, §1.2/§20 semver.
  • Docs/examples: AUTHORING Prosody section; runnable examples/prosody.podscript (single-sourced + CI-guarded).
  • Conformance: new parse/prosody and resolve/prosody fixtures; existing fixtures restamped.
  • OpenSpec: openspec/specs/prosody/ capability spec; add-prosody change archived.

Validation

  • Docs-drift guard: 3 tagged blocks, 0 problems
  • reuse lint: 48/48 compliant
  • Existing golden fixtures: differ from prior only by the version stamp (structure/timing unchanged)
  • New fixtures: JSON valid; per-attribute merge + default-omission verified; timing recomputed

🤖 Generated with Claude Code

Introduce a core prosody model (SPEC §5.5): a `prosody` control carrying the
continuous attributes `rate` (tempo multiplier), `pitch` (semitone shift), and
`volume` (vocal-intensity multiplier), as a per-voice baseline object (§2.3) and a
per-line cue clause (§5), merged per attribute onto the IR clip and omitted at natural
defaults (§11.1). The section maps the remaining prosodic dimensions onto existing
constructs (*emphasis*, breaks, punctuation, direction).

Prosody is advisory synthesis guidance — a deliberate exception to fail-closed
(§15.4): core vocabulary, but engines drop attributes they cannot honour, degrading
expressiveness not mix correctness. It joins the synthesis cache key (§14.3) and does
not affect timing/resolution. New SEMITONES token (§1.5); AST Voice.prosody / Prosody
interface / prosody clause variant (§10); IR-clip prosody.

Versioning: adopt three-part semver and bump the spec to v0.2.0 (minor). Normalize
every example and conformance-fixture stamp to 0.2.0 (stamp-only, pre-1.0 housekeeping;
0.1 remains valid input). Add CHANGELOG.md.

Docs/examples: AUTHORING Prosody section + runnable examples/prosody.podscript
(single-sourced, CI-guarded). Conformance: new parse/prosody and resolve/prosody
fixtures. OpenSpec: prosody capability spec added; add-prosody change archived.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@mikkel-bergmann
mikkel-bergmann merged commit 501903a into main Jul 2, 2026
4 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