Agent skill Web motion
Three.js Asset Pipeline
Use spatial graphics, scenes or materials to support a web experience.
Install the skill
Run the command from your project root with Node.js and npm.
npx skills@latest add cloudai-x/threejs-skills --skill threejs-asset-pipeline --agent claude-code --yesCheck this file in your project.claude/skills/threejs-asset-pipeline/SKILL.md
Other ways to install
Choose an assistant interactively
npx skills@latest add cloudai-x/threejs-skills --skill threejs-asset-pipelineSelect your assistant and choose the project installation scope.
Official instructions
The tested Skills CLI 1.10.0 requires Node.js 22.20 or later. A licensed or original GLB, Node.js compatible with the installed glTF Transform CLI, and an existing Three.js viewer.
View operation manualWhat this skill helps with
- Use spatial graphics, scenes or materials to support a web experience.
Good for
- 3D on the web
- Publisher
- cloudai-x
- Control points
- inspect · meshopt --level high · validate · loader.setMeshoptDecoder()
- Result
- Two inspect reports and a browser-tested compressed asset with its decoder wired.
- Skill name
threejs-asset-pipeline- Repository
cloudai-x/threejs-skills
Common pitfall
Avoid this prompt
Replace the source GLB with an optimized file before inspecting required extensions.
Some extensions need explicit runtime decoders, and losing the source removes a useful visual baseline.
Use these steps
- Inspect the original target
- Apply the documented technique
- Verify the result in the project
Project walkthrough
Inspect one original GLB, apply Meshopt compression, and validate the decoded model in Three.js.
Inspect one original GLB, apply Meshopt compression, and validate the decoded model in Three.js.
Inspect the original target
Inspect the original target
Prompt · Step 1Use Three.js Asset Pipeline on [my original copper marker GLB]. Keep the source file, run npx @gltf-transform/cli inspect <source.glb>, and note bytes, triangle count, attributes, required extensions and image count. Capture a baseline pose in the actual viewer.Apply the documented technique
Apply the documented technique
Prompt · Step 2Run npx @gltf-transform/cli meshopt <source.glb> <compressed.glb> --level high and inspect the output. Import MeshoptDecoder from three/addons/libs/meshopt_decoder.module.js. Create const loader = new GLTFLoader(), call loader.setMeshoptDecoder(MeshoptDecoder), then use that same instance to load the file with loader.loadAsync(). Keep a compression-focused comparison and record any attribute or registration differences instead of treating smaller bytes as fewer runtime faces.Verify the result in the project
The compressed GLB loads in the viewer through its matching decoder and the measured geometry remains equivalent.
- The compressed GLB loads in the viewer through its matching decoder and the measured geometry remains equivalent.
Prompt · Step 3Run npx @gltf-transform/cli validate <compressed.glb> and record any extension support warnings. Also load it in a browser at the baseline pose and compare bounds, silhouette, material and index count against the source. Confirm decoder errors are surfaced and keep the original asset as a fallback where needed. Report sizes and renderer version.
Implementation lookup
Find the input and the expected observation for the selected workflow.
Check the control pointsInputs
- Command or reference
inspect · meshopt --level high · validate · loader.setMeshoptDecoder()- Examples
- The compressed GLB loads in the viewer through its matching decoder and the measured geometry remains equivalent.
FAQ
What decides which decoder to wire?
Read the required extensions in the generated file and consult the installed loader. Meshopt-compressed output uses MeshoptDecoder with GLTFLoader.
Where can I verify the version?
Open the publisher’s pinned Skill source and compare the API references with the application’s lockfile.