@glissade/narrate 0.16.0-pre.0 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +11 -0
- package/dist/providers.js +3 -1
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -137,6 +137,17 @@ interface TimedSegment {
|
|
|
137
137
|
words?: TimedWord[];
|
|
138
138
|
/** anchor budget (s) carried from the script's per-segment `maxSec`; lint reads it here */
|
|
139
139
|
maxSec?: number;
|
|
140
|
+
/**
|
|
141
|
+
* Per-segment voice PROVENANCE (auditability, gh#2): the RESOLVED voice
|
|
142
|
+
* identity that produced THIS segment's audio. A named voice records its name
|
|
143
|
+
* string (e.g. `"zf_xiaoxiao"`); a BLEND records its canonical `blendIdentity()`
|
|
144
|
+
* recipe (`blend=[zf_xiaoni:0.650000,zf_xiaoxiao:0.350000 lang=zh v1]` —
|
|
145
|
+
* normalized weights + base names + language + BLEND_SPEC_VERSION). Optional/
|
|
146
|
+
* additive: omitted when a segment used the provider/script default with no
|
|
147
|
+
* explicit voice. Distinct from the script-level `providerVersion`, which is
|
|
148
|
+
* computed once and cannot capture a per-segment (or per-blend) override.
|
|
149
|
+
*/
|
|
150
|
+
voice?: string;
|
|
140
151
|
}
|
|
141
152
|
/** A resolved pause window in the committed manifest. */
|
|
142
153
|
interface TimedPause {
|
package/dist/providers.js
CHANGED
|
@@ -999,13 +999,15 @@ async function synthesizeScript(scriptPath, opts = {}) {
|
|
|
999
999
|
aligned.push(seg.id);
|
|
1000
1000
|
}
|
|
1001
1001
|
}
|
|
1002
|
+
const voiceProvenance = voiceCacheIdentity(voice);
|
|
1002
1003
|
const timed = {
|
|
1003
1004
|
id: seg.id,
|
|
1004
1005
|
text: seg.text,
|
|
1005
1006
|
start: cursor,
|
|
1006
1007
|
duration,
|
|
1007
1008
|
file: entry.file,
|
|
1008
|
-
...seg.maxSec !== void 0 ? { maxSec: seg.maxSec } : {}
|
|
1009
|
+
...seg.maxSec !== void 0 ? { maxSec: seg.maxSec } : {},
|
|
1010
|
+
...voiceProvenance !== null ? { voice: voiceProvenance } : {}
|
|
1009
1011
|
};
|
|
1010
1012
|
if (words) timed.words = words.map((w) => ({
|
|
1011
1013
|
word: w.word,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@glissade/narrate",
|
|
3
|
-
"version": "0.16.0
|
|
3
|
+
"version": "0.16.0",
|
|
4
4
|
"description": "glissade narration + captions: TTS at prepare time (gs narrate), deterministic caching, narration-anchored timeline beats, and captions as plain tracks. Render stays offline.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"engines": {
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
"dist"
|
|
23
23
|
],
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@glissade/core": "0.16.0
|
|
26
|
-
"@glissade/scene": "0.16.0
|
|
25
|
+
"@glissade/core": "0.16.0",
|
|
26
|
+
"@glissade/scene": "0.16.0"
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"kokoro-js": "^1.2.0"
|