@kheleshikhi/studio-agent 0.6.1 → 0.9.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/README.md CHANGED
@@ -13,10 +13,140 @@ nerdbro connect
13
13
  mkdir my-kheleshikhi-work
14
14
  cd my-kheleshikhi-work
15
15
  nerdbro agent init --provider codex # or claude / generic
16
- nerdbro studio create --title "Ball Lab" --target combined --concept "Projectile range"
16
+ nerdbro studio create --title "Ball Lab" --concept "Projectile range" \
17
+ --graph-purpose "Range against launch angle" # target defaults to sceneComposition
17
18
  nerdbro studio checkout <asset-id>
18
19
  ```
19
20
 
21
+ ## Mental model: Scene + Experience
22
+
23
+ Since 0.8.0 the CLI follows ADR-0003, the unified model the server projects:
24
+
25
+ - **Everything visual is a Scene** (`sceneComposition`). A graph is not a
26
+ separate asset or target: it is a **Scene math plane** (`mathPlanes`, Scene
27
+ Source v15, manifest v19) inside the Scene. A graph-only lesson is a Scene
28
+ holding one plane; a physical + graph lesson is one Scene holding both.
29
+ - **Interaction is an Experience** (`kheleshikhi.experience.v3`): final learner
30
+ content containing one or more Scenes, with `interaction` (inputs, requests,
31
+ handlers, readouts, exports, tools), `rounds`, `presentation` and
32
+ `assessment.outcomes`. `game` carries scoring only (sections and metrics).
33
+ `requiredCapabilities` are derived by the server, never authored; every
34
+ canonical capability is available in every host.
35
+ - **Frozen:** the `interactiveScene` part shape and the `mathGraph` and
36
+ `combined` targets are read so existing assets keep playing, but are never
37
+ authored for new work. Experience V2 is read through one normalizer and never
38
+ authored again.
39
+
40
+ The CLI does not bundle these lists. `nerdbro context` returns the live
41
+ projection — `authoring_targets`, `frozen_authoring_targets`, `deprecations`,
42
+ `scene_schema`, `scene_manifest_schema`, `experience_schema`,
43
+ `experience_capabilities`, `experience_tools` — plus a `summary` with the
44
+ compatibility verdict. `studio create` defaults `--target` to `sceneComposition`
45
+ and refuses a target only when the server's context lists it as frozen
46
+ (`STUDIO_TARGET_FROZEN`, exit `2`, with the server's deprecation text); any
47
+ other target is sent to the server, which remains the authority. Graph intent
48
+ (`--math-plane`, or `--graph-purpose`/`--graph-x`/`--graph-y`/`--graph-sync`)
49
+ sets the brief's `requires_graph`, meaning "this Scene holds a math plane",
50
+ whatever the target.
51
+
52
+ `nerdbro schema experience` returns the live V3 contract with the universal
53
+ capability list attached (`universal_capabilities`), and
54
+ `nerdbro capabilities` returns that list and the canonical tools beside the
55
+ Studio capability registry. A schema topic the server marks deprecated (for
56
+ example `mathGraph.config`) carries `deprecated` in its result.
57
+
58
+ A Scene holding a math plane (validated and compiled by the server's Scene
59
+ parser; the plane fields are documented by `nerdbro docs open mathgraph`, and
60
+ `nerdbro schema scene.versions` names the current authoring schema):
61
+
62
+ ```json
63
+ {
64
+ "schema": "kheleshikhi.scene-source.v15",
65
+ "id": "parabola-lab",
66
+ "titleEn": "Parabola",
67
+ "titleBn": "পরাবৃত্ত",
68
+ "instructionEn": "Change k and watch the curve.",
69
+ "instructionBn": "k বদলাও, বক্ররেখা দেখো।",
70
+ "canvas": { "width": 960, "height": 540 },
71
+ "variables": [{ "name": "k", "type": "number", "value": 1, "min": -3, "max": 3 }],
72
+ "bands": [{ "id": "graphs", "kind": "mathPath", "placement": "compiled" }],
73
+ "instances": [],
74
+ "bindings": [],
75
+ "mathPlanes": [
76
+ {
77
+ "id": "graph",
78
+ "band": "graphs",
79
+ "title": "y equals k x squared",
80
+ "rect": { "x": 280, "y": 120, "width": 400, "height": 300 },
81
+ "viewport": { "minX": -5, "maxX": 5, "minY": -4, "maxY": 4 },
82
+ "axes": { "xLabel": "x", "yLabel": "y" },
83
+ "series": [{ "id": "curve", "kind": "explicit", "formula": "k*x^2", "label": "y = kx²" }]
84
+ }
85
+ ]
86
+ }
87
+ ```
88
+
89
+ An Experience V3 using that kind of Scene, with inputs, requests, readouts,
90
+ exports, a tool, a round, presentation and assessment outcomes (validated by
91
+ the server's Experience parser; read `nerdbro schema experience` for the live
92
+ field lists and `nerdbro capabilities` for tool types):
93
+
94
+ ```json
95
+ {
96
+ "schema": "kheleshikhi.experience.v3",
97
+ "id": "ramp",
98
+ "kind": "lesson",
99
+ "title": "Ramp",
100
+ "language": "bn",
101
+ "scenes": { "main": { "asset": "<approved Scene asset id>" } },
102
+ "variables": { "placed": false },
103
+ "interaction": {
104
+ "inputs": [
105
+ { "type": "directional2d", "axes": ["moveX"] },
106
+ { "type": "action", "action": "primary", "labelEn": "Go", "labelBn": "চলো" }
107
+ ],
108
+ "requests": {
109
+ "speed": { "type": "number", "presentation": "dial", "min": 0, "max": 10, "step": 1 },
110
+ "hint": { "type": "hint", "textEn": "Look at the slope." }
111
+ },
112
+ "handlers": [
113
+ { "topic": "input.action.primary.pressed", "kind": "event", "sceneEvent": "begin" }
114
+ ],
115
+ "readouts": [
116
+ {
117
+ "topic": "ramp.speed",
118
+ "kind": "state",
119
+ "from": { "scene": "main", "variable": "speed" },
120
+ "display": { "labelEn": "Speed", "labelBn": "বেগ", "unit": "m/s" }
121
+ }
122
+ ],
123
+ "exports": [{ "topic": "session.complete", "kind": "event", "on": "allPlaced" }],
124
+ "tools": [{ "id": "replay", "type": "replay-scrubber", "config": {} }]
125
+ },
126
+ "rounds": {
127
+ "count": 1,
128
+ "pool": [{ "id": "one", "promptEn": "Place it", "promptBn": "রাখো", "value": 1 }]
129
+ },
130
+ "presentation": { "orientation": "landscape", "aspectRatio": "16:9", "controlsLayout": "standard" },
131
+ "assessment": {
132
+ "outcomes": [
133
+ { "id": "placed", "on": "targetMatched", "status": "correct", "evidence": "placed" },
134
+ { "id": "missed", "on": "targetMissed", "status": "incorrect", "retry": true },
135
+ { "id": "done", "on": "allPlaced", "status": "completed" }
136
+ ]
137
+ }
138
+ }
139
+ ```
140
+
141
+ ### Version negotiation
142
+
143
+ Every command first reads `/v1/agent/context`. A different `agent_protocol`
144
+ or a CLI older than `minimum_cli_version` exits `5`
145
+ (`AGENT_PROTOCOL_INCOMPATIBLE`, `AGENT_CLI_UPGRADE_REQUIRED`) with the exact
146
+ `npm install -g @kheleshikhi/studio-agent@<version>` to run. A CLI older than
147
+ `recommended_cli_version` keeps working and prints one upgrade notice on
148
+ stderr. The server currently recommends 0.8.0.
149
+
20
150
  The browser pairing page uses the normal NerdBro login. The daemon stores the
21
151
  scoped production credential only in memory. It binds to `127.0.0.1` on a
22
152
  random port and protects local RPC with a random discovery secret. The
@@ -30,7 +160,7 @@ are CSS layout sizes; they do not simulate a low-density display. Headless mode
30
160
  uses the same explicit responsive viewports for automated inspection, but its
31
161
  screenshot pixels are not promised to be byte-identical across hardware.
32
162
  Chrome's device-metrics API applies the CSS size while leaving the host device
33
- scale native; NerdBro does not force a DPR value. Version 0.6.1 keeps the
163
+ scale native; NerdBro does not force a DPR value. Since 0.6.2 the CLI keeps the
34
164
  Chrome DevTools viewport session alive for the browser tab, so a requested
35
165
  desktop, mobile, or custom CSS size remains in effect through inspection and
36
166
  capture.
@@ -81,15 +211,98 @@ Use `nerdbro schema experience` for the final learner content contract and
81
211
  `nerdbro docs open experiences` for one-Scene, narrated, mixed, and multi-Band
82
212
  examples. Use `nerdbro schema scene.variables`, `scene.events`, `scene.gestures`, `scene.diagram`,
83
213
  `scene.motions`, `scene.captions`, `scene.audio`, `scene.stateMachines`,
84
- `expressions`, `stateMachine.actions`, `mathGraph.behaviorProjection`,
85
- `assessment`, or the `runtime.*` topics to request a narrow projection of
86
- the parser/runtime contract. `nerdbro schema` returns the topic index and
87
- summary contracts.
214
+ `scene.versions`, `scene.limits`, `expressions`, `stateMachine.actions`,
215
+ `assessment`, or the other listed topics to request a narrow projection of
216
+ the parser/runtime contract. `nerdbro schema` returns the live topic index and
217
+ summary contracts. The `mathGraph.*` and `runtime.*` topics describe frozen
218
+ shapes kept for existing assets; new graphs are Scene math planes.
88
219
  Search Components and Behaviors narrowly. Example search rejects an empty
89
220
  query, returns ranked summaries with a small default limit, and leaves full
90
221
  source to `example inspect <id>`; normally inspect no more than three relevant
91
222
  examples.
92
223
 
224
+ ### Authoring projects (library scope)
225
+
226
+ A Maker's authoring project fixes which asset libraries the work may draw
227
+ from. Start the Attempt in one and every later command in that workspace is
228
+ scoped by the server:
229
+
230
+ ```sh
231
+ nerdbro project list # your projects
232
+ nerdbro project libraries # every library; home/permitted marked for the active project
233
+ nerdbro project create --title "Siege of the fort" --output-target video \
234
+ --home-library history-youtube [--purpose <text>] [--permitted shared-general,...]
235
+ nerdbro attempt start --label siege --project <project-id>
236
+ nerdbro project current | project show [<project-id>]
237
+ nerdbro component search cannon # compact, in-scope page; outside-scope ids on stderr
238
+ nerdbro component search cannon --all-libraries [--limit n] [--offset n]
239
+ nerdbro component search cannon --full # the old full-contract list
240
+ nerdbro component inspect physics.cannon.v1 # libraries, inScope, scopeBasis; never filtered
241
+ nerdbro project import physics.cannon.v1 --reason "siege cannon" [--kind component|behavior|audio|experience]
242
+ nerdbro studio validate <asset-id> # scope_warnings: LIBRARY_SCOPE_NOT_PERMITTED
243
+ ```
244
+
245
+ The project's public id is kept in `.nerdbro-attempt.json`; `project show`
246
+ and `project import` default to it (pass `--project` or an id to choose
247
+ another). In a project Attempt, `component|behavior search` returns
248
+ `view: "compact"`, `scope`, and `outside_scope` `{count, examples, hint}`; the
249
+ human output prints the scope and hint on stderr (stdout stays JSON).
250
+ `--compact` asks for the compact view without a project; `--full` and
251
+ `--compact` are exclusive. Studio assets created in a project Attempt join
252
+ the project. `studio validate|compile|preview` copy any
253
+ `LIBRARY_SCOPE_NOT_PERMITTED` diagnostics to `scope_warnings`; approval in the
254
+ Studio refuses an unimported out-of-scope dependency. Without `--project`
255
+ nothing changes. Routes and scopes: `GET /v1/agent/libraries`
256
+ (`CATALOGUE_READ`), `GET /v1/agent/projects[/{id}]` (`STUDIO_READ`),
257
+ `POST /v1/agent/projects` (`STUDIO_ASSET_CREATE`),
258
+ `POST /v1/agent/projects/{id}/imports` (`STUDIO_DRAFT_WRITE`); no library or
259
+ membership writes.
260
+
261
+ `nerdbro experience inspect-browser <id>` opens the canonical Experience
262
+ workspace. `nerdbro experience drive <id> --scenario scenario.json` runs a
263
+ bounded scenario against the mounted Experience Preview of **your local
264
+ `source.json`, saved or not** (0.7.0+): the exact candidate is mounted in the
265
+ daemon's own browser through the non-persisting Draft Preview and bound by its
266
+ canonical hash (`source_origin: "local"`, `source_hash`); nothing is stored.
267
+ `--saved` drives the saved revision instead. It accepts master
268
+ events (`fire`), Scene semantic events (`fireSceneEvent`), learner presses of
269
+ the active Scene's available events (`press`), Timeline play/pause/seek, Cue
270
+ dispatch, `previewState` (a bare master State id with master-variable
271
+ `setup`, or `machine/state` in the active Scene with `setup` naming variables
272
+ that Scene declares — type and min/max checked, reported as
273
+ `probe.sceneSetup`), `select` (`state:repair`), restart,
274
+ waits, assertions, and captures. It never saves or publishes the source.
275
+ Observation paths read the shared `kheleshikhi.studio-observation.v2`
276
+ domains the Maker's Observatory shows — `experience.activeState`,
277
+ `experience.masterVariables.<name>`, `scene.activeStates.<machine>`,
278
+ `timeline.ms`, `probe.active`, `probe.setup.<name>`, `selection.sourcePath` —
279
+ and the older flat keys (`active_state`, `master_variables`, `timeline_ms`,
280
+ `scene_active_states`, `preview_override`, …) still work.
281
+
282
+ ### Source is the authority; probes are not journeys
283
+
284
+ You author the same canonical Source as the Maker. Every drive returns
285
+ `evidence_mode`: `probe` when it jumped to a State, used synthetic `setup`,
286
+ fired an event a learner could not press, or seeked — useful development
287
+ evidence that never proves a learner path or certifies anything — and
288
+ `journey` when it ran from the initial State with learner-reachable actions
289
+ only. Certification refuses a probed runtime observation.
290
+
291
+ ### Agent Presence
292
+
293
+ The Maker's open Studio shows what you are doing, through
294
+ `PUT /v1/agent/presence` (scope `STUDIO_OBSERVE`): status, changed source
295
+ paths, the last semantic command and result, where your runtime is, your
296
+ selection, your last capture. The CLI reports it around each
297
+ validate/compile/preview/save/certify/capture/drive and per drive step.
298
+ `nerdbro studio watch <asset> [--once]` and `nerdbro experience watch <id>
299
+ [--once]` report which JSON Pointers your local `source.json` changed
300
+ against the saved head, debounced; they never send the source. Presence is
301
+ overwritten in place, expires after 90 seconds, is cleared on disconnect, and
302
+ carries no reasoning, credentials or local paths. A Maker may **Follow
303
+ Agent**: their Studio mirrors your selection, source path and runtime
304
+ position, but you never control their browser or runtime.
305
+
93
306
  The daemon reuses the authenticated context response for at most 30 seconds,
94
307
  then revalidates it; connecting or disconnecting clears the cache. This cuts
95
308
  repeated compatibility reads without caching mutable drafts.
@@ -97,9 +310,9 @@ repeated compatibility reads without caching mutable drafts.
97
310
  Check out once, edit only `source.json`, and use `studio status` for later
98
311
  synchronization. Validate, compile, preview when useful, save, then inspect the
99
312
  real Studio. The daemon reuses its short-lived read-only browser credential in
100
- memory and clears it on disconnect, stop, reconnect, or origin change. A graph
101
- requirement without a teaching purpose or axis/synchronization meaning is a
102
- clarification request, not permission to invent filler.
313
+ memory and clears it on disconnect, stop, reconnect, or origin change. A math
314
+ plane requirement without a teaching purpose or axis/synchronization meaning is
315
+ a clarification request, not permission to invent filler.
103
316
 
104
317
  `studio create` needs the `STUDIO_ASSET_CREATE` pairing scope and returns a
105
318
  Maker-owned draft identity and its server starter-source hash. `--scratch`
@@ -107,7 +320,8 @@ only labels the intent to use an ordinary new, unapproved asset as a disposable
107
320
  spike. It has no separate lifecycle, automatic expiry, promotion, or garbage
108
321
  collection. Save its exact ID for explicit cleanup after success. Use
109
322
  `studio brief <asset>` and `studio brief update <asset> --graph-purpose ...`
110
- to inspect or update authoring intent with a concurrency check.
323
+ (or `--math-plane` / `--no-math-plane`) to inspect or update authoring intent
324
+ with a concurrency check.
111
325
 
112
326
  `studio save` creates a draft. `studio certify` records technical evidence.
113
327
  Neither approves or publishes. `studio export --revision ...` accepts only the
@@ -147,8 +361,28 @@ and has at most 64 steps and a two-minute run budget:
147
361
  }
148
362
  ```
149
363
 
150
- `set`, `fire`, `press`, `tap`, `drag`, `play`, `pause`, `seek`, and `reset`
151
- address only declared variables, events, instances, and gestures. `press`
364
+ To start mid-flow without replaying the Scene, jump to a State of one
365
+ machine — always `machine/state`, because two machines may share a State id —
366
+ optionally with synthetic setup for 1–16 declared variables:
367
+
368
+ ```json
369
+ {"version": 1, "steps": [
370
+ {"op": "previewState", "target": "launch/armed", "setup": {"force": 9, "armed": true}},
371
+ {"op": "assert", "path": "probe.active", "equals": true},
372
+ {"op": "select", "target": "instance:cart"},
373
+ {"op": "assert", "path": "selection.sourcePath", "equals": "/sources/mainScene/document/instances/0"},
374
+ {"op": "press", "target": "disarmPressed"},
375
+ {"op": "wait", "path": "scene.activeStates.launch", "equals": "idle"},
376
+ {"op": "capture", "name": "after-disarm"},
377
+ {"op": "restart"}
378
+ ]}
379
+ ```
380
+
381
+ `set`, `fire`, `press`, `tap`, `drag`, `play`, `pause`, `seek`, `reset`,
382
+ `restart`, `previewState` and `select` address only declared variables,
383
+ events, instances, gestures, machines and States. A `set` on a variable the
384
+ learner has no visible control for is synthetic setup and makes the run a
385
+ probe. `press`
152
386
  honours conditional availability; `drag` derives a Scene point from the
153
387
  authored gesture range. `wait` and `assert` read allowlisted observation paths,
154
388
  never arbitrary code. `capture` records the actual browser pixels. The result
@@ -157,6 +391,23 @@ For a gesture with an interaction handle, assert
157
391
  `gestures.<id>.affordance_visible` before `drag`; the driver also refuses a
158
392
  handle that the mounted preview has not presented.
159
393
 
394
+ ## Presentation video and episodes
395
+
396
+ `nerdbro studio render-video <asset> --recipe recipe.json` and `nerdbro
397
+ experience render-video <stable-id> --recipe recipe.json` render one
398
+ presentation MP4 (H.264/AAC, exact frame times, sounds mixed from canonical
399
+ bytes; needs local FFmpeg) as a daemon render job the CLI polls; Ctrl-C
400
+ cancels it. `render.json` records the source hash, the dependency record
401
+ digest (Scene) or per-Scene provenance (Experience), the recipe and every
402
+ frame's SHA-256, plus a per-phase capture timing breakdown.
403
+
404
+ `nerdbro episode validate|plan|render|status <episode.json>` assembles an
405
+ episode from such shots with a content-addressed shot cache, one ducked and
406
+ loudness-normalised mix, SRT subtitles and a QC report. `NERDBRO_RENDER_WORKERS`
407
+ (default 1, at most 4) sets how many render browsers the daemon may run, and
408
+ `--workers` how many shots render at once. See
409
+ [episode video production](../docs/guides/episode-video.md).
410
+
160
411
  ## Library authoring
161
412
 
162
413
  The Studio Library's semantic kinds — `experience`, `audio`, `component`
@@ -199,7 +450,12 @@ edits without `--force`. `status` reports `local_changed`, `remote_changed` and
199
450
  saving unchanged content creates no draft but still refreshes the lock, and a
200
451
  stale base exits `3` (`VOCABULARY_DRAFT_CONFLICT`) with `source.json` untouched.
201
452
  `validate` and `certify` default to the lock's head revision. `preview` sends
202
- the local, unsaved `source.json` and writes `preview.json` beside it.
453
+ the local, unsaved `source.json` and writes `preview.json` beside it; for an
454
+ Experience its summary reports the schema, Scene and audio counts, V3
455
+ interaction block counts, rounds, outcomes and the server-derived
456
+ `required_capabilities`. When a checked-out Experience is not the context's
457
+ `experience_schema` (for example a V2 document), `checkout`, `status` and
458
+ `preview` add a `schema_notice` with the server's deprecation text.
203
459
  `inspect-browser` captures the Studio Library workspace to `screenshot.png` and
204
460
  `browser.json` in the checkout directory; its bounded `browser.capture` activity
205
461
  record is reported locally in the command result only.
package/dist/attempt.d.ts CHANGED
@@ -7,6 +7,8 @@ export interface AttemptPointer {
7
7
  attempt_root: string;
8
8
  server_origin: string;
9
9
  started_at: string;
10
+ /** Authoring project public id when the Attempt was started in one; the server owns its scope. */
11
+ project?: string | null;
10
12
  }
11
13
  export declare function attemptHome(): string;
12
14
  export declare function attemptDirectory(attemptId: string): string;
@@ -15,6 +17,8 @@ export declare function readAttemptPointer(start?: string): Promise<{
15
17
  workspace: string;
16
18
  } | null>;
17
19
  export declare function createAttemptPointer(server: Record<string, unknown>, serverOrigin: string, workspace?: string): Promise<AttemptPointer>;
20
+ /** The project public id the server scoped this Attempt to, if any. */
21
+ export declare function attemptProject(server: Record<string, unknown>): string | null;
18
22
  export declare function saveCommandEvidence(pointer: AttemptPointer, commandId: string, command: string, result: unknown): Promise<void>;
19
23
  export declare function finalizeClient(pointer: AttemptPointer, workspace: string, server: Record<string, unknown>): Promise<{
20
24
  path: string;
package/dist/attempt.js CHANGED
@@ -54,12 +54,22 @@ export async function createAttemptPointer(server, serverOrigin, workspace = pro
54
54
  label: String(server.label), mode: String(server.mode),
55
55
  attempt_root: root, server_origin: serverOrigin,
56
56
  started_at: String(server.started_at),
57
+ // Only a project Attempt records one, so unscoped pointers stay as before.
58
+ ...(attemptProject(server) ? { project: attemptProject(server) } : {}),
57
59
  };
58
60
  await writeFile(path.join(workspace, POINTER_NAME), `${JSON.stringify(pointer, null, 2)}\n`, { flag: "wx", mode: 0o600 });
59
- await writeFile(path.join(root, "README.md"), `# NerdBro Attempt ${attemptId}\n\nLabel: ${pointer.label}\nMode: ${pointer.mode}\n\nRun \`nerdbro attempt finish --outcome completed|blocked|incomplete|abandoned\` in the original workspace with the accurate outcome, then run \`just studio-agent-attempt-export ${attemptId}\` from the NerdBro repository.\n`);
61
+ await writeFile(path.join(root, "README.md"), `# NerdBro Attempt ${attemptId}\n\nLabel: ${pointer.label}\nMode: ${pointer.mode}\n${pointer.project ? `Project: ${pointer.project}\n` : ""}\nRun \`nerdbro attempt finish --outcome completed|blocked|incomplete|abandoned\` in the original workspace with the accurate outcome, then run \`just studio-agent-attempt-export ${attemptId}\` from the NerdBro repository.\n`);
60
62
  await writeFile(path.join(root, "RUN_MANIFEST.json"), `${JSON.stringify({ schema: "kheleshikhi.studio-agent-attempt-run.v1", ...server }, null, 2)}\n`);
61
63
  return pointer;
62
64
  }
65
+ /** The project public id the server scoped this Attempt to, if any. */
66
+ export function attemptProject(server) {
67
+ const scope = server.project_scope;
68
+ if (!scope || typeof scope !== "object")
69
+ return null;
70
+ const project = scope.project;
71
+ return typeof project === "string" && project ? project : null;
72
+ }
63
73
  export async function saveCommandEvidence(pointer, commandId, command, result) {
64
74
  const root = attemptDirectory(pointer.attempt_id);
65
75
  const destination = path.join(root, "client", "evidence", command.startsWith("studio.drive") ? "drives" : command.startsWith("studio.inspect") ? "captures" : command.startsWith("studio.certify") ? "certification"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AE,CAAC,IAAI,CAAC,CAAC;IACxK,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,WAAW,CAAC,MAAM,EAAE,QAAQ,EAAE,IAAI,CAAC,QAAQ,EAAE,CAAC;AAClG,CAAC;AAED,KAAK,UAAU,uBAAuB,CAAC,SAAiB;IACtD,IAAI,CAAC;QAAC,MAAM,KAAK,CAAC,SAAS,CAAC,CAAC;IAAC,CAAC;IAAC,MAAM,CAAC;QAAC,OAAO,EAAE,CAAC;IAAC,CAAC;IACpD,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,SAAS,CAAC,CAAC;IACxC,OAAO,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,YAAY,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;AACzH,CAAC"}
package/dist/browser.d.ts CHANGED
@@ -1,6 +1,21 @@
1
+ import { type RenderRecipe } from "./video.js";
1
2
  import { type Page } from "playwright";
2
3
  import { AgentApi } from "./protocol.js";
3
- import { type DriveScenario } from "./scenario.js";
4
+ import { type RenderProgress } from "./render-jobs.js";
5
+ import { type DriveScenario, type ExperienceScenario } from "./scenario.js";
6
+ /** A render's cancellation signal and progress reports (a daemon render job). */
7
+ export type RenderControl = {
8
+ signal?: AbortSignal;
9
+ onProgress?: (value: RenderProgress) => void;
10
+ };
11
+ /** One semantic step as it happened, for Agent Presence and the activity feed. */
12
+ export type DriveStepReport = {
13
+ index: number;
14
+ summary: Record<string, unknown>;
15
+ observation?: Record<string, unknown>;
16
+ };
17
+ /** Called after each semantic step; failures inside it never fail the drive. */
18
+ export type DriveStepListener = (report: DriveStepReport) => void | Promise<void>;
4
19
  export declare function studioBrowserLaunchOptions(headless: boolean): {
5
20
  readonly headless: boolean;
6
21
  readonly viewport: null;
@@ -19,7 +34,7 @@ export declare function waitForCapturePaint(page: Page): Promise<void>;
19
34
  export declare function applyCssViewport(page: Page, dimensions: {
20
35
  width: number;
21
36
  height: number;
22
- }): Promise<void>;
37
+ }, deviceScaleFactor?: number): Promise<void>;
23
38
  export declare function renderingDiagnostics(page: Page, screenshot: Buffer): Promise<Record<string, unknown>>;
24
39
  export declare const VIEW_QUERY: Record<string, Record<string, string>>;
25
40
  export declare function viewRequiresRuntimeObservation(view: string): boolean;
@@ -58,6 +73,8 @@ export interface BrowserCaptureRequest {
58
73
  timeoutMs?: number;
59
74
  observation?: boolean;
60
75
  drive?: boolean;
76
+ /** An Experience drive that will mount an unsaved candidate itself. */
77
+ awaitsCandidate?: boolean;
61
78
  /** Library workspace route (`?workspace=<name>&selection=<stable id>`) instead of a Scene asset. */
62
79
  library?: {
63
80
  workspace: string;
@@ -65,6 +82,12 @@ export interface BrowserCaptureRequest {
65
82
  revision?: string;
66
83
  definitionHash?: string;
67
84
  };
85
+ /** Semantic step reports for presence; never part of the request sent to the page. */
86
+ onStep?: DriveStepListener;
87
+ /** The presentation render host (`studio_present=1`): the learner stage alone, filling the viewport. */
88
+ present?: boolean;
89
+ /** CSS-to-device pixel scale; 0 keeps the display's own. */
90
+ deviceScaleFactor?: number;
68
91
  }
69
92
  export interface PreviewObservationRequest extends BrowserCaptureRequest {
70
93
  mode?: string;
@@ -73,13 +96,15 @@ export interface PreviewObservationRequest extends BrowserCaptureRequest {
73
96
  }
74
97
  export declare class StudioBrowser {
75
98
  private api;
99
+ private readonly profileName;
76
100
  private context?;
77
101
  private page?;
78
102
  private headless;
79
103
  private browserEngine;
80
104
  private apiOrigin;
81
105
  private credentials;
82
- constructor(api: AgentApi);
106
+ /** `profileName` keeps a render worker's persistent profile apart from the main browser's. */
107
+ constructor(api: AgentApi, profileName?: string);
83
108
  start(headless: boolean): Promise<void>;
84
109
  stop(): Promise<void>;
85
110
  clearAuthentication(): void;
@@ -96,6 +121,67 @@ export declare class StudioBrowser {
96
121
  candidate: Record<string, unknown>;
97
122
  candidateHash: string;
98
123
  }): Promise<Record<string, unknown>>;
124
+ driveExperience(request: BrowserCaptureRequest & {
125
+ scenario: ExperienceScenario;
126
+ candidate?: unknown;
127
+ candidateHash?: string;
128
+ }): Promise<Record<string, unknown>>;
129
+ /**
130
+ * Presentation frames (STU-001) of a Scene, from the presentation host.
131
+ *
132
+ * Mounts and verifies the candidate exactly as `drive` does, but in the
133
+ * presentation host (`studio_present=1`) at a viewport of exactly the
134
+ * output size and device scale 1. `renderBegin` silences the Scene's
135
+ * sounds into a log and restarts it at 0 s; then for every frame video
136
+ * time is stepped to `start + k / fps`, the runtime confirms that instant
137
+ * and a paint, and the whole viewport is captured: one PNG of exactly the
138
+ * output size, proved before it is kept. Scheduled learner actions happen
139
+ * at their own seconds. Afterwards the audio log and each logged sound's
140
+ * canonical bytes are collected for the mixer.
141
+ */
142
+ renderFrames(request: BrowserCaptureRequest & {
143
+ candidate: Record<string, unknown>;
144
+ candidateHash: string;
145
+ recipe: RenderRecipe;
146
+ framesDirectory: string;
147
+ audioDirectory: string;
148
+ /** Optional: afterwards, play in real time and sample frame intervals. */
149
+ measurePlaybackSeconds?: number;
150
+ } & RenderControl): Promise<Record<string, unknown>>;
151
+ /**
152
+ * Presentation frames of an Experience: the canonical Experience player
153
+ * in the presentation host, driven by video time (`renderBegin`, then
154
+ * `step` per frame). The master timeline advances with video time only
155
+ * while it runs, so a learner pause or a wait for a choice stays paused,
156
+ * as it would in playback; Scenes change, cues fire and sounds start at
157
+ * the exact video second they would.
158
+ */
159
+ renderExperienceFrames(request: BrowserCaptureRequest & {
160
+ candidate?: unknown;
161
+ candidateHash?: string;
162
+ recipe: RenderRecipe;
163
+ framesDirectory: string;
164
+ audioDirectory: string;
165
+ } & RenderControl): Promise<Record<string, unknown>>;
166
+ private requirePage;
167
+ /** The page's runtime observation and its one-at-a-time drive channel. */
168
+ private renderChannel;
169
+ /**
170
+ * The newest observation once [ready] holds. The page publishes one every
171
+ * 150 ms and after every command; while not ready, each read also asks the
172
+ * host for a fresh one (the drive-command wake event, with no command
173
+ * waiting, only republishes), so a paint that lands between polls is seen
174
+ * within milliseconds.
175
+ */
176
+ private waitForRender;
177
+ /**
178
+ * The frame loop both subjects share: actions at their seconds, a step to
179
+ * each frame's exact second, the subject's own arrival check, a paint,
180
+ * and a whole-viewport PNG proved to be exactly the output size.
181
+ */
182
+ private captureFrames;
183
+ /** Every logged sound's canonical bytes, written once by key; checked against the logged SHA-256. */
184
+ private collectAudio;
99
185
  /** Local-agent capture from the same browser page and renderer the Maker sees. */
100
186
  capturePreview(request: PreviewObservationRequest): Promise<Record<string, unknown>>;
101
187
  }