wave3d-agent-sdk 0.2.9 → 0.2.10

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
@@ -21,19 +21,19 @@ Vocabulary:
21
21
  - Project: user workspace content. Reading a project is not opening/replacing live workspace.
22
22
 
23
23
  ```bash
24
- npx -y wave3d-agent-sdk@0.2.9 start
24
+ npx -y wave3d-agent-sdk@0.2.10 start
25
25
  ```
26
26
 
27
27
  After Copy to Agent, run the exact start command with MCP_TOKEN preserved as the local pairing secret. Keep it hidden:
28
28
 
29
29
  ```bash
30
- WAVE3D_MCP_TOKEN="$MCP_TOKEN" npx -y wave3d-agent-sdk@0.2.9 start
30
+ WAVE3D_MCP_TOKEN="$MCP_TOKEN" npx -y wave3d-agent-sdk@0.2.10 start
31
31
  ```
32
32
 
33
33
  Check SDK build before trusting a running SDK process:
34
34
 
35
35
  ```bash
36
- npx -y wave3d-agent-sdk@0.2.9 --version
36
+ npx -y wave3d-agent-sdk@0.2.10 --version
37
37
  ```
38
38
 
39
39
  The package bundles the WaveEngine SDK lookup corpus. No normal session needs a separate protected zip download.
@@ -43,7 +43,7 @@ The package bundles the WaveEngine SDK lookup corpus. No normal session needs a
43
43
  Wave Studio Copy to Agent defaults same-machine live MCP transport to this SDK:
44
44
 
45
45
  ```bash
46
- npx -y wave3d-agent-sdk@0.2.9 start
46
+ npx -y wave3d-agent-sdk@0.2.10 start
47
47
  ```
48
48
 
49
49
  Agents choose topology first:
@@ -58,13 +58,13 @@ Use `MCP_HTTP_GATEWAY_FALLBACK_URL` only for topology mismatch, remote/sandboxed
58
58
  For unfamiliar authoring, use the local SDK tools:
59
59
 
60
60
  ```bash
61
- npx -y wave3d-agent-sdk@0.2.9 cache search "continuous left rotation"
61
+ npx -y wave3d-agent-sdk@0.2.10 cache search "continuous left rotation"
62
62
  ```
63
63
 
64
64
  `cache refresh` without MCP arguments reinstalls the bundled SDK into `~/.wave3d/agent-cache`:
65
65
 
66
66
  ```bash
67
- npx -y wave3d-agent-sdk@0.2.9 cache refresh
67
+ npx -y wave3d-agent-sdk@0.2.10 cache refresh
68
68
  ```
69
69
 
70
70
  Old `cache refresh --mcp-url <url> --token <token>` arguments are ignored. Normal users update the npm package; no separate zip download exists.
package/dist/cli.js CHANGED
@@ -42488,8 +42488,8 @@ function normalizeWaveGenieAssetUploadRequest(request) {
42488
42488
 
42489
42489
  // ../../src/lib/waveStudio/aiAssist/bridge/localAgentSdkContract.ts
42490
42490
  var WAVE3D_AGENT_SDK_PACKAGE_NAME = "wave3d-agent-sdk";
42491
- var WAVE3D_AGENT_SDK_REQUIRED_VERSION = "0.2.9";
42492
- var WAVE3D_AGENT_SDK_REQUIRED_BUILD = "agent-sdk-20260620.4";
42491
+ var WAVE3D_AGENT_SDK_REQUIRED_VERSION = "0.2.10";
42492
+ var WAVE3D_AGENT_SDK_REQUIRED_BUILD = "agent-sdk-20260621.1";
42493
42493
  var WAVE3D_AGENT_SDK_PACKAGE_SPEC = `${WAVE3D_AGENT_SDK_PACKAGE_NAME}@${WAVE3D_AGENT_SDK_REQUIRED_VERSION}`;
42494
42494
  var WAVE3D_AGENT_SDK_START_COMMAND = `npx -y ${WAVE3D_AGENT_SDK_PACKAGE_SPEC} start`;
42495
42495
  var WAVE3D_AGENT_SDK_TOKEN_ENV_VAR = "WAVE3D_MCP_TOKEN";
@@ -44421,7 +44421,7 @@ var WAVE_MCP_AGENT_BRIEF = [
44421
44421
  "VFS hashes: simple edit tools auto-resolve the latest mirror `contentHash`; pass `baseHash` only when you already have it or when using advanced `apply_wave_patch`. Always inspect `changedFiles`, `changedPaths`, `partial`, and `skippedOperations` after edits.",
44422
44422
  "VFS modules: scene-root modules and their owned helpers run inside the Studio authoring context, but helpers should stay pure or parameterized. Put live object ownership in scene-root/feature files, not shared helpers.",
44423
44423
  'VFS HTML sketches: for diagram/chart/doc-sketch requests, create or edit an exact `.html` file with Studio VFS tools. Mermaid renders from `<div class="mermaid">flowchart TD ...</div>` when that HTML file is active in the editor/coding pane; HTML sketches must never replace the live engine preview iframe. Do not put Mermaid in markdown fences unless user specifically wants markdown text.',
44424
- 'VFS hot reload ownership: Studio hot reload targets the active/open edited file when safe. Editing `/main.ts` reloads the main graph; editing a scene-root module reloads that root; bootstrap/scene registry/assets/network/ambiguous helper surfaces escalate. In multi-file projects, standalone `hot_reload_wave_preview` follows the active Studio editor file, so do not expect it to reload an arbitrary unopened module by path. Put heavy world loading in bootstrap or a coarse world module. If authored UI in `main.ts` changes bootstrap/world-provider state, store the state and call `waveStudio.reloadPreview({ reason })`; do not call `myScene.hotReload(...)` from Studio-authored code because it bypasses Studio VFS/package/source-patch orchestration. For intentional cross-module live entities, the owner module calls `waveStudio.exportEntity("Name", entity)` and importer modules call `waveStudio.importEntity<T>("Name")`; Studio restores the exported baseline and replays active importer overlays during source hot reload. Source execution order is dependency-driven: exporter roots run before importer roots; an exporter root runs before `main.ts` when main imports it; importer overlays run after exporter/main baseline. Entity names must be static string literals, unique, and acyclic or run/hot reload stops before execution. Keep shared helpers pure or parameterized.',
44424
+ 'VFS hot reload ownership: Studio hot reload targets the active/open edited file when safe. Editing `/main.ts` reloads the main graph; editing a scene-root module reloads that root; bootstrap/scene registry/assets/network/ambiguous helper surfaces escalate. In multi-file projects, standalone `hot_reload_wave_preview` follows the active Studio editor file, so do not expect it to reload an arbitrary unopened module by path. Put heavy world loading in bootstrap or a coarse world module. Static VFS/package/asset-surface changes can be detected from file/package diffs and Studio may upgrade the tier automatically. Runtime-authored UI state changes cannot be inferred from files; if UI in `main.ts` changes bootstrap/world-provider/runtime-envelope state, store the state and call `waveStudio.reloadPreview({ reason, invalidates: ["world-provider"] })`. Valid invalidations are `bootstrap`, `world-provider`, and `runtime-envelope`. Do not call `myScene.hotReload(...)` from Studio-authored code because it bypasses Studio VFS/package/source-patch orchestration. For intentional cross-module live entities, the owner module calls `waveStudio.exportEntity("Name", entity)` and importer modules call `waveStudio.importEntity<T>("Name")`; Studio restores the exported baseline and replays active importer overlays during source hot reload. Source execution order is dependency-driven: exporter roots run before importer roots; an exporter root runs before `main.ts` when main imports it; importer overlays run after exporter/main baseline. Entity names must be static string literals, unique, and acyclic or run/hot reload stops before execution. Keep shared helpers pure or parameterized.',
44425
44425
  "Assets: when quoting or passing an existing asset, use typed bare refs in main files: `models.X`, `textures.X`, `materials.X`, `audios.X`, `hdr.X`, `cubeMaps.X`, `animations.X`, etc. Do not paste raw paths or edit Studio-managed generated files just to register assets. If the exact ref is not already visible, call category-first asset discovery (`find_wave_assets_by_category`, alias `list_wave_assets_by_category`, alias `search_wave_assets_by_category`, or tolerant `list_wave_assets`) with required `category` from user intent, semantic `query`, and small `limit` before editing code; category-filtered results can still be capped/truncated, so refine query before concluding absence. Use `list_wave_explorer_assets` only for uploaded library metadata, rename/delete, URL, path, size, or display/ref-name management.",
44426
44426
  "Asset authoring facade split: typed refs quote existing assets; `waveMaterial` authors material handles; `assetManager` is only for exact asset-pipeline/generated-asset APIs that a local SDK skill or API lookup names, such as SDF surfaces or surface ribbons. Do not treat `assetManager` as the default creative facade for materials or normal asset arguments.",
44427
44427
  "Material authoring: when creating, configuring, forking, or intentionally editing material handles, route to `wave.material.authoring` and start from `waveMaterial` (`createWater`, `createGrid`, `createSplatMaterial`, `createFromAsset`, `editAsset`). If a material handle later needs runtime sync, `assetManager` may be passed as the sync target; it is still not the authoring root.",
@@ -44446,7 +44446,7 @@ var WAVE_MCP_AUTHORING_GLOBALS_GUIDE = [
44446
44446
  "- Colors/materials/fx helpers: `COLOR`, `PALETTE`, `waveCOLOR`, `waveMaterial`, `shaderUniform`, `waveFx`, `waveFxPresets`, `FxAnchor`, `FxCondition`.",
44447
44447
  "- Controller movement helpers: `waveKinematicActor`, `netKinematicActor`, `KinematicHumanoidMovementState`, `KinematicVehicleMovementState`, and `KinematicFlightMovementState`. Use actor-level `.asHumanoid(...)`, `.asVehicle(...)`, or `.asFlight(...)` for player/controller movement.",
44448
44448
  "- Asset maps: use category-first refs returned by `find_wave_assets_by_category`, commonly `models`, `gaussianSplats`, `animations`, `materials`, `guis`, `textures`, `audios`, `instruments`, `videos`, `hdr`, `fonts`, `serializedData`, `terrains`, `fx`, and `particles`.",
44449
- "- Scene/runtime handles: prefer `myScene` for scene composition and `waveStudio` for Studio operations. If authored UI changes bootstrap/world-provider state and needs the Studio preview to rebuild, call `waveStudio.reloadPreview({ reason })`, not `myScene.hotReload(...)`. `assetManager` is available, but use it only when an exact skill/API names an asset-pipeline or generated-asset factory; do not use it as the default facade for existing asset refs or material authoring. Use lower-level `ctx`, `engine`, or `scene` only when existing code or an exact API requires them.",
44449
+ '- Scene/runtime handles: prefer `myScene` for scene composition and `waveStudio` for Studio operations. If authored UI changes bootstrap/world-provider/runtime-envelope state and needs the Studio preview package to rebuild, call `waveStudio.reloadPreview({ reason, invalidates: ["world-provider"] })`, not `myScene.hotReload(...)`. Valid invalidations are `bootstrap`, `world-provider`, and `runtime-envelope`; use the narrowest true reason. `assetManager` is available, but use it only when an exact skill/API names an asset-pipeline or generated-asset factory; do not use it as the default facade for existing asset refs or material authoring. Use lower-level `ctx`, `engine`, or `scene` only when existing code or an exact API requires them.',
44450
44450
  "- Authoring systems/presets: `waveEventBus`, `waveRig`, `waveValueCurve`, `waveValueCurvePresets`, `waveMotionSignal`, `waveParam`, `WaveParam`, `WaveChoice`, `prefabModels`, `effectPrefabs`, and prefab helpers such as `rocketPrefab`.",
44451
44451
  "- Lowercase constructors: `prop`, `marker`, `sphere`, `point`, `cube`, `box`, `cylinder`, `capsule`, `cone`, `torus`, `plane`, `ground`, `line`, `arc`, `path`, and related shape helpers.",
44452
44452
  "- Type names are not import paths. If the handbook shows a type like `TransformVerbMode` or `WaveRateUnit`, look for the matching bare runtime value such as `Animate` or `DegreesPerSecond` before writing code. Transform `Snapshot` calls return a snapshot builder; call `.take()` before passing the pose to `transitionTo(...)`.",
@@ -44483,11 +44483,11 @@ var WAVE_MCP_CODING_GUARDRAIL = [
44483
44483
  "6b. Asset facade split: passing an existing asset uses typed refs such as `models.X`, `textures.X`, `materials.X`, or `audios.X`; material authoring starts from `waveMaterial`; `assetManager` is reserved for exact low-level generated-asset/asset-pipeline APIs named by a local SDK skill or API lookup. Do not use `assetManager` as the default material, asset-ref, or path-surface authoring root.",
44484
44484
  '7. Use category-first asset discovery before referencing uploaded user assets, project aliases, or ambiguous built-in assets. Preferred tool: `find_wave_assets_by_category`; aliases: `list_wave_assets_by_category`, `search_wave_assets_by_category`, tolerant `list_wave_assets`. Choose category from user intent first, then query: `list_wave_assets_by_category({ category:"materials", query:"grass", limit:50 })`. For sound use `audios`, for 3D objects use `models`, for sky/HDR use `hdr`, for cube-map sky/environment use `cubeMaps`, for images use `textures`. Category-filtered responses can still be capped/truncated; absence there is not absence in the library. Only use asset refs returned by this tool. If the current code already contains the exact ref and the user asks for a small pattern-preserving edit, you may reuse that visible ref.',
44485
44485
  "7a. Use `list_wave_explorer_assets` when you need uploaded asset explorer metadata such as path, URL, size, or display/ref name for rename/delete/library work. It is not a fallback for built-in/public code refs and may be empty while `find_wave_assets_by_category` has many usable refs.",
44486
- "8. Wave Studio automations: `project.assetrefs.ts`, `project.scene.ts`, `project.scenes.ts`, and `project.execution.ts` are automatically managed by Wave Studio and are MCP read-only for agents. `bootstrap.ts` / scene `*/bootstrap.ts` is normally managed too. Edit bootstrap only when you can confidently pass `managedFileEditReason` as one of: `world_streaming_or_terrain_provider` (including Google Maps 3D tiles), `render_profile_or_runtime_backend`, `media_consent_or_capture_plan`, `external_ai_or_tts_backend`, `scene_envelope_or_template_baseline`, `baseline_setup_before_user_main`, or `stale_api_update_to_latest`. Never edit bootstrap for `asset_manifest_or_loader`, `instrument_registry`, `scene_registry`, or `execution_manifest`; Studio owns those. Do not edit managed files to register/preload assets, wire scenes, execution order, or force bootstrap sync; write user-authored scene code in `main.ts` or feature modules with bare refs like `models.Robot` or `textures.Grass`, then let Studio sync bootstrap/asset/scene/execution wiring. Hot reload is the normal way to see code changes. If the hot-reload path discovers new asset/bootstrap/scene-surface needs, Studio automatically upgrades the reload tier internally (`patchMain`, `preserveScene`, or hard `rebuildScene`). Only the hard rebuild tier performs a full bundled scene run.",
44486
+ '8. Wave Studio automations: `project.assetrefs.ts`, `project.scene.ts`, `project.scenes.ts`, and `project.execution.ts` are automatically managed by Wave Studio and are MCP read-only for agents. `bootstrap.ts` / scene `*/bootstrap.ts` is normally managed too. Edit bootstrap only when you can confidently pass `managedFileEditReason` as one of: `world_streaming_or_terrain_provider` (including Google Maps 3D tiles), `render_profile_or_runtime_backend`, `media_consent_or_capture_plan`, `external_ai_or_tts_backend`, `scene_envelope_or_template_baseline`, `baseline_setup_before_user_main`, or `stale_api_update_to_latest`. Never edit bootstrap for `asset_manifest_or_loader`, `instrument_registry`, `scene_registry`, or `execution_manifest`; Studio owns those. Do not edit managed files to register/preload assets, wire scenes, execution order, or force bootstrap sync; write user-authored scene code in `main.ts` or feature modules with bare refs like `models.Robot` or `textures.Grass`, then let Studio sync bootstrap/asset/scene/execution wiring. Hot reload is the normal way to see code changes. Static VFS/package/asset-surface changes can be detected from file/package diffs, so Studio may upgrade the reload tier internally (`patchMain`, `preserveScene`, or hard `rebuildScene`). Runtime-authored UI state changes cannot be inferred from files; when UI changes bootstrap/world-provider/runtime-envelope state, call `waveStudio.reloadPreview({ reason, invalidates: ["world-provider"] })` with the narrowest valid invalidation: `bootstrap`, `world-provider`, or `runtime-envelope`. Only the hard rebuild tier performs a full bundled scene run.',
44487
44487
  "9. Use `waveStudio.*` only for Studio host services. Check `waveStudio.capabilities.assetSave` before save/bake calls.",
44488
44488
  '10. Make deterministic file edits through the simplest fitting tool. Default to forgiving `edit_wave_file`: oldText infers exact replace, startLine/endLine infers line replace, `edits:[{startLine,endLine,text}]` or `edits:[{rangeOffset,rangeLength,text}]` performs one-file multi-edit, and path+text/content with no oldText infers whole-file replace. It is the primary simple edit tool and can omit `baseHash`; Studio resolves the latest hosted VFS mirror contentHash and still applies browser-side stale-write checks. Prefer canonical fields: `path` for file path, `text` for line/whole-file content, and `newText` for text replacement; `filePath`, `replacement`, and `content` are accepted as aliases where useful. Use `apply_wave_patch({ operations: [...] })` for multi-file edits, grouped cross-file edits, unified diffs, or full rewrites; a single bare operation is tolerated for mistake recovery but operations:[...] is preferred. Use `create_wave_file`, `rename_wave_file`, and `delete_wave_file` to split projects into `.ts` modules such as `/actors/player.ts`, `/systems/obstacles.ts`, and `/levels/obby.ts` instead of growing one giant `main.ts`; newly created `.ts/.tsx` files are standalone runnable source roots by default, so top-level scene code in them runs on Run/hot reload. Pass `runnable:false` only for pure helper modules that should not execute on their own. These same VFS tools also create `.html` sketch files for diagrams/charts/docs, with Mermaid rendered from `<div class="mermaid">...</div>` when the HTML file is active in the editor/coding pane; HTML sketches must never replace the live engine preview iframe. Scene-root modules and their owned helpers run inside the Studio authoring context, but helpers should stay pure or parameterized. Studio hot reload targets the active/open edited file when safe: `/main.ts` reloads the whole main graph, scene-root modules reload that root, and bootstrap/scene registry/assets/network/ambiguous helper surfaces escalate. Standalone `hot_reload_wave_preview` has no target path and follows the currently open/active Studio editor file in multi-file projects. A feature file should own the objects, callbacks, promoted GLB parts, and appearance mutations it wants to iterate on. For intentional live entity reuse across modules, the owner calls `waveStudio.exportEntity("Name", entity)` and importers call `waveStudio.importEntity<T>("Name")`; do not pass live entities through shared helper exports. Use exact VFS paths from `list_wave_files`; read target file before writing. `contentHash` is a cooperative stale-write fingerprint, not a security boundary. For advanced compact `apply_wave_patch` operations, pass the latest full-file `contentHash` as `baseHash`: one `lineEdits`, one `textEdits`, one strict `searchReplace`, or one `unifiedDiff`. Do not send multiple compact ops for the same file with the same baseHash; the first edit changes the file hash and later compact ops skip as stale. Scoped `read_wave_file` line ranges do not change the `textEdits` offset base; they do pair naturally with line-based edits. Existing-file `writeFile` requires `baseHash` unless `forceOverwrite: true`; force overwrite is only for intentional stale overwrites.',
44489
44489
  "10a. Always inspect `changedFiles`, `changedPaths`, `partial`, `skippedOperations`, `hotReloadRequested`, `hotReloadSkippedReason`, and `runtimeVerification`; treat skipped operations, no-content-change skips, unscheduled hot reloads, runtime verification errors, and `runtimeVerification.diagnostics.editorErrorCount > 0` as work still needing attention.",
44490
- "11. After the final code edit, default to hot reload. Prefer `awaitHotReload: true` on the edit tool when you want one MCP response with edit result + hot reload + bounded diagnostics. `requestHotReload:true` also waits for diagnostics by default unless paired with `awaitHotReload:false`. Standalone `run_wave_preview` / `hot_reload_wave_preview` also wait by default and return `runtimeVerification`; set `awaitRuntimeResult:false` only for intentional fire-and-poll. Caveat: standalone `hot_reload_wave_preview` mirrors the toolbar button and reloads the currently open/active TypeScript file in multi-file projects; it does not take a target path or reload every user-created .ts module. That hot-reload request may internally upgrade from `patchMain` to `preserveScene` or hard `rebuildScene` when assets/bootstrap/scene surface changed; do not manually force bootstrap sync. Use `run_wave_preview` only when diagnostics show no successful preview yet (`hasRunSucceeded: false`), the user explicitly asks for a full run/restart, or hot reload/polling fails and a full restart is the last resort. `pause_wave_preview` and `resume_wave_preview` are direct preview controls mirroring the toolbar pause/resume buttons.",
44490
+ '11. After the final code edit, default to hot reload. Prefer `awaitHotReload: true` on the edit tool when you want one MCP response with edit result + hot reload + bounded diagnostics. `requestHotReload:true` also waits for diagnostics by default unless paired with `awaitHotReload:false`. Standalone `run_wave_preview` / `hot_reload_wave_preview` also wait by default and return `runtimeVerification`; set `awaitRuntimeResult:false` only for intentional fire-and-poll. Caveat: standalone `hot_reload_wave_preview` mirrors the toolbar button and reloads the currently open/active TypeScript file in multi-file projects; it does not take a target path or reload every user-created .ts module. That hot-reload request may internally upgrade from `patchMain` to `preserveScene` or hard `rebuildScene` when assets/bootstrap/scene surface changed; do not manually force bootstrap sync. Runtime-authored UI that changes bootstrap/world-provider/runtime-envelope state must call `waveStudio.reloadPreview({ reason, invalidates: ["world-provider"] })` because Studio cannot infer that from static file diffs. Use `run_wave_preview` only when diagnostics show no successful preview yet (`hasRunSucceeded: false`), the user explicitly asks for a full run/restart, or hot reload/polling fails and a full restart is the last resort. `pause_wave_preview` and `resume_wave_preview` are direct preview controls mirroring the toolbar pause/resume buttons.',
44491
44491
  '12. After run/hot reload, use returned `runtimeVerification` when present; otherwise call `get_wave_runtime_diagnostics` repeatedly until `runtimeBusy` is false and `lastRuntimeOutcome` is `success` or `error`. Use `previewExecutionPhase` to distinguish Studio preparing work from the preview iframe executing it. `isRunning` is only the Studio scheduling flag, not the final runtime completion gate. If the edit/runtime tool returned `requestedAt` or `runtimeActionRequestedAt`, ignore diagnostics whose `lastRuntimeOutcomeAt` is older than that timestamp. Treat `latestError` as current only when `lastRuntimeOutcome` is `error`; older error lines can remain in returned logs as history. Treat `editorErrorCount > 0` as blocking Monaco/linter/compile failure and read `editorDiagnostics` before claiming success, even when `lastRuntimeOutcome` is `success`. If `lastRuntimeOutcome` is `success` and `editorErrorCount` is 0, verify visually with `capture_wave_screenshot({ resolution: "L" })` or structurally with `get_wave_runtime_entity_snapshot({ variableName, filePath? })` instead of declaring failure from old log text. Same-machine screenshots usually return `localPath`; hosted screenshots return exact field `dataBase64`, not `imageBase64`.',
44492
44492
  "12a. Marker waypoint workflow: when the human asks to use preview marking tools such as `clickToMark()`, route with `marker.use` plus the code/project intent, then call `list_wave_runtime_markers`. Treat marker records as runtime observation data, write marker `worldPosition`/`worldRotation` into the appropriate path/waypoint/placement code, hot reload, and verify with screenshot or marker re-read. One marker read may happen before routing only when needed to decide the code intent. Use path/placement skills only when current code does not reveal the marker-to-code pattern.",
44493
44493
  `13. To use locally generated assets in code, prefer \`create_wave_asset_upload\` for local files when available: pass assetKind from the Wave Studio upload policy SSOT (${getWaveStudioBridgeAssetUploadKindHelpText()}), stat the file first, pass exact byte size, get \`uploadUrl\` + \`uploadHeaders\`, upload raw bytes with plain HTTP PUT using every returned header exactly, keep \`clientToken\`/\`uploadHeaders.Authorization\` out of logs, call \`get_wave_asset_upload_status\` until \`receivedBytes === sizeBytes\`, then call \`commit_wave_asset_upload\` with the same uploadId, assetKind, filename, contentType, and sizeBytes from the create response. No local Python, Vercel package, or Blob SDK is required. On hosted MCP this uses hosted temporary object storage; on same-machine local MCP it uses the local SDK as temporary staging. If direct upload is unavailable, use \`stage_wave_asset_upload_chunk\` plus \`commit_wave_asset_chunk_upload\`: omit uploadId only for chunkIndex 0, then reuse the returned uploadId for every later chunk and for commit. Use \`upload_wave_asset\` with exactly one of \`dataBase64\` or \`dataUrl\` only for small inline assets. If staging is abandoned before commit, call \`abort_wave_asset_upload\` with the uploadId. Do not abort after commit returns pending or completed; the Studio browser cleans committed staging after execution. Hosted MCP cannot read local filesystem paths through inline upload. All flows stage bytes outside the command queue, cap staged bytes at 300 MB, and return \`asset.bareRef\`, for example \`textures.Albedo\`, \`cubeMaps.Studio\`, \`materials.Wood\`, \`audios.Click\`, \`models.Robot\`, \`animations.Run\`, \`fonts.Title\`, or \`serializedData.Config\`. If the name already exists, the upload result returns \`skipped: true\` and the existing asset. Staged chunks/blobs are also swept lazily after about 24 hours. Model-family uploads enable meshoptimizer by default unless \`useMeshoptimizer\` is false.`,
@@ -44664,7 +44664,7 @@ var WAVE_MCP_STUDIO_TOOL_GUIDE = [
44664
44664
  "- `waveStudio.saveFor3dPrinting(target, options?)`: save export-friendly model.",
44665
44665
  "- `waveStudio.saveMaterial(request)`: save authored material asset.",
44666
44666
  "- `waveStudio.bakeTerrainMaterial(request)`: bake terrain material textures.",
44667
- "- `waveStudio.reloadPreview({ reason? })`: request the Wave Studio toolbar-style reload path from authored code. Use this when a UI authored in `main.ts` changes Studio/bootstrap-backed state such as active city/world provider and must re-run the Studio preview package. Do not call `myScene.hotReload(...)` from Studio-authored code for this; that bypasses Studio VFS/package/source-patch orchestration.",
44667
+ '- `waveStudio.reloadPreview({ reason?, invalidates? })`: request the Wave Studio toolbar-style reload path from authored code. Use `invalidates: ["world-provider"]` when UI authored in `main.ts` changes Studio/bootstrap-backed runtime state such as active city/world provider and must rebuild the Studio preview package. Valid invalidations are `bootstrap`, `world-provider`, and `runtime-envelope`; use the narrowest true reason. Do not call `myScene.hotReload(...)` from Studio-authored code for this; that bypasses Studio VFS/package/source-patch orchestration.',
44668
44668
  "- `waveStudio.exportEntity(name, entity)`: declare a live entity owned by the current source module for intentional modular reuse. `name` must be a static string literal and unique across runnable roots.",
44669
44669
  "- `waveStudio.importEntity<T>(name)`: import an exported live entity into the current source module; Studio restores the exporter baseline and prunes/replays importer callbacks/overlays during source hot reload. Studio orders source roots by export/import dependencies: exporter before importer; exporter before `main.ts` if main imports it; overlay importers after exporter/main baseline. Missing, duplicate, dynamic, or cyclic entity names stop run/hot reload before execution.",
44670
44670
  '- MCP command result rule: poll `get_wave_command_result({ requestId })` only when the previous tool response includes `status:"pending"` plus `requestId`. HTTP Gateway browser-backed tools may return pending and need that poll. WaveEngine Agent SDK browser-backed tools wait directly and return final results; its `get_wave_command_result` is a catalog-parity no-op unless a pending result was explicitly returned.',
@@ -46199,7 +46199,7 @@ var HOT_RELOAD_UNSAFE_SCENE_EVENT_CALLBACKS = /* @__PURE__ */ new Map([
46199
46199
  ["once", "myScene.once(...) is scene-scoped, but an unfired one-shot handler can survive preserve-scene hotreload. Use Wave-owned input/entity callbacks, or wait for a scoped Wave scene-event authoring API."]
46200
46200
  ]);
46201
46201
  var HOT_RELOAD_FORBIDDEN_STUDIO_SCENE_METHODS = /* @__PURE__ */ new Map([
46202
- ["hotReload", 'Studio-authored code must not call myScene.hotReload(...). Use waveStudio.reloadPreview({ reason: "..." }) so Wave Studio can flush VFS, rebuild the project package/bootstrap, sync assets, choose the correct reload tier, and return diagnostics.']
46202
+ ["hotReload", 'Studio-authored code must not call myScene.hotReload(...). Use waveStudio.reloadPreview({ reason: "...", invalidates: ["world-provider"] }) when authored UI changes bootstrap/world-provider/runtime-envelope state so Wave Studio can flush VFS, rebuild the project package/bootstrap, sync assets, choose the correct reload tier, and return diagnostics.']
46203
46203
  ]);
46204
46204
  var HOT_RELOAD_UNSAFE_CONSTRUCTORS = /* @__PURE__ */ new Map([
46205
46205
  ["Promise", "new Promise(...) is not hotreload-safe because it creates unmanaged callback closures. Use awaitable Wave APIs instead."],
@@ -52407,10 +52407,8 @@ function readLocalSdkPeerHealth(value) {
52407
52407
  const data = isRecord4(value.data) ? value.data : value;
52408
52408
  const bridgeId = readStringProperty(data, "bridgeId");
52409
52409
  const protocolVersion = readStringProperty(data, "protocolVersion");
52410
- const requiredPackage = readStringProperty(data, "requiredPackage");
52411
52410
  const isCurrentSdkProtocol = protocolVersion === "waveengine-agent-sdk-http-v1";
52412
- const isLegacyHelperProtocol = protocolVersion === "local-agent-helper-http-v1" && typeof requiredPackage === "string" && requiredPackage.startsWith("wave3d-agent-bridge@");
52413
- if (!bridgeId || !bridgeId.startsWith("wgbridge_") || !isCurrentSdkProtocol && !isLegacyHelperProtocol) {
52411
+ if (!bridgeId || !bridgeId.startsWith("wgbridge_") || !isCurrentSdkProtocol) {
52414
52412
  return null;
52415
52413
  }
52416
52414
  return {
@@ -52529,34 +52527,7 @@ async function findChildProcessIds(parentPid) {
52529
52527
  }
52530
52528
  }
52531
52529
  function isWaveEngineAgentProcessCommand(command) {
52532
- return /\bwave3d-agent-(sdk|bridge)\b/.test(command);
52533
- }
52534
- function isLegacyBridgePeer(health) {
52535
- return health.protocolVersion === "local-agent-helper-http-v1";
52536
- }
52537
- async function stopLegacyBridgeLaunchAgent(health) {
52538
- if (!isLegacyBridgePeer(health) || process.platform !== "darwin") return;
52539
- const getuid = process.getuid;
52540
- if (typeof getuid !== "function") return;
52541
- const uid = getuid();
52542
- const launchTarget = `gui/${uid}/com.wave3d.agent-bridge`;
52543
- console.log("[WaveEngine Agent SDK] Stopping legacy wave3d-agent-bridge launch agent before replacement.");
52544
- try {
52545
- await execFileAsync("launchctl", ["bootout", launchTarget], {
52546
- timeout: 2500,
52547
- maxBuffer: 128 * 1024,
52548
- windowsHide: true
52549
- });
52550
- } catch {
52551
- }
52552
- try {
52553
- await execFileAsync("launchctl", ["remove", "com.wave3d.agent-bridge"], {
52554
- timeout: 2500,
52555
- maxBuffer: 128 * 1024,
52556
- windowsHide: true
52557
- });
52558
- } catch {
52559
- }
52530
+ return /\bwave3d-agent-sdk\b/.test(command);
52560
52531
  }
52561
52532
  async function collectVerifiedSdkPeerProcessIds(seedPids) {
52562
52533
  const targetPids = /* @__PURE__ */ new Set();
@@ -52641,7 +52612,6 @@ async function waitForSdkPeerPortRelease(port, deadlineMs) {
52641
52612
  return false;
52642
52613
  }
52643
52614
  async function terminateVerifiedSdkPeer(health, port) {
52644
- await stopLegacyBridgeLaunchAgent(health);
52645
52615
  const seedPids = /* @__PURE__ */ new Set();
52646
52616
  if (health.processId && health.processId !== process.pid) seedPids.add(health.processId);
52647
52617
  for (const pid of await findListenerProcessIds(port)) seedPids.add(pid);
@@ -3,6 +3,6 @@
3
3
  Bundled public-safe WaveEngine SDK lookup cache for wave3d-agent-sdk.
4
4
  Generated from sanitized public API/skill corpus during package build.
5
5
 
6
- cacheKey: 2026-06-17.1.TzPhd-nl78ioHZ5HHdOLeV95c3YCuOJf
7
- bundleHash: TzPhd-nl78ioHZ5HHdOLeV95c3YCuOJf
8
- zip: wave-engine-sdk-2026-06-17.1.TzPhd-nl78ioHZ5HHdOLeV95c3YCuOJf.zip
6
+ cacheKey: 2026-06-17.1.fz3T9rwUI7jgxk1aZBl-4dloSaAXWjEf
7
+ bundleHash: fz3T9rwUI7jgxk1aZBl-4dloSaAXWjEf
8
+ zip: wave-engine-sdk-2026-06-17.1.fz3T9rwUI7jgxk1aZBl-4dloSaAXWjEf.zip
@@ -1,21 +1,21 @@
1
1
  {
2
- "version": "2026-06-17.1.TzPhd-nl78ioHZ5HHdOLeV95c3YCuOJf",
2
+ "version": "2026-06-17.1.fz3T9rwUI7jgxk1aZBl-4dloSaAXWjEf",
3
3
  "formatVersion": "2026-06-17.1",
4
- "cacheKey": "2026-06-17.1.TzPhd-nl78ioHZ5HHdOLeV95c3YCuOJf",
5
- "bundleFileName": "wave-engine-sdk-2026-06-17.1.TzPhd-nl78ioHZ5HHdOLeV95c3YCuOJf.zip",
6
- "bundleHash": "TzPhd-nl78ioHZ5HHdOLeV95c3YCuOJf",
4
+ "cacheKey": "2026-06-17.1.fz3T9rwUI7jgxk1aZBl-4dloSaAXWjEf",
5
+ "bundleFileName": "wave-engine-sdk-2026-06-17.1.fz3T9rwUI7jgxk1aZBl-4dloSaAXWjEf.zip",
6
+ "bundleHash": "fz3T9rwUI7jgxk1aZBl-4dloSaAXWjEf",
7
7
  "generatedAt": "2026-06-06T00:00:00.000Z",
8
8
  "sourceVersions": {
9
9
  "onboarding": {
10
10
  "promptVersion": "2026-06-15.2",
11
- "promptHash": "YyLcFG8-h779ReTOG7GOz4mjgutRtKZw"
11
+ "promptHash": "XmQbudg8ys8LmiXVENo3zVyngwfWfTD7"
12
12
  },
13
13
  "apiHandbook": {
14
14
  "version": "1",
15
15
  "contentHash": "edf117cbd2b09857"
16
16
  },
17
17
  "waveSkillCorpusHash": "nhg-WfsotIdN1pRO41g97bff6RrKujrN",
18
- "sdkLookupCorpusHash": "1DUg8-FDFbzXLOMm12TB3-S_y4c6Z74H"
18
+ "sdkLookupCorpusHash": "cIY-jnbSR_-b2nlQgJwVDT7ffQyZ372l"
19
19
  },
20
20
  "cacheContract": {
21
21
  "llmContextCacheOnly": [
@@ -35,7 +35,7 @@
35
35
  "searchDocuments"
36
36
  ],
37
37
  "rule": "Priority 1 always-on sections must stay in LLM chat/system context. The WaveEngine SDK local cache is public-safe retrieval data, never the only memory for core policy.",
38
- "defaultRefreshCommand": "npx -y wave3d-agent-sdk@0.2.9 cache refresh",
38
+ "defaultRefreshCommand": "npx -y wave3d-agent-sdk@0.2.10 cache refresh",
39
39
  "refreshRule": "When using WaveEngine SDK local cache, compare cacheKey, bundleHash, and sourceVersions before trusting local lookup. If any value differs, update the SDK package or reinstall its bundled SDK cache and rebuild local indexes. Do not fetch a remote SDK zip.",
40
40
  "onlineFallback": "HTTP Gateway does not provide cloud API lookup. If local Node/npm or cache is refused/unavailable, use only concrete Studio operations and already-known code; repair the local WaveEngine SDK before unfamiliar API authoring."
41
41
  },
@@ -50,8 +50,8 @@
50
50
  "path": "cache-policy.json",
51
51
  "mediaType": "application/json",
52
52
  "role": "lookup-guide",
53
- "bytes": 1310,
54
- "hash": "PCkIsr75VpI_nQ4ufjVs-j13jCuh_YUL"
53
+ "bytes": 1311,
54
+ "hash": "cKZ5cpwWvIcymqtgXmCcrFyPK5pMUCKm"
55
55
  },
56
56
  {
57
57
  "path": "skills/wave-skills.jsonl",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wave3d-agent-sdk",
3
- "version": "0.2.9",
3
+ "version": "0.2.10",
4
4
  "description": "WaveEngine Agent SDK for same-machine Wave Studio MCP plus bundled WaveEngine lookup.",
5
5
  "type": "module",
6
6
  "license": "UNLICENSED",