Benchmarking LLM 3D Programming Skills: A Dual-Dimension Approach to Quality and Efficiency

    A practical framework for evaluating large language models on interactive 3D tasks, combining six quality dimensions—runnability, structural realism, interaction, aesthetics, accessibility, and code quality—with efficiency metrics like end-to-end time and token consumption, to produce reproducible, decision-ready comparison results.

    Why Use 3D Interactive Tasks to Test Model Engineering Capability

    In real-world development, a model’s value rarely lies in how convincing its answers sound, but in whether its deliverables actually run, can be modified, and can ship to production. Interactive 3D tasks—such as disassembling mechanical structures and physical animations—make an excellent high-difficulty benchmark for three reasons:

    • Large state space: Geometry, materials, lighting, cameras, animation timelines, and interaction events are tightly coupled. A failure in any single part can render the whole output unusable.
    • Automatically verifiable correctness: Whether there are zero script errors, whether resources load successfully, and whether disassembly truly modifies the scene graph can all be verified programmatically, avoiding subjective scoring.
    • Aesthetics and engineering are judged together: The output must look credible while the code remains maintainable, degrade gracefully, and be accessible.

    The focus of evaluation, therefore, is not “who generates flashier results” but under identical conditions, who delivers higher-quality output in less time.

    Evaluation Design: Lock Down the Variables

    The most common mistake in side-by-side benchmarking is uncontrolled variables. Fix the following four:

    1. Same prompts: Include both a “one-sentence wish-style” prompt and a “constraint-based structured” prompt per task, to observe how models handle reasonable completion when information is incomplete.
    2. Same agent and toolchain: Identical file read/write, command execution, and screenshot review capabilities, so tool differences aren’t mistaken for model differences.
    3. Same runtime environment: Matching runtime versions, screen resolution, headless browser configuration, and network conditions.
    4. Same acceptance script: All outputs run through the same automated assertions and screenshot pipeline.

    Quality Dimension: Six Scorable Aspects

    1. Runnability (Veto Criterion)

    Zero script exceptions, zero resource load failures, and no uncaught console errors. Any output that “looks like 3D but the interactions don’t work” is immediately disqualified.

    2. Structural Realism

    The key question is whether disassembly/assembly actually manipulates the scene graph and transformation matrices, rather than playing a pre-baked animation. A合格 implementation should satisfy: independent part hierarchies, visible internal structure after disassembly, and consistent state after reset.

    3. Interaction Effectiveness

    Is the disassembly progress continuous with visual feedback? Do annotation lines track part projections in real time? Are there details like staggered expansion by index? Do responsive breakpoints cover multiple screen sizes?

    4. Visuals and Aesthetics

    Color logic, material differentiation, and whether the default camera framing and exposure are sensible. The most common scoring losses in practice are a default camera positioned too far away and default exposure set too low—either can make users conclude within the first three seconds that “the model built it wrong.”

    5. Accessibility and Graceful Degradation

    Does the output include semantic markup, keyboard reachability, adaptation for “reduced motion” preferences, and a degradation path for low-performance devices?

    6. Code Engineering Quality

    Explicit disposal of resources and textures, deterministic reproducibility of randomized processes, clear module separation, and absence of basic modeling defects such as geometry clipping/interpenetration.

    A scoring table structure that can be used directly:

    1. {
    2. "task": "mechanical_deconstruct_3d",
    3. "gates": ["no_js_error", "no_resource_404", "deconstruct_changes_scene_graph"],
    4. "scores": {
    5. "runtime": 0, "structure": 0, "interaction": 0,
    6. "aesthetics": 0, "a11y": 0, "code_quality": 0
    7. },
    8. "metrics": { "wall_time_sec": 0, "retries": 0, "tokens": 0 }
    9. }

    The core assertions for automated acceptance can be quite simple:

    1. // Pseudocode: verify that "disassemble" actually takes effect
    2. const before = scene.getObjectByName('gearbox').getWorldPosition();
    3. await page.click('#explode');
    4. const after = scene.getObjectByName('gearbox').getWorldPosition();
    5. assert(before.distanceTo(after) > 0.5, 'Disassembly did not change the scene graph');
    6. assert(pageErrors.length === 0, 'Uncaught exceptions exist');

    Efficiency Dimension: Time Spent Is Not the Same as Quality

    The second use case (generating a fully operational container crane in a port scene) tests physical structure design and scene aesthetics: whether the spreader’s lifting, the trolley’s traverse, and the boom’s motion follow reasonable kinematic constraints, rather than parts floating independently.

    On the efficiency side, track three quantities: end-to-end time, number of rework iterations, and token consumption. In practice, clear divergence emerges: some implementations deliver in about 7 minutes with top-tier quality; others take 9 minutes but suffer from clipping and missing loading states; still others take over 30 minutes, spending the time on repeated exploration and self-verification.

    It’s worth emphasizing that long runtimes can be either a flaw or a strategy: more thorough self-verification genuinely improves structural complexity and completeness. Efficiency metrics must therefore be interpreted jointly with quality scores—use ratios like “quality per unit of time” rather than raw duration alone to draw conclusions.

    Conclusions and Practical Recommendations

    • When prioritizing structure and engineering standards, favor implementations with clear hierarchies, complete accessibility, and graceful degradation.
    • When prioritizing visual distinctiveness and modeling precision, focus on materials, curves, and detail completeness—but add extra acceptance checks for clipping and exposure.
    • When prioritizing iteration speed, use cache hits, context length, and concurrency strategies to keep costs down, and add logging, monitoring alerts, and automated regression of deliverables in the production pipeline.

    Finally, three common pitfalls to avoid: reviewing screenshots without checking the console; replacing automated assertions with subjective impressions; and ignoring “first-impression variables” like the default camera angle and default exposure. Lock down the variables, write the assertions clearly, and put quality and efficiency in the same table—only then are benchmark conclusions truly reproducible and actionable.