Verifiable 3D Script Generation: A Benchmark Method for Evaluating Model Capabilities

    As general-purpose models expand from text generation and code completion into executable 3D content generation, "writing code" no longer proves "the ability to model." This article presents an evaluation method for pure-code 3D scene generation, using a composite character-riding-a-bicycle scene as the test case. It defines the task format (single prompt, no reference images, headless-executable script, parameterized re-runs), breaks acceptance into six dimensions — semantic fidelity, degree of parameterization, spatial and assembly constraints, kinematic and phase consistency, executability and robustness, and verifiability and maintainability — and shows why re-parameterization testing is the step that truly separates models. Common failure modes and practical guidance for building a standardized test set are also covered.

    1. Background: Why “Being Able to Write Code” Is Not the Same as “Being Able to Model”

    The capability boundary of general-purpose models is expanding from text generation and code completion to executable 3D content generation. “Generating a 3D scene purely in code” does not mean producing a plausible-looking geometric description. It means delivering a script that runs directly, with no reference image, no external assets, and no manual drag-and-drop modeling. In headless mode, the script must build the scene, name objects, set materials or colors, organize the hierarchy, place cameras and lights, and satisfy defined spatial and kinematic constraints.

    This class of task is harder than an ordinary coding problem because it exercises four capabilities at once:

    1. Semantic understanding — extracting characters, vehicles, environment, actions, style, and narrative relationships from natural language.
    2. Structured planning — decomposing a complex scene into subsystems such as frame, wheels, drivetrain, character pose, accessories, and environment.
    3. Spatial reasoning — getting dimensions, positions, orientations, and contact relationships between parts right, rather than having each part merely “look about right.”
    4. Verifiable engineering — keeping parameters in a single source, deriving geometry from them, and proving correctness through automated assertions, logs, and re-run tests.

    A seemingly simple scene such as “a character riding a bicycle” is therefore a good overall test. It involves dimension chains, assembly relationships, drivetrain phase, character pose, suspension and contact states, and the balance between artistic and engineering constraints. A model that only produces static props may pass visually; but as soon as you ask it to change the wingspan, the chainring tooth count, or the crank phase, hidden hard-coded values, broken parameter chains, and incorrect spatial relationships surface.

    2. Benchmark Task Design: From a Single Prompt to a Re-runnable Script

    The task should take the form of a single prompt, zero reference images, an executable script, and parameterized re-runs. The prompt can be abstracted as follows:

    Build a composite character-riding scene from text alone. The script must run in headless mode. All key dimensions, tooth counts, and phase parameters must be declared at the top of the script as global constants. All geometry must be derived from those constants; no disconnected magic numbers may appear inside functions. Artistic styling is allowed, but spatial relationships between parts must pass parameterized checks. The crank is driving the rear wheel and the chain stays tensioned. One of the character’s feet is on a pedal; the other hangs in the low position of the return stroke. Handlebar width, grip positions, and foot contact states must be linked to the parameters.

    To compare multiple general-purpose models fairly, the evaluation should standardize the host environment, units, coordinate-system conventions, entry point, and log format. The task can be broken into verifiable goals:

    • Scene completeness — are the frame, wheels, drivetrain, character, tool bag, rear rack, fishing net, and other objects all present?
    • Structural soundness — is the frame a stable structure, are the wheels on the ground, and is there a drivetrain relationship between crank and rear wheel?
    • Parameter linkage — after changing the top-level constants, is the related geometry recomputed rather than only the displayed values?
    • Pose correctness — do the grips enclose the character’s forward-reaching extremities, and do the pedals contact the feet or maintain the specified clearance?
    • Kinematic consistency — does the crank phase drive the pedal positions, do the left and right pedals keep a sensible phase offset, and is the chain closed without clipping?
    • Executability — does the headless run succeed, with no uncaught exceptions, empty geometry, NaN coordinates, or external dependencies?
    • Verifiability — are assertions, geometry checks, logs, or diagnostic output provided so acceptance can be automated?

    3. Core Evaluation Dimensions

    3.1 Semantic Fidelity

    Semantic fidelity is not as simple as “does a bicycle appear.” Objects, actions, spatial relationships, and narrative elements must all hold simultaneously. For example, the character leaning forward, both wings extended forward to grip the handlebar, one webbed foot on a pedal, the other suspended in the low return position, a tool bag hanging from the down tube, a fishing net tied to the rear rack, and a seaside promenade at dusk are all semantic requirements. During evaluation, semantic points should be converted into checkable items: object existence, hierarchy relationships, material or color tendencies, character orientation, and relative part positions. Artistic interpretation is acceptable, but stylization must not be used to mask structural errors.

    3.2 Degree of Parameterization

    Parameterization is what separates “writing code” from “building a model.” The correct approach is to declare key parameters at the top of the script and derive all geometry from them, for example:

    1. WINGSPAN = 1.15 # Wingspan; controls handlebar width and grip spacing
    2. WHEELBASE = 1.02 # Wheelbase; drives frame geometry
    3. CHAINRING_TEETH = 44 # Chainring teeth; drives chain length and gear ratio
    4. COG_TEETH = 16 # Rear cog teeth
    5. CRANK_PHASE_DEG = 35.0 # Crank phase angle
    6. GRIP_WIDTH_RATIO = 0.62
    7. CONTACT_TOL = 0.005

    Acceptance should not stop at checking whether these constants exist; it must verify that they actually affect geometry. Look for hard-coded dimensions disconnected from the parameters — for instance, grip positions fixed at an absolute value, a chain path drawn to a fixed length, or foot positions that do not change with phase. A stricter method is a re-parameterization test: change only the constant values, leave the code untouched, re-run the script, and check whether all related constraints still hold.

    3.3 Spatial Relationships and Assembly Constraints

    Spatial relationships cover dimension chains and assembly relationships. Handlebar width should vary with wingspan, and grip positions should enclose the character’s forward-reaching extremities; frame geometry should vary with wheelbase; wheels should touch the ground; crank, chainring, cog, and chain should lie in the same drivetrain plane or use a sensible offset; accessories should attach to the frame rather than float. Automated acceptance can use bounding boxes, center-point distances, normal angles, minimum clearances, and collision detection. For contact relationships, define a reasonable tolerance to avoid cases that “look like contact but are numerically suspended.”

    3.4 Kinematics and Phase Consistency

    The drivetrain is not static decoration. Crank phase should determine the current position of both pedals, and the left and right pedals normally maintain a phase offset of roughly half a cycle. The supporting foot should contact the current pedal surface, while the non-load-bearing foot should hang in the low return position. If the crank phase changes, the character pose must be re-solved rather than reusing the old positions. The chain path must also be recomputed so that it stays closed, tensioned, and free of clipping or suspended segments between chainring and cog. For this kind of scene, separate layout from kinematic solving: first compute frame, wheel sets, and drivetrain center distances from the parameters; then solve pedal positions from the crank phase; finally adjust the character’s foot and leg pose with inverse kinematics or constraint solving, and confirm contact or clearance with assertions.

    3.5 Executability and Robustness

    Executability is the baseline. The script must run successfully in headless mode, without manual interaction, without loading external models or textures, with a fixed random seed, consistent units, and stable naming. At minimum, the evaluation should check:

    • Whether the headless run returns a success status.
    • Whether there are uncaught exceptions, division by zero, empty-array out-of-bounds access, or invalid geometry.
    • Whether any NaN or infinite coordinates appear.
    • Whether zero-area faces, zero-length edges, or obviously degenerate geometry appear.
    • Whether repeated runs produce identical results.
    • Whether reasonable logs and error messages are produced.

    3.6 Verifiability and Maintainability

    A high-quality script should not only run; it should be able to prove it is correct. For example, add constraint-checking functions that report key dimensions, contact distances, chain closure error, and collision results. Pseudocode:

    1. def rebuild(params):
    2. handlebar = layout_handlebar(width=params.WINGSPAN * GRIP_WIDTH_RATIO)
    3. frame = layout_frame(wheelbase=params.WHEELBASE)
    4. drive = layout_drive(
    5. chainring=params.CHAINRING_TEETH,
    6. cog=params.COG_TEETH,
    7. phase=params.CRANK_PHASE_DEG
    8. )
    9. rider = solve_rider_pose(
    10. grip_targets=handlebar.grips,
    11. pedal_targets=drive.pedals
    12. )
    13. chain = solve_chain_path(frame, drive)
    14. assert_constraint(chain.is_closed())
    15. assert_constraint(chain.no_collision())
    16. assert_contact(rider.left_foot, drive.pedals.active, tol=CONTACT_TOL)
    17. assert_suspended(rider.right_foot, drive.pedals.return_low, tol=CONTACT_TOL * 4)

    The point is not a specific API but the engineering loop of parameters, derivation, constraints, and assertions. A model that proactively designs verification logic in its script shows not only that it can generate geometry but that it has some engineering self-checking awareness.

    4. Re-parameterization Testing: Where the Real Differences Appear

    Re-parameterization testing should be a core acceptance step. Suppose the wingspan changes from 1.15 to 1.35, the chainring from 44 to 52 teeth, and the crank phase from 35 to 140 degrees — numbers only, no code changes — then re-run the script and check at least the following:

    1. Handlebar width and grip positions
      Handlebar width should increase with wingspan, grip center distance should be recomputed, and the character’s forward-reaching extremities should still fall within the grip envelope. If grip positions are fixed, the re-run produces floating or intersecting hands.

    2. Chain path
      Changing the chainring tooth count changes the chainring radius and gear ratio, so chain length, tangent directions, wrap angles, and center-distance relationships must all be re-solved. A correct result is closed, tensioned, and free of clipping or suspended segments; a typical wrong result keeps drawing the chain at the old radius or misplaces the chain endpoints.

    3. Crank phase and foot contact
      After the phase changes from 35 to 140 degrees, the pedals should rotate to their new positions. The supporting foot must re-attach to the pedal surface, and the non-load-bearing foot should remain suspended in the low return position with a visible gap. If foot positions are hard-coded, you get feet through the pedals, floating feet, wrong left/right phase, or implausible leg lengths.

    4. Overall proportions and collisions
      Wingspan and wheelbase changes can introduce new collision relationships — for example, the character’s body against the frame, the handlebar against the body, the fishing net against the rear wheel, or the tool bag against the front wheel. Use minimum-distance or collision detection to confirm there is no obvious clipping.

    5. Determinism and repeatability
      Re-runs should be stable; geometry must not differ each time because of random perturbation. If random detail is used, fix the seed or use a reproducible pseudo-random sequence.

    5. Common Failure Modes

    Failure modes in this class of task are highly consistent:

    • Hard-coded dimensions — parameters exist on the surface, but the geometry still uses fixed values, so re-parameterization fails.
    • Parameter islands — wingspan affects only the character and not the handlebar; tooth count affects only the display and not the chain.
    • Broken assembly relationships — parts are generated independently with no shared coordinate system or dimension chain, producing floating, intersecting, or misaligned components.
    • Missing kinematics — no solving relationship among crank, pedals, and feet; they are merely “placed” at approximate positions.
    • Over-reliance on visual approximation — the render looks reasonable, but geometric distances and contact relationships violate the tolerance.
    • Non-executable or unstable — the script depends on external resources, manual operations, or undefined state and fails in batch runs.
    • Missing verification output — no logs, assertions, or check results, making failures hard to diagnose.
    • Stylization masking engineering problems — stylization is not the issue, but it cannot substitute for correct spatial relationships.

    6. Engineering Recommendations

    For developers who want to use this kind of evaluation for model selection or capability acceptance, build a standardized test set covering different complexity levels, constraint densities, and re-parameterization combinations. Run headless tasks in batch on a container platform, store scripts, run logs, check results, and optional renders in object storage, then use log services and monitoring alerts to locate failing samples. Score by weighted sub-items — semantic fidelity, parameter linkage, spatial and kinematic constraints, executability, and maintainability — keeping human review while maximizing automation.

    For model generation strategy, prioritize a single parameter source, derived computation, explicit constraints, automatic assertions, and diagnosable output. For complex scenes, generating a parameter table and assembly plan first, then geometry and pose-solving code, is usually more reliable than stacking geometry in one pass. For teams, what matters is not one good render but whether the script stays stable under parameter changes, batch execution, and automated acceptance.

    7. Conclusion

    Verifiable 3D script generation is a high-density综合 testbed — a high-density combined testbed. It compresses semantic understanding, spatial reasoning, code organization, kinematic constraints, and engineering verifiability into a single task. Judging a general-purpose model on this kind of task cannot rely on whether it produces a scene that “looks like” the target. What matters more is whether it preserves correct relationships after parameters change, whether it executes stably in a headless environment, and whether it can prove the result with assertions and logs. An evaluation method built around re-parameterization testing, automated acceptance, and maintainable scripts is better suited to objective comparison by developers and enterprise users, and it reflects more accurately how usable a model is in real creative-coding and 3D content production workflows.