Evo threejs scene parser

From OpenLAIR/OpenSkill · View interactive version

Evo threejs scene parser is an AI agent skill from the GitHub repository OpenLAIR/OpenSkill. Parse a Three.js createScene() file in headless Node.js, identify part-level structure (Groups and standalone Meshes), and export OBJ files for both individual sub-meshes per part and merged part assemblies (links). Use when extracting decomposed 3D object structure from Three.js scene definitions.

How to use this skill

Skill file

evo-threejs-scene-parser

Parses a Three.js scene file (one that exports a createScene() function) using a headless Node.js runtime, then exports each part as Wavefront OBJ files in two views:

Output Layout

output/
├── part_meshes/
│   ├── <part_name>/<mesh_name>.obj  # one per direct child Mesh
│   └── ...
└── links/
    ├── <part_name>.obj  # merged direct child meshes only
    └── ...

Part Identification Rules

  1. A "part" is ANY THREE.Group found anywhere in the scene tree (excluding the root). Use root.traverse() and collect node.isGroup.
  2. Standalone Meshes that are direct children of the root (not inside any Group) are also exported as their own part.
  3. For each Group:
  1. root.updateMatrixWorld(true) MUST be called before export so world matrices are baked.
  2. Use node.name for naming; fallback UnnamedGroup_<i> / UnnamedMesh_<i>.
  3. For merging: clone geometries, apply matrixWorld, convert indexed→non-indexed, strip non-essential attributes (keep only position+normal), then use mergeGeometries().

Usage (Python)

import sys
sys.path.insert(0, '/app/environment/skills/evo-threejs-scene-parser/scripts')
from run import run_threejs_parser
result = run_threejs_parser('/root/data/object.js', '/root/output')
print(result)

Usage (CLI)

cd /root && node /app/environment/skills/evo-threejs-scene-parser/scripts/parser.mjs /root/data/object.js /root/output

Key Implementation Notes

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.