@cueframe/kernel 0.2.36 → 0.2.37
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/_members/plane/contract.d.ts +29 -20
- package/dist/plane/contract.js +2 -2
- package/package.json +10 -10
|
@@ -2,32 +2,41 @@ import { z } from "zod";
|
|
|
2
2
|
/**
|
|
3
3
|
* Still-capture budget. ONE definition, because the batch a caller may ask for
|
|
4
4
|
* and the time the renderer is given to serve it are the same number seen from
|
|
5
|
-
* two ends
|
|
6
|
-
* provably could not finish.
|
|
5
|
+
* two ends.
|
|
7
6
|
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
* and failed with an untyped `render_still_failed`.
|
|
7
|
+
* THE BUDGET IS A TIMEOUT, NOT A RESERVATION. Work that finishes early costs
|
|
8
|
+
* nothing extra; a generous budget only delays the error on work that is
|
|
9
|
+
* genuinely stuck. Setting it tight buys nothing and fails real renders, which
|
|
10
|
+
* is exactly what happened.
|
|
13
11
|
*
|
|
14
|
-
*
|
|
15
|
-
* `@modal.batched`, so up to CO_BATCHED_CALLERS callers share ONE harness run
|
|
16
|
-
* and one ceiling. The largest per-caller batch that survives the worst case is
|
|
17
|
-
* therefore the largest N where
|
|
12
|
+
* History, because both mistakes are instructive (CUE-39):
|
|
18
13
|
*
|
|
19
|
-
*
|
|
14
|
+
* 1. The Modal worker computed `min(280, 60 + 45 * beats)`. The per-beat term is
|
|
15
|
+
* dead above four beats — the cap TRUNCATES a budget the caller can never
|
|
16
|
+
* meet instead of refusing the batch — and `timestamps` had no maximum, so a
|
|
17
|
+
* 124-beat request was accepted and failed five minutes later.
|
|
18
|
+
* 2. The first fix derived MAX from the worker's 300s function timeout as though
|
|
19
|
+
* that were physics. It is a decorator value we choose. Worse, it was derived
|
|
20
|
+
* so the worst case EXACTLY fit (276 <= 280), leaving zero headroom: seven
|
|
21
|
+
* in-bound batches on a 31-clip composition with alpha layers then failed,
|
|
22
|
+
* because that composition costs ~4s per still and the constant said 3s.
|
|
20
23
|
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
24
|
+
* So PER_BEAT is now the HEAVY end with real headroom, not the median. A light
|
|
25
|
+
* composition finishing in a third of its budget is free; a heavy one exceeding
|
|
26
|
+
* a tight budget is an outage. MEASURED on prod 2026-09-17: 52 stills of a
|
|
27
|
+
* 5-track / 31-clip / 60s composition with alpha layers completed inside 216s
|
|
28
|
+
* (<=4.15s each), while 72 stills exceeded 276s.
|
|
29
|
+
*
|
|
30
|
+
* MAX_STILL_BEATS_PER_BATCH is a product choice, not a derivation: it admits the
|
|
31
|
+
* verify lane's worst case (6 eval beats x 3 burst frames). The invariant a test
|
|
32
|
+
* pins is that the worst case COMFORTABLY fits, and that the ceiling stays under
|
|
33
|
+
* the worker's own function timeout.
|
|
26
34
|
*/
|
|
27
35
|
export declare const STILL_BUDGET_BASE_S = 60;
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
36
|
+
/** Heavy-composition cost with headroom; measured ~4s/still, budgeted at 10. */
|
|
37
|
+
export declare const STILL_BUDGET_PER_BEAT_S = 10;
|
|
38
|
+
/** Under `render_still_worker`'s `timeout=` decorator, which is ours to set. */
|
|
39
|
+
export declare const STILL_BUDGET_CEILING_S = 840;
|
|
31
40
|
/** `STILL_BATCH_MAX` on the still worker: callers sharing one harness run. */
|
|
32
41
|
export declare const CO_BATCHED_CALLERS = 4;
|
|
33
42
|
export declare const MAX_STILL_BEATS_PER_BATCH = 18;
|
package/dist/plane/contract.js
CHANGED
|
@@ -3,8 +3,8 @@ import "../chunk-2ESYSVXG.js";
|
|
|
3
3
|
// ../plane/src/contract.ts
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
var STILL_BUDGET_BASE_S = 60;
|
|
6
|
-
var STILL_BUDGET_PER_BEAT_S =
|
|
7
|
-
var STILL_BUDGET_CEILING_S =
|
|
6
|
+
var STILL_BUDGET_PER_BEAT_S = 10;
|
|
7
|
+
var STILL_BUDGET_CEILING_S = 840;
|
|
8
8
|
var CO_BATCHED_CALLERS = 4;
|
|
9
9
|
var MAX_STILL_BEATS_PER_BATCH = 18;
|
|
10
10
|
function stillBudgetSeconds(beats) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cueframe/kernel",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.37",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Publish-only aggregate of CueFrame's isomorphic kernel packages — composition, primitives, authoring, MCP, and friends shipped as one npm artifact. Members remain separate workspace packages; this only changes what ships.",
|
|
6
6
|
"files": [
|
|
@@ -17,25 +17,25 @@
|
|
|
17
17
|
"tsup": "^8.3.5",
|
|
18
18
|
"typescript": "^5.9.3",
|
|
19
19
|
"@cueframe/account-model": "0.1.0",
|
|
20
|
-
"@cueframe/animate": "0.1.0",
|
|
21
20
|
"@cueframe/authoring": "0.1.0",
|
|
22
|
-
"@cueframe/cloud-import": "0.1.0",
|
|
23
21
|
"@cueframe/compose": "0.1.0",
|
|
24
22
|
"@cueframe/composition-ops": "0.1.0",
|
|
25
|
-
"@cueframe/
|
|
23
|
+
"@cueframe/animate": "0.1.0",
|
|
26
24
|
"@cueframe/brand-derivation": "0.1.0",
|
|
25
|
+
"@cueframe/composition": "0.1.0",
|
|
26
|
+
"@cueframe/cloud-import": "0.1.0",
|
|
27
27
|
"@cueframe/core": "0.1.0",
|
|
28
|
-
"@cueframe/errors": "0.1.0",
|
|
29
|
-
"@cueframe/director": "0.1.0",
|
|
30
|
-
"@cueframe/foundation": "0.1.0",
|
|
31
28
|
"@cueframe/component-runtime": "0.1.0",
|
|
29
|
+
"@cueframe/foundation": "0.1.0",
|
|
30
|
+
"@cueframe/director": "0.1.0",
|
|
32
31
|
"@cueframe/mcp": "0.1.0",
|
|
33
|
-
"@cueframe/primitives": "0.1.0",
|
|
34
|
-
"@cueframe/perception": "0.1.0",
|
|
35
32
|
"@cueframe/nle-export": "0.1.0",
|
|
33
|
+
"@cueframe/perception": "0.1.0",
|
|
36
34
|
"@cueframe/plane": "0.1.0",
|
|
35
|
+
"@cueframe/primitives": "0.1.0",
|
|
36
|
+
"@cueframe/media-model": "0.1.0",
|
|
37
37
|
"@cueframe/render-harness": "0.1.0",
|
|
38
|
-
"@cueframe/
|
|
38
|
+
"@cueframe/errors": "0.1.0"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|
|
41
41
|
"gsap": "3.13.0",
|