storyforge 0.14.1 → 0.15.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.
|
@@ -620,8 +620,8 @@ function getErrorMap() {
|
|
|
620
620
|
|
|
621
621
|
// ../../node_modules/zod/v3/helpers/parseUtil.js
|
|
622
622
|
var makeIssue = (params) => {
|
|
623
|
-
const { data, path:
|
|
624
|
-
const fullPath = [...
|
|
623
|
+
const { data, path: path17, errorMaps, issueData } = params;
|
|
624
|
+
const fullPath = [...path17, ...issueData.path || []];
|
|
625
625
|
const fullIssue = {
|
|
626
626
|
...issueData,
|
|
627
627
|
path: fullPath
|
|
@@ -737,11 +737,11 @@ var errorUtil;
|
|
|
737
737
|
|
|
738
738
|
// ../../node_modules/zod/v3/types.js
|
|
739
739
|
var ParseInputLazyPath = class {
|
|
740
|
-
constructor(parent, value,
|
|
740
|
+
constructor(parent, value, path17, key) {
|
|
741
741
|
this._cachedPath = [];
|
|
742
742
|
this.parent = parent;
|
|
743
743
|
this.data = value;
|
|
744
|
-
this._path =
|
|
744
|
+
this._path = path17;
|
|
745
745
|
this._key = key;
|
|
746
746
|
}
|
|
747
747
|
get path() {
|
|
@@ -5647,7 +5647,8 @@ var renderGeminiRemotion = async (shot, ctx) => {
|
|
|
5647
5647
|
fps: ctx.fps,
|
|
5648
5648
|
intent: shot.intent ?? "",
|
|
5649
5649
|
...shot.citationUrl ? { citationUrl: shot.citationUrl } : {},
|
|
5650
|
-
...shot.quotedPhrase ? { quotedPhrase: shot.quotedPhrase } : {}
|
|
5650
|
+
...shot.quotedPhrase ? { quotedPhrase: shot.quotedPhrase } : {},
|
|
5651
|
+
...shot.textPosition ? { textPosition: shot.textPosition } : {}
|
|
5651
5652
|
},
|
|
5652
5653
|
null,
|
|
5653
5654
|
2
|
|
@@ -7732,6 +7733,7 @@ function abortedSkeleton(spec) {
|
|
|
7732
7733
|
}
|
|
7733
7734
|
|
|
7734
7735
|
// src/bridge-poller.ts
|
|
7736
|
+
import * as path16 from "path";
|
|
7735
7737
|
var HEARTBEAT_INTERVAL_MS = 6e4;
|
|
7736
7738
|
var POLL_INTERVAL_MS = 8e3;
|
|
7737
7739
|
var CANCEL_POLL_INTERVAL_MS = 5e3;
|
|
@@ -7795,8 +7797,8 @@ var BridgePoller = class {
|
|
|
7795
7797
|
if (!/^[a-z][a-z0-9-]*$/i.test(name)) return { available: false, path: null };
|
|
7796
7798
|
const r = spawnSync("which", [name], { encoding: "utf-8", timeout: 2e3 });
|
|
7797
7799
|
if (r.status !== 0) return { available: false, path: null };
|
|
7798
|
-
const
|
|
7799
|
-
return { available: !!
|
|
7800
|
+
const path17 = (r.stdout ?? "").trim();
|
|
7801
|
+
return { available: !!path17, path: path17 || null };
|
|
7800
7802
|
}
|
|
7801
7803
|
async heartbeat() {
|
|
7802
7804
|
if (this.stopped) return;
|
|
@@ -8011,6 +8013,26 @@ var BridgePoller = class {
|
|
|
8011
8013
|
void this.postRenderProgress(jobId, payload.projectId, event);
|
|
8012
8014
|
};
|
|
8013
8015
|
try {
|
|
8016
|
+
const os2 = await import("os");
|
|
8017
|
+
const audioStageDir = path16.join(os2.tmpdir(), "forge-audio");
|
|
8018
|
+
await fs18.promises.mkdir(audioStageDir, { recursive: true });
|
|
8019
|
+
await Promise.all(
|
|
8020
|
+
payload.specs.map(async (spec) => {
|
|
8021
|
+
if (spec.audioPath) return;
|
|
8022
|
+
const url = spec.audioStorjUrl;
|
|
8023
|
+
if (!url) return;
|
|
8024
|
+
const localPath = path16.join(audioStageDir, `${spec.chunkId}.mp3`);
|
|
8025
|
+
try {
|
|
8026
|
+
const resp = await fetch(url);
|
|
8027
|
+
if (!resp.ok) throw new Error(`HTTP ${resp.status}`);
|
|
8028
|
+
const buf = Buffer.from(await resp.arrayBuffer());
|
|
8029
|
+
await fs18.promises.writeFile(localPath, buf);
|
|
8030
|
+
spec.audioPath = localPath;
|
|
8031
|
+
} catch (err) {
|
|
8032
|
+
log.info(`[bridge] audio download failed for chunk ${spec.chunkId}: ${err.message} \u2014 rendering silent clip`);
|
|
8033
|
+
}
|
|
8034
|
+
})
|
|
8035
|
+
);
|
|
8014
8036
|
const result = await renderChunksParallel(payload.specs, {
|
|
8015
8037
|
concurrency: payload.options?.concurrency,
|
|
8016
8038
|
failFast: payload.options?.failFast,
|
|
@@ -8241,9 +8263,9 @@ var BridgePoller = class {
|
|
|
8241
8263
|
error: `stitch-final job requires @forge/pipeline/stitch (not installed): ${err.message}`
|
|
8242
8264
|
};
|
|
8243
8265
|
}
|
|
8244
|
-
const
|
|
8245
|
-
const projectRoot =
|
|
8246
|
-
const clipsDir =
|
|
8266
|
+
const path17 = await import("path");
|
|
8267
|
+
const projectRoot = path17.resolve(process.cwd(), "forge-renders", payload.projectSlug);
|
|
8268
|
+
const clipsDir = path17.join(projectRoot, "clips");
|
|
8247
8269
|
const publish = async (phase, eventPayload) => {
|
|
8248
8270
|
try {
|
|
8249
8271
|
await fetch(`${this.baseUrl}/api/cli-bridge/stitch-event`, {
|
|
@@ -8269,7 +8291,7 @@ var BridgePoller = class {
|
|
|
8269
8291
|
projectSlug: payload.projectSlug,
|
|
8270
8292
|
clipsDir,
|
|
8271
8293
|
chunkOrder: payload.chunkOrder ?? [],
|
|
8272
|
-
masterAudioPath:
|
|
8294
|
+
masterAudioPath: path17.isAbsolute(masterAudioRel) ? masterAudioRel : path17.join(projectRoot, masterAudioRel),
|
|
8273
8295
|
outputDir: projectRoot,
|
|
8274
8296
|
aspect: payload.aspect,
|
|
8275
8297
|
skipTransitions: payload.skipTransitions,
|
package/dist/index.js
CHANGED
|
@@ -1689,7 +1689,7 @@ Return ONLY the complete updated TSX. No markdown fences, no explanation.`;
|
|
|
1689
1689
|
return "0.0.0";
|
|
1690
1690
|
})();
|
|
1691
1691
|
void (async () => {
|
|
1692
|
-
const { BridgePoller } = await import("./bridge-poller-
|
|
1692
|
+
const { BridgePoller } = await import("./bridge-poller-NOG4WB3K.js");
|
|
1693
1693
|
const poller = new BridgePoller({ baseUrl: bridgeUrl, token: bridgeToken2, clientVersion: `storyforge ${pkgVersion}` });
|
|
1694
1694
|
poller.start();
|
|
1695
1695
|
})();
|
|
@@ -2512,7 +2512,7 @@ function resolveBridgeToken2(explicit) {
|
|
|
2512
2512
|
// package.json
|
|
2513
2513
|
var package_default = {
|
|
2514
2514
|
name: "storyforge",
|
|
2515
|
-
version: "0.
|
|
2515
|
+
version: "0.15.0",
|
|
2516
2516
|
description: "StoryForge \u2014 local bridge for the Forge video production web app. Parallel clip-render orchestrator (Remotion 4 + Manim + HyperFrames + ffmpeg) + final video stitcher + dependency doctor.",
|
|
2517
2517
|
type: "module",
|
|
2518
2518
|
bin: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "storyforge",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "StoryForge — local bridge for the Forge video production web app. Parallel clip-render orchestrator (Remotion 4 + Manim + HyperFrames + ffmpeg) + final video stitcher + dependency doctor.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|