@nodetool-ai/protocol 0.8.2 → 0.8.4-a13.1
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/README.md +1 -1
- package/dist/.nodetool-build-stamp +1 -1
- package/dist/api-schemas/api-error-code.d.ts +9 -1
- package/dist/api-schemas/api-error-code.d.ts.map +1 -1
- package/dist/api-schemas/api-error-code.js +6 -0
- package/dist/api-schemas/api-error-code.js.map +1 -1
- package/dist/api-schemas/app-runs.d.ts +28 -0
- package/dist/api-schemas/app-runs.d.ts.map +1 -1
- package/dist/api-schemas/applications.d.ts +46 -0
- package/dist/api-schemas/applications.d.ts.map +1 -1
- package/dist/api-schemas/applications.js +4 -1
- package/dist/api-schemas/applications.js.map +1 -1
- package/dist/api-schemas/assets.d.ts +7 -0
- package/dist/api-schemas/assets.d.ts.map +1 -1
- package/dist/api-schemas/assets.js +5 -0
- package/dist/api-schemas/assets.js.map +1 -1
- package/dist/api-schemas/jobs.d.ts +7 -0
- package/dist/api-schemas/jobs.d.ts.map +1 -1
- package/dist/api-schemas/messages.d.ts +9 -0
- package/dist/api-schemas/messages.d.ts.map +1 -1
- package/dist/api-schemas/messages.js +10 -0
- package/dist/api-schemas/messages.js.map +1 -1
- package/dist/api-schemas/nodes.d.ts +2 -0
- package/dist/api-schemas/nodes.d.ts.map +1 -1
- package/dist/api-schemas/nodes.js +2 -1
- package/dist/api-schemas/nodes.js.map +1 -1
- package/dist/api-schemas/projects.d.ts +102 -6
- package/dist/api-schemas/projects.d.ts.map +1 -1
- package/dist/api-schemas/projects.js +24 -0
- package/dist/api-schemas/projects.js.map +1 -1
- package/dist/api-schemas/recipes.d.ts +8 -0
- package/dist/api-schemas/recipes.d.ts.map +1 -1
- package/dist/api-schemas/sdk-execution-v1.d.ts +81 -0
- package/dist/api-schemas/sdk-execution-v1.d.ts.map +1 -1
- package/dist/api-schemas/sdk-v1-http-operations.d.ts +2 -0
- package/dist/api-schemas/sdk-v1-http-operations.d.ts.map +1 -1
- package/dist/api-schemas/sketch.d.ts +40 -0
- package/dist/api-schemas/sketch.d.ts.map +1 -1
- package/dist/api-schemas/sketch.js +14 -4
- package/dist/api-schemas/sketch.js.map +1 -1
- package/dist/api-schemas/storyboards.d.ts +170 -0
- package/dist/api-schemas/storyboards.d.ts.map +1 -1
- package/dist/api-schemas/storyboards.js +42 -2
- package/dist/api-schemas/storyboards.js.map +1 -1
- package/dist/api-schemas/timeline-tool-contracts.d.ts +56 -0
- package/dist/api-schemas/timeline-tool-contracts.d.ts.map +1 -1
- package/dist/api-schemas/timeline-tool-contracts.js +17 -15
- package/dist/api-schemas/timeline-tool-contracts.js.map +1 -1
- package/dist/api-schemas/timeline-tool-params.d.ts.map +1 -1
- package/dist/api-schemas/timeline-tool-params.js +2 -1
- package/dist/api-schemas/timeline-tool-params.js.map +1 -1
- package/dist/api-schemas/timeline.d.ts +493 -0
- package/dist/api-schemas/timeline.d.ts.map +1 -1
- package/dist/api-schemas/timeline.js +49 -1
- package/dist/api-schemas/timeline.js.map +1 -1
- package/dist/api-schemas/workflows.d.ts +180 -0
- package/dist/api-schemas/workflows.d.ts.map +1 -1
- package/dist/api-schemas/workflows.js +41 -4
- package/dist/api-schemas/workflows.js.map +1 -1
- package/dist/api-types.d.ts +20 -2
- package/dist/api-types.d.ts.map +1 -1
- package/dist/api-types.js +17 -1
- package/dist/api-types.js.map +1 -1
- package/dist/bridge-frames.d.ts +23 -3
- package/dist/bridge-frames.d.ts.map +1 -1
- package/dist/bridge-frames.js +24 -3
- package/dist/bridge-frames.js.map +1 -1
- package/dist/bridge-frames.schema.json +31 -0
- package/dist/bridge-protocol.d.ts +8 -7
- package/dist/bridge-protocol.d.ts.map +1 -1
- package/dist/bridge-protocol.js +8 -7
- package/dist/bridge-protocol.js.map +1 -1
- package/dist/cloud-profile.d.ts +13 -0
- package/dist/cloud-profile.d.ts.map +1 -1
- package/dist/cloud-profile.js +37 -0
- package/dist/cloud-profile.js.map +1 -1
- package/dist/creative.d.ts +4 -0
- package/dist/creative.d.ts.map +1 -1
- package/dist/creative.js.map +1 -1
- package/dist/custom-providers.js +1 -1
- package/dist/custom-providers.js.map +1 -1
- package/dist/example-needs.d.ts +24 -0
- package/dist/example-needs.d.ts.map +1 -0
- package/dist/example-needs.js +64 -0
- package/dist/example-needs.js.map +1 -0
- package/dist/game-asset-catalog.d.ts +129 -0
- package/dist/game-asset-catalog.d.ts.map +1 -0
- package/dist/game-asset-catalog.js +208 -0
- package/dist/game-asset-catalog.js.map +1 -0
- package/dist/game-design.d.ts +18 -0
- package/dist/game-design.d.ts.map +1 -1
- package/dist/game-design.js +148 -0
- package/dist/game-design.js.map +1 -1
- package/dist/game-entity-metadata.d.ts +7 -0
- package/dist/game-entity-metadata.d.ts.map +1 -0
- package/dist/game-entity-metadata.js +42 -0
- package/dist/game-entity-metadata.js.map +1 -0
- package/dist/game-input.d.ts +186 -0
- package/dist/game-input.d.ts.map +1 -0
- package/dist/game-input.js +166 -0
- package/dist/game-input.js.map +1 -0
- package/dist/game-particles.d.ts +388 -0
- package/dist/game-particles.d.ts.map +1 -0
- package/dist/game-particles.js +173 -0
- package/dist/game-particles.js.map +1 -0
- package/dist/game-saves.d.ts +73 -0
- package/dist/game-saves.d.ts.map +1 -0
- package/dist/game-saves.js +87 -0
- package/dist/game-saves.js.map +1 -0
- package/dist/game-screens.d.ts +2031 -0
- package/dist/game-screens.d.ts.map +1 -0
- package/dist/game-screens.js +89 -0
- package/dist/game-screens.js.map +1 -0
- package/dist/game-script-events.d.ts +32 -0
- package/dist/game-script-events.d.ts.map +1 -0
- package/dist/game-script-events.js +32 -0
- package/dist/game-script-events.js.map +1 -0
- package/dist/game-script-params.d.ts +134 -0
- package/dist/game-script-params.d.ts.map +1 -0
- package/dist/game-script-params.js +109 -0
- package/dist/game-script-params.js.map +1 -0
- package/dist/game-slot-prompt.d.ts +6 -1
- package/dist/game-slot-prompt.d.ts.map +1 -1
- package/dist/game-slot-prompt.js +1 -1
- package/dist/game-slot-prompt.js.map +1 -1
- package/dist/game-ui.d.ts +681 -0
- package/dist/game-ui.d.ts.map +1 -0
- package/dist/game-ui.js +215 -0
- package/dist/game-ui.js.map +1 -0
- package/dist/game2d/components/audio.d.ts +144 -0
- package/dist/game2d/components/audio.d.ts.map +1 -0
- package/dist/game2d/components/audio.js +137 -0
- package/dist/game2d/components/audio.js.map +1 -0
- package/dist/game2d/components/audioSource.d.ts +65 -0
- package/dist/game2d/components/audioSource.d.ts.map +1 -1
- package/dist/game2d/components/audioSource.js +44 -1
- package/dist/game2d/components/audioSource.js.map +1 -1
- package/dist/game2d/components/behaviors.d.ts +53 -0
- package/dist/game2d/components/behaviors.d.ts.map +1 -1
- package/dist/game2d/components/behaviors.js +4 -1
- package/dist/game2d/components/behaviors.js.map +1 -1
- package/dist/game2d/components/entity-components.d.ts +149 -0
- package/dist/game2d/components/entity-components.d.ts.map +1 -1
- package/dist/game2d/components/entity-components.js +3 -1
- package/dist/game2d/components/entity-components.js.map +1 -1
- package/dist/game2d/components/music.d.ts +4 -0
- package/dist/game2d/components/music.d.ts.map +1 -1
- package/dist/game2d/components/music.js +12 -1
- package/dist/game2d/components/music.js.map +1 -1
- package/dist/game2d/index.d.ts +2838 -76
- package/dist/game2d/index.d.ts.map +1 -1
- package/dist/game2d/index.js +44 -9
- package/dist/game2d/index.js.map +1 -1
- package/dist/game3d/components/animation-graph.d.ts +336 -0
- package/dist/game3d/components/animation-graph.d.ts.map +1 -0
- package/dist/game3d/components/animation-graph.js +66 -0
- package/dist/game3d/components/animation-graph.js.map +1 -0
- package/dist/game3d/components/animator.d.ts +1 -0
- package/dist/game3d/components/animator.d.ts.map +1 -1
- package/dist/game3d/components/animator.js +2 -1
- package/dist/game3d/components/animator.js.map +1 -1
- package/dist/game3d/components/assets.d.ts +58 -0
- package/dist/game3d/components/assets.d.ts.map +1 -1
- package/dist/game3d/components/assets.js +8 -1
- package/dist/game3d/components/assets.js.map +1 -1
- package/dist/game3d/components/behaviors.d.ts +106 -0
- package/dist/game3d/components/behaviors.d.ts.map +1 -1
- package/dist/game3d/components/collider.d.ts +70 -0
- package/dist/game3d/components/collider.d.ts.map +1 -1
- package/dist/game3d/components/collider.js +10 -2
- package/dist/game3d/components/collider.js.map +1 -1
- package/dist/game3d/components/collision-matrix.d.ts +6 -0
- package/dist/game3d/components/collision-matrix.d.ts.map +1 -0
- package/dist/game3d/components/collision-matrix.js +7 -0
- package/dist/game3d/components/collision-matrix.js.map +1 -0
- package/dist/game3d/components/environment.d.ts +91 -0
- package/dist/game3d/components/environment.d.ts.map +1 -1
- package/dist/game3d/components/environment.js +35 -2
- package/dist/game3d/components/environment.js.map +1 -1
- package/dist/game3d/components/force-command.d.ts +30 -0
- package/dist/game3d/components/force-command.d.ts.map +1 -0
- package/dist/game3d/components/force-command.js +10 -0
- package/dist/game3d/components/force-command.js.map +1 -0
- package/dist/game3d/components/light.d.ts +8 -0
- package/dist/game3d/components/light.d.ts.map +1 -1
- package/dist/game3d/components/light.js +8 -3
- package/dist/game3d/components/light.js.map +1 -1
- package/dist/game3d/components/material.d.ts +66 -0
- package/dist/game3d/components/material.d.ts.map +1 -1
- package/dist/game3d/components/material.js +13 -2
- package/dist/game3d/components/material.js.map +1 -1
- package/dist/game3d/components/model.d.ts +54 -0
- package/dist/game3d/components/model.d.ts.map +1 -1
- package/dist/game3d/components/model.js +1 -0
- package/dist/game3d/components/model.js.map +1 -1
- package/dist/game3d/components/performance.d.ts +30 -0
- package/dist/game3d/components/performance.d.ts.map +1 -0
- package/dist/game3d/components/performance.js +27 -0
- package/dist/game3d/components/performance.js.map +1 -0
- package/dist/game3d/components/physics-material.d.ts +50 -0
- package/dist/game3d/components/physics-material.d.ts.map +1 -0
- package/dist/game3d/components/physics-material.js +20 -0
- package/dist/game3d/components/physics-material.js.map +1 -0
- package/dist/game3d/components/primitive.d.ts +54 -0
- package/dist/game3d/components/primitive.d.ts.map +1 -1
- package/dist/game3d/components/primitive.js +2 -1
- package/dist/game3d/components/primitive.js.map +1 -1
- package/dist/game3d/components/shadows.d.ts +25 -0
- package/dist/game3d/components/shadows.d.ts.map +1 -0
- package/dist/game3d/components/shadows.js +21 -0
- package/dist/game3d/components/shadows.js.map +1 -0
- package/dist/game3d/index.d.ts +10308 -1187
- package/dist/game3d/index.d.ts.map +1 -1
- package/dist/game3d/index.js +73 -21
- package/dist/game3d/index.js.map +1 -1
- package/dist/graph-links.d.ts +37 -0
- package/dist/graph-links.d.ts.map +1 -0
- package/dist/graph-links.js +73 -0
- package/dist/graph-links.js.map +1 -0
- package/dist/graph.d.ts +19 -0
- package/dist/graph.d.ts.map +1 -1
- package/dist/graph.js.map +1 -1
- package/dist/index.d.ts +12 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +11 -0
- package/dist/index.js.map +1 -1
- package/dist/messages.d.ts +302 -0
- package/dist/messages.d.ts.map +1 -1
- package/dist/messages.js +7 -1
- package/dist/messages.js.map +1 -1
- package/dist/missing-pack.d.ts +45 -0
- package/dist/missing-pack.d.ts.map +1 -0
- package/dist/missing-pack.js +53 -0
- package/dist/missing-pack.js.map +1 -0
- package/dist/missing-runtime-package.d.ts +63 -1
- package/dist/missing-runtime-package.d.ts.map +1 -1
- package/dist/missing-runtime-package.js +167 -1
- package/dist/missing-runtime-package.js.map +1 -1
- package/dist/native-game-templates.d.ts +21 -0
- package/dist/native-game-templates.d.ts.map +1 -0
- package/dist/native-game-templates.js +32 -0
- package/dist/native-game-templates.js.map +1 -0
- package/dist/nodetool-models.js +2 -2
- package/dist/nodetool-models.js.map +1 -1
- package/dist/one-take.d.ts +134 -0
- package/dist/one-take.d.ts.map +1 -0
- package/dist/one-take.js +207 -0
- package/dist/one-take.js.map +1 -0
- package/dist/processing-messages.schema.json +357 -0
- package/dist/python-packs.d.ts +27 -4
- package/dist/python-packs.d.ts.map +1 -1
- package/dist/python-packs.js +46 -17
- package/dist/python-packs.js.map +1 -1
- package/dist/resource-id.d.ts +10 -0
- package/dist/resource-id.d.ts.map +1 -1
- package/dist/resource-id.js +21 -0
- package/dist/resource-id.js.map +1 -1
- package/dist/run-trace.d.ts +2 -0
- package/dist/run-trace.d.ts.map +1 -1
- package/dist/run-trace.js +29 -3
- package/dist/run-trace.js.map +1 -1
- package/dist/runtime-npm-packages.d.ts +101 -0
- package/dist/runtime-npm-packages.d.ts.map +1 -0
- package/dist/runtime-npm-packages.js +124 -0
- package/dist/runtime-npm-packages.js.map +1 -0
- package/dist/screenplay-authoring.js +1 -1
- package/dist/screenplay-authoring.js.map +1 -1
- package/dist/token-providers.d.ts.map +1 -1
- package/dist/token-providers.js +3 -1
- package/dist/token-providers.js.map +1 -1
- package/dist/workflow-document-revision.d.ts +1 -1
- package/dist/workflow-document-revision.d.ts.map +1 -1
- package/dist/workflow-document-revision.js +14 -1
- package/dist/workflow-document-revision.js.map +1 -1
- package/dist/workflow-plan.d.ts +15 -1
- package/dist/workflow-plan.d.ts.map +1 -1
- package/dist/workflow-plan.js +88 -43
- package/dist/workflow-plan.js.map +1 -1
- package/dist/ws-commands.d.ts +9 -0
- package/dist/ws-commands.d.ts.map +1 -1
- package/dist/ws-commands.js +23 -2
- package/dist/ws-commands.js.map +1 -1
- package/package.json +14 -1
- package/schema/sdk-v1.discovery.schema.json +4 -2
- package/schema/sdk-v1.execution.schema.json +734 -0
- package/schema/sdk-v1.manifest.json +2 -2
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* One-take direction: a whole storyboard rendered as one continuous clip.
|
|
3
|
+
*
|
|
4
|
+
* The board stores one prompt the creator writes (brand, rules, light, …).
|
|
5
|
+
* Everything the board already knows is compiled, never stored, so a change
|
|
6
|
+
* to a shot shows up in the editor preview, the render and the agent tools at
|
|
7
|
+
* once:
|
|
8
|
+
*
|
|
9
|
+
* | Block | Compiled from |
|
|
10
|
+
* | ------- | ---------------------------------------------------------------- |
|
|
11
|
+
* | `REFS` | every shot still in shot order, numbered `[Image N]` |
|
|
12
|
+
* | `STEPS` | each shot: time range, description, motion, `End:` end state |
|
|
13
|
+
* | `AUDIO` | each shot's `sound` with its time range |
|
|
14
|
+
*
|
|
15
|
+
* The render sends the creator's prompt, then the compiled block. Duration and
|
|
16
|
+
* aspect ratio travel as request parameters, so the creator's text never has
|
|
17
|
+
* to repeat them.
|
|
18
|
+
*
|
|
19
|
+
* `[Image N]` is the provider-neutral marker the render path already uses: the
|
|
20
|
+
* Dreamina provider turns each one into an inline image mention. Because the
|
|
21
|
+
* numbering follows the board, the creator can refer to `[Image 3]` in their
|
|
22
|
+
* own text.
|
|
23
|
+
*/
|
|
24
|
+
import type { Shot, ShotModelRef } from "./creative.js";
|
|
25
|
+
/**
|
|
26
|
+
* A board's one-take direction, stored on the storyboard document. Every
|
|
27
|
+
* render setting is optional: an absent one falls back as documented.
|
|
28
|
+
*/
|
|
29
|
+
export interface OneTakeDirection {
|
|
30
|
+
/** The creator's own prompt. Sent before the compiled block. */
|
|
31
|
+
prompt: string;
|
|
32
|
+
/**
|
|
33
|
+
* The clip's length in seconds. Absent: the sum of the shot durations. When
|
|
34
|
+
* it differs from that sum, every shot's window scales to fit it.
|
|
35
|
+
*/
|
|
36
|
+
duration_seconds?: number | null;
|
|
37
|
+
/** Absent: the board's aspect ratio. */
|
|
38
|
+
aspect_ratio?: string | null;
|
|
39
|
+
/** Absent: 1080p when the model offers it, else the model's first. */
|
|
40
|
+
resolution?: string | null;
|
|
41
|
+
/** The video model. Absent: the board's video model. */
|
|
42
|
+
model?: ShotModelRef | null;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* One image the clip conditions on, in `[Image N]` order. Only shot stills
|
|
46
|
+
* go in: the stills already carry the cast, so entity images would only
|
|
47
|
+
* compete with them.
|
|
48
|
+
*/
|
|
49
|
+
export interface OneTakeReference {
|
|
50
|
+
shot_id: string;
|
|
51
|
+
asset_id: string;
|
|
52
|
+
label: string;
|
|
53
|
+
}
|
|
54
|
+
/** What {@link compileOneTake} needs from a board. */
|
|
55
|
+
export interface OneTakeBoard {
|
|
56
|
+
shots: readonly Shot[];
|
|
57
|
+
oneTake?: OneTakeDirection | null;
|
|
58
|
+
}
|
|
59
|
+
/** A shot's place on the one-take clock. */
|
|
60
|
+
export interface OneTakeStep {
|
|
61
|
+
shot_id: string;
|
|
62
|
+
start_seconds: number;
|
|
63
|
+
end_seconds: number;
|
|
64
|
+
}
|
|
65
|
+
export interface CompiledOneTake {
|
|
66
|
+
/** The block compiled from the board: REFS, STEPS, AUDIO. */
|
|
67
|
+
compiled: string;
|
|
68
|
+
/** What the render sends: the creator's prompt, then the compiled block. */
|
|
69
|
+
prompt: string;
|
|
70
|
+
/** The images in `[Image N]` order; index 0 is `[Image 1]`. */
|
|
71
|
+
references: OneTakeReference[];
|
|
72
|
+
/** Each shot's window on the clip, in order, scaled to its duration. */
|
|
73
|
+
steps: OneTakeStep[];
|
|
74
|
+
/** The clip's length: the direction's duration, else the shot total. */
|
|
75
|
+
duration_seconds: number;
|
|
76
|
+
/** The sum of the shot durations, before any scaling. */
|
|
77
|
+
shot_total_seconds: number;
|
|
78
|
+
}
|
|
79
|
+
/** A shot without a duration counts as this long. */
|
|
80
|
+
export declare const ONE_TAKE_DEFAULT_SHOT_SECONDS = 5;
|
|
81
|
+
/** `0-5s`, as the compiled blocks print a window. */
|
|
82
|
+
export declare const oneTakeWindow: (start: number, end: number) => string;
|
|
83
|
+
/**
|
|
84
|
+
* The shots in board order, each with its window on the clip. With
|
|
85
|
+
* `durationSeconds`, the windows scale so the last one ends there.
|
|
86
|
+
*/
|
|
87
|
+
export declare function oneTakeSteps(shots: readonly Shot[], durationSeconds?: number | null): OneTakeStep[];
|
|
88
|
+
/** The images the clip conditions on: every shot still, in shot order. */
|
|
89
|
+
export declare function oneTakeReferences(board: OneTakeBoard): OneTakeReference[];
|
|
90
|
+
/**
|
|
91
|
+
* Compile the board's part of the one-take prompt and join it to the
|
|
92
|
+
* creator's prompt. Empty blocks drop.
|
|
93
|
+
*/
|
|
94
|
+
export declare function compileOneTake(board: OneTakeBoard): CompiledOneTake;
|
|
95
|
+
/** The fewest shots one scene clip covers. One shot renders its own clip. */
|
|
96
|
+
export declare const SCENE_CLIP_MIN_SHOTS = 2;
|
|
97
|
+
/** The most shots one scene clip covers. */
|
|
98
|
+
export declare const SCENE_CLIP_MAX_SHOTS = 5;
|
|
99
|
+
/**
|
|
100
|
+
* A run of consecutive shots rendered as one clip: a one take over part of
|
|
101
|
+
* the board. It is stored on the board, so the run, its prompt and its
|
|
102
|
+
* settings survive a reload and a re-render. An absent setting falls back to
|
|
103
|
+
* the board's one-take direction, then as {@link OneTakeDirection} documents.
|
|
104
|
+
*
|
|
105
|
+
* The clip lands on the run's first shot and every other shot in the run is
|
|
106
|
+
* covered by its window of it (`Shot.covered_by`), exactly as a one take.
|
|
107
|
+
*/
|
|
108
|
+
export interface SceneClipDirection extends OneTakeDirection {
|
|
109
|
+
id: string;
|
|
110
|
+
/** The run's shot ids in board order. */
|
|
111
|
+
shot_ids: string[];
|
|
112
|
+
}
|
|
113
|
+
/** A scene clip's shots, or why they no longer form a run. */
|
|
114
|
+
export type SceneClipRun = {
|
|
115
|
+
shots: Shot[];
|
|
116
|
+
issue: null;
|
|
117
|
+
} | {
|
|
118
|
+
shots: Shot[];
|
|
119
|
+
issue: string;
|
|
120
|
+
};
|
|
121
|
+
/**
|
|
122
|
+
* Resolve a scene clip's shots on the board. The run must name between
|
|
123
|
+
* {@link SCENE_CLIP_MIN_SHOTS} and {@link SCENE_CLIP_MAX_SHOTS} existing
|
|
124
|
+
* shots that sit next to each other in board order and share one scene.
|
|
125
|
+
* A deleted or moved shot breaks the run rather than silently changing what
|
|
126
|
+
* the clip covers.
|
|
127
|
+
*/
|
|
128
|
+
export declare function sceneClipRun(shots: readonly Shot[], shotIds: readonly string[]): SceneClipRun;
|
|
129
|
+
/**
|
|
130
|
+
* Compile a scene clip: {@link compileOneTake} over the run's shots alone, so
|
|
131
|
+
* `[Image N]` numbers and the step windows start at the run's first shot.
|
|
132
|
+
*/
|
|
133
|
+
export declare function compileSceneClip(shots: readonly Shot[], clip: SceneClipDirection): CompiledOneTake;
|
|
134
|
+
//# sourceMappingURL=one-take.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"one-take.d.ts","sourceRoot":"","sources":["../src/one-take.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAExD;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,gEAAgE;IAChE,MAAM,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,wCAAwC;IACxC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,sEAAsE;IACtE,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,wDAAwD;IACxD,KAAK,CAAC,EAAE,YAAY,GAAG,IAAI,CAAC;CAC7B;AAED;;;;GAIG;AACH,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,sDAAsD;AACtD,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,SAAS,IAAI,EAAE,CAAC;IACvB,OAAO,CAAC,EAAE,gBAAgB,GAAG,IAAI,CAAC;CACnC;AAED,4CAA4C;AAC5C,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,EAAE,MAAM,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,eAAe;IAC9B,6DAA6D;IAC7D,QAAQ,EAAE,MAAM,CAAC;IACjB,4EAA4E;IAC5E,MAAM,EAAE,MAAM,CAAC;IACf,+DAA+D;IAC/D,UAAU,EAAE,gBAAgB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AgB,CAC9B,KAAK,EAAE,SAAS,IAAI,EAAE,EACtB,IAAI,EAAE,kBAAkB,GACvB,eAAe,CAKjB"}
|
package/dist/one-take.js
ADDED
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* One-take direction: a whole storyboard rendered as one continuous clip.
|
|
3
|
+
*
|
|
4
|
+
* The board stores one prompt the creator writes (brand, rules, light, …).
|
|
5
|
+
* Everything the board already knows is compiled, never stored, so a change
|
|
6
|
+
* to a shot shows up in the editor preview, the render and the agent tools at
|
|
7
|
+
* once:
|
|
8
|
+
*
|
|
9
|
+
* | Block | Compiled from |
|
|
10
|
+
* | ------- | ---------------------------------------------------------------- |
|
|
11
|
+
* | `REFS` | every shot still in shot order, numbered `[Image N]` |
|
|
12
|
+
* | `STEPS` | each shot: time range, description, motion, `End:` end state |
|
|
13
|
+
* | `AUDIO` | each shot's `sound` with its time range |
|
|
14
|
+
*
|
|
15
|
+
* The render sends the creator's prompt, then the compiled block. Duration and
|
|
16
|
+
* aspect ratio travel as request parameters, so the creator's text never has
|
|
17
|
+
* to repeat them.
|
|
18
|
+
*
|
|
19
|
+
* `[Image N]` is the provider-neutral marker the render path already uses: the
|
|
20
|
+
* Dreamina provider turns each one into an inline image mention. Because the
|
|
21
|
+
* numbering follows the board, the creator can refer to `[Image 3]` in their
|
|
22
|
+
* own text.
|
|
23
|
+
*/
|
|
24
|
+
/** A shot without a duration counts as this long. */
|
|
25
|
+
export const ONE_TAKE_DEFAULT_SHOT_SECONDS = 5;
|
|
26
|
+
/** Rounds a window edge to a tenth of a second. */
|
|
27
|
+
const tenth = (value) => Math.round(value * 10) / 10;
|
|
28
|
+
/** `5` → `"5"`, `2.5` → `"2.5"`. */
|
|
29
|
+
const seconds = (value) => Number.isInteger(value) ? String(value) : String(Math.round(value * 10) / 10);
|
|
30
|
+
/** `0-5s`, as the compiled blocks print a window. */
|
|
31
|
+
export const oneTakeWindow = (start, end) => `${seconds(start)}-${seconds(end)}s`;
|
|
32
|
+
const byIndex = (shots) => [...shots].sort((a, b) => a.index - b.index);
|
|
33
|
+
/**
|
|
34
|
+
* The shots in board order, each with its window on the clip. With
|
|
35
|
+
* `durationSeconds`, the windows scale so the last one ends there.
|
|
36
|
+
*/
|
|
37
|
+
export function oneTakeSteps(shots, durationSeconds) {
|
|
38
|
+
const steps = shotSteps(shots);
|
|
39
|
+
const total = steps.at(-1)?.end_seconds ?? 0;
|
|
40
|
+
if (!durationSeconds || durationSeconds <= 0 || total <= 0 || durationSeconds === total) {
|
|
41
|
+
return steps;
|
|
42
|
+
}
|
|
43
|
+
const scale = durationSeconds / total;
|
|
44
|
+
return steps.map((step) => ({
|
|
45
|
+
shot_id: step.shot_id,
|
|
46
|
+
start_seconds: tenth(step.start_seconds * scale),
|
|
47
|
+
end_seconds: tenth(step.end_seconds * scale)
|
|
48
|
+
}));
|
|
49
|
+
}
|
|
50
|
+
/** Each shot's window at its own duration. */
|
|
51
|
+
function shotSteps(shots) {
|
|
52
|
+
let clock = 0;
|
|
53
|
+
return byIndex(shots).map((shot) => {
|
|
54
|
+
const length = shot.duration_seconds && shot.duration_seconds > 0
|
|
55
|
+
? shot.duration_seconds
|
|
56
|
+
: ONE_TAKE_DEFAULT_SHOT_SECONDS;
|
|
57
|
+
const step = {
|
|
58
|
+
shot_id: shot.id,
|
|
59
|
+
start_seconds: clock,
|
|
60
|
+
end_seconds: clock + length
|
|
61
|
+
};
|
|
62
|
+
clock += length;
|
|
63
|
+
return step;
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
const sentence = (text) => {
|
|
67
|
+
const trimmed = (text ?? "").trim();
|
|
68
|
+
return trimmed.length === 0 || /[.!?…:]$/.test(trimmed)
|
|
69
|
+
? trimmed
|
|
70
|
+
: `${trimmed}.`;
|
|
71
|
+
};
|
|
72
|
+
/** A shot's name in a reference label: its title, else "shot N". */
|
|
73
|
+
const shotName = (shot) => shot.slug?.trim() || `shot ${shot.index + 1}`;
|
|
74
|
+
/** The images the clip conditions on: every shot still, in shot order. */
|
|
75
|
+
export function oneTakeReferences(board) {
|
|
76
|
+
const steps = new Map(oneTakeSteps(board.shots, board.oneTake?.duration_seconds).map((step) => [
|
|
77
|
+
step.shot_id,
|
|
78
|
+
step
|
|
79
|
+
]));
|
|
80
|
+
return byIndex(board.shots).flatMap((shot) => {
|
|
81
|
+
const assetId = shot.keyframe?.asset_id;
|
|
82
|
+
const step = steps.get(shot.id);
|
|
83
|
+
if (!assetId || !step) {
|
|
84
|
+
return [];
|
|
85
|
+
}
|
|
86
|
+
return [
|
|
87
|
+
{
|
|
88
|
+
shot_id: shot.id,
|
|
89
|
+
asset_id: assetId,
|
|
90
|
+
label: `the still of ${shotName(shot)} at ${oneTakeWindow(step.start_seconds, step.end_seconds)}`
|
|
91
|
+
}
|
|
92
|
+
];
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
function compileRefs(references) {
|
|
96
|
+
return references
|
|
97
|
+
.map((reference, index) => `[Image ${index + 1}] is ${reference.label}.`)
|
|
98
|
+
.join(" ");
|
|
99
|
+
}
|
|
100
|
+
function compileSteps(shots, steps) {
|
|
101
|
+
const byId = new Map(shots.map((shot) => [shot.id, shot]));
|
|
102
|
+
return steps
|
|
103
|
+
.map((step, index) => {
|
|
104
|
+
const shot = byId.get(step.shot_id);
|
|
105
|
+
const body = [sentence(shot?.action), sentence(shot?.motion)]
|
|
106
|
+
.filter((part) => part.length > 0)
|
|
107
|
+
.join(" ");
|
|
108
|
+
const end = shot?.end_state?.trim()
|
|
109
|
+
? ` End: ${sentence(shot.end_state)}`
|
|
110
|
+
: "";
|
|
111
|
+
const number = String(index + 1).padStart(2, "0");
|
|
112
|
+
return `STEP_${number}: ${oneTakeWindow(step.start_seconds, step.end_seconds)}. ${body}${end}`.trimEnd();
|
|
113
|
+
})
|
|
114
|
+
.join("\n");
|
|
115
|
+
}
|
|
116
|
+
function compileAudio(shots, steps) {
|
|
117
|
+
const byId = new Map(shots.map((shot) => [shot.id, shot]));
|
|
118
|
+
return steps
|
|
119
|
+
.map((step) => {
|
|
120
|
+
const sound = byId.get(step.shot_id)?.sound?.trim();
|
|
121
|
+
return sound
|
|
122
|
+
? `<${sound}> at ${oneTakeWindow(step.start_seconds, step.end_seconds)}`
|
|
123
|
+
: null;
|
|
124
|
+
})
|
|
125
|
+
.filter((cue) => cue !== null)
|
|
126
|
+
.join(" · ");
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Compile the board's part of the one-take prompt and join it to the
|
|
130
|
+
* creator's prompt. Empty blocks drop.
|
|
131
|
+
*/
|
|
132
|
+
export function compileOneTake(board) {
|
|
133
|
+
const steps = oneTakeSteps(board.shots, board.oneTake?.duration_seconds);
|
|
134
|
+
const shotTotal = shotSteps(board.shots).at(-1)?.end_seconds ?? 0;
|
|
135
|
+
const references = oneTakeReferences(board);
|
|
136
|
+
const refs = compileRefs(references);
|
|
137
|
+
const audio = compileAudio(board.shots, steps);
|
|
138
|
+
const compiled = [
|
|
139
|
+
refs ? `REFS: ${refs}` : "",
|
|
140
|
+
compileSteps(board.shots, steps),
|
|
141
|
+
audio ? `AUDIO: ${audio}` : ""
|
|
142
|
+
]
|
|
143
|
+
.filter((block) => block.length > 0)
|
|
144
|
+
.join("\n\n");
|
|
145
|
+
const own = board.oneTake?.prompt.trim() ?? "";
|
|
146
|
+
return {
|
|
147
|
+
compiled,
|
|
148
|
+
prompt: [own, compiled].filter((part) => part.length > 0).join("\n\n"),
|
|
149
|
+
references,
|
|
150
|
+
steps,
|
|
151
|
+
duration_seconds: steps.at(-1)?.end_seconds ?? 0,
|
|
152
|
+
shot_total_seconds: shotTotal
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
// ── Scene clips ─────────────────────────────────────────────────────────────
|
|
156
|
+
/** The fewest shots one scene clip covers. One shot renders its own clip. */
|
|
157
|
+
export const SCENE_CLIP_MIN_SHOTS = 2;
|
|
158
|
+
/** The most shots one scene clip covers. */
|
|
159
|
+
export const SCENE_CLIP_MAX_SHOTS = 5;
|
|
160
|
+
/**
|
|
161
|
+
* Resolve a scene clip's shots on the board. The run must name between
|
|
162
|
+
* {@link SCENE_CLIP_MIN_SHOTS} and {@link SCENE_CLIP_MAX_SHOTS} existing
|
|
163
|
+
* shots that sit next to each other in board order and share one scene.
|
|
164
|
+
* A deleted or moved shot breaks the run rather than silently changing what
|
|
165
|
+
* the clip covers.
|
|
166
|
+
*/
|
|
167
|
+
export function sceneClipRun(shots, shotIds) {
|
|
168
|
+
const ordered = byIndex(shots);
|
|
169
|
+
const positions = shotIds.map((id) => ordered.findIndex((shot) => shot.id === id));
|
|
170
|
+
const found = positions
|
|
171
|
+
.filter((position) => position >= 0)
|
|
172
|
+
.sort((a, b) => a - b);
|
|
173
|
+
const run = found.map((position) => ordered[position]);
|
|
174
|
+
if (found.length < shotIds.length) {
|
|
175
|
+
return { shots: run, issue: "A shot in this scene clip was deleted." };
|
|
176
|
+
}
|
|
177
|
+
if (run.length < SCENE_CLIP_MIN_SHOTS || run.length > SCENE_CLIP_MAX_SHOTS) {
|
|
178
|
+
return {
|
|
179
|
+
shots: run,
|
|
180
|
+
issue: `A scene clip covers ${SCENE_CLIP_MIN_SHOTS} to ${SCENE_CLIP_MAX_SHOTS} shots.`
|
|
181
|
+
};
|
|
182
|
+
}
|
|
183
|
+
if (found.some((position, i) => i > 0 && position !== found[i - 1] + 1)) {
|
|
184
|
+
return {
|
|
185
|
+
shots: run,
|
|
186
|
+
issue: "The shots in this scene clip are no longer next to each other."
|
|
187
|
+
};
|
|
188
|
+
}
|
|
189
|
+
if (run.some((shot) => (shot.scene_id ?? null) !== (run[0].scene_id ?? null))) {
|
|
190
|
+
return {
|
|
191
|
+
shots: run,
|
|
192
|
+
issue: "The shots in this scene clip are no longer in one scene."
|
|
193
|
+
};
|
|
194
|
+
}
|
|
195
|
+
return { shots: run, issue: null };
|
|
196
|
+
}
|
|
197
|
+
/**
|
|
198
|
+
* Compile a scene clip: {@link compileOneTake} over the run's shots alone, so
|
|
199
|
+
* `[Image N]` numbers and the step windows start at the run's first shot.
|
|
200
|
+
*/
|
|
201
|
+
export function compileSceneClip(shots, clip) {
|
|
202
|
+
return compileOneTake({
|
|
203
|
+
shots: sceneClipRun(shots, clip.shot_ids).shots,
|
|
204
|
+
oneTake: clip
|
|
205
|
+
});
|
|
206
|
+
}
|
|
207
|
+
//# sourceMappingURL=one-take.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"one-take.js","sourceRoot":"","sources":["../src/one-take.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AA+DH,qDAAqD;AACrD,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,CAAC;AAE/C,mDAAmD;AACnD,MAAM,KAAK,GAAG,CAAC,KAAa,EAAU,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,GAAG,EAAE,CAAC,GAAG,EAAE,CAAC;AAErE,oCAAoC;AACpC,MAAM,OAAO,GAAG,CAAC,KAAa,EAAU,EAAE,CACxC,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,GAAG,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC;AAEhF,qDAAqD;AACrD,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,KAAa,EAAE,GAAW,EAAU,EAAE,CAClE,GAAG,OAAO,CAAC,KAAK,CAAC,IAAI,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC;AAEvC,MAAM,OAAO,GAAG,CAAC,KAAsB,EAAU,EAAE,CACjD,CAAC,GAAG,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC;AAE/C;;;GAGG;AACH,MAAM,UAAU,YA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