3D Scene Evaluation: From Code Generation to Spatial Reasoning

    Evaluating AI-generated 3D scenes requires more than checking whether code runs or a render looks convincing. This guide uses a pelican riding a bicycle to explain how to assess geometric constraints, contact relationships, parameter dependencies, and motion consistency. It also outlines parameter perturbation tests and a reproducible validation workflow that separates visual quality from verifiable spatial reasoning.

    1. Evaluating Generative Models Beyond Task Completion

    As generative models take on creative coding, 3D scene construction, and animation tasks, evaluation must move beyond fluent responses to ask whether generated results can be executed, explained, and verified.

    A script may run successfully and render a seemingly complete scene without demonstrating an understanding of spatial relationships. A bicycle chain might pass through the frame, a character’s foot might hover above a pedal, or a wingtip might appear to touch a handlebar only from one camera angle. Changing the viewpoint, dimensions, or motion phase can expose these problems.

    Evaluation should therefore distinguish at least four levels:

    1. Code completeness: Is the deliverable complete, and can it execute automatically in the specified environment?
    2. Visual quality: Do composition, materials, lighting, and shapes meet the task requirements?
    3. Spatial correctness: Are relative positions, connections, and contact relationships valid?
    4. Parametric and dynamic consistency: Do the constraints remain valid when input parameters change or time advances?

    These levels are not interchangeable. A visually impressive result may contain obvious mechanical errors, while a simple-looking scene may have a more reliable parametric structure. Professional evaluation should record them separately rather than combine them into a single subjective score.

    2. Why a Pelican Riding a Bicycle Is a Useful Spatial Reasoning Task

    The value of this scene lies not in its unusual subject but in its combination of semantic interpretation, geometric construction, mechanical constraints, and character posing.

    The scene can be summarized as follows: at dusk on a coastal path, a forward-leaning pelican rides a steel-frame bicycle. Both wings reach toward the handlebars. One webbed foot contacts a pedal while the other is in a recovery phase. A tool bag hangs from the frame, and a fishing net is secured to the rear rack. The drivetrain and riding pose must be mutually consistent.

    These requirements fall into three categories.

    Visual Narrative

    Dusk, the coastline, the tool bag, the fishing net, and the forward-leaning pose establish the scene’s story. These elements allow artistic interpretation and do not require photorealism.

    However, stylization does not justify structural errors. The tool bag needs a plausible mounting location, the fishing net must sit within the rack’s support area, and the character’s body should not visibly intersect the frame.

    Geometric Structure

    The wheels, frame, handlebars, cranks, and pedals have defined spatial relationships. A classic diamond frame is not an arbitrary collection of line segments; it is a system of nodes and members with a specific topology.

    This layer tests whether a model can translate a written description into an organized geometric system.

    Mechanisms and Contact

    The chain must follow a plausible path around the front and rear drivetrain components. Pedal positions must change with crank phase, and the foot must adjust its position and orientation to follow its target pedal.

    This layer most clearly distinguishes assembling a picture from building a computational scene. It requires dependencies between objects, not merely the independent generation of each object.

    3. Convert Natural Language into a Constraint Checklist

    Passing a long prompt directly to a model can produce a visually complete scene with missing constraints. A more reliable approach is to break the requirements into verifiable items first.

    Scene requirement Modeling constraint Validation method
    Both wings hold the handlebars Wingtip endpoints correspond to grip target positions Check positional error and local orientation
    One webbed foot rests on a pedal The foot’s contact surface satisfies the required relationship with the pedal surface Check gaps, penetration, and projected overlap
    The chain is taut The chain path is derived from drivetrain dimensions and center positions Check path continuity and wrapping geometry
    The tool bag hangs from the down tube Mounting points are derived from down-tube geometry Check whether the attachment follows frame changes
    The fishing net is tied to the rear rack Net placement is defined in the rack’s local coordinates Check support and attachment relationships
    The scene remains correct after parameter changes Geometry and pose share a consistent source of parameters Regenerate and validate multiple parameter sets

    Contact does not simply mean that two object centers are close together. Foot–pedal contact also depends on surface orientation, coverage, and penetration depth. A wingtip gripping a handlebar must likewise have a reasonable relationship to the grip’s direction.

    Ambiguous natural-language requirements also need to be resolved before modeling.

    For example, in a conventional crank assembly with the left and right cranks half a revolution apart, both pedal positions are determined by the same phase. Requiring arbitrary crank-phase changes while also requiring the opposite pedal to remain at its lowest point creates a contradiction.

    The specification should clarify whether a “low recovery position” describes the initial pose or an artistic motion of the raised foot, rather than the position of the opposite pedal. Mechanical structure should not be broken merely to satisfy the wording superficially.

    4. Parametric Modeling Is About Dependencies, Not Variable Counts

    Placing a few constants at the top of a script is only the beginning of parametric modeling. If objects still use independent, fixed coordinates, those constants are largely decorative.

    For this scene, task inputs might include:

    • Wingspan: 1.15 m
    • Wheelbase: 1.02 m
    • Front chainring: 44 teeth
    • Rear sprocket: 16 teeth
    • Initial crank phase: 35 degrees

    These values are scene inputs, not API parameters for a tool or service. Wheel diameter, crank length, chain pitch, frame proportions, and character segment lengths also need explicit design parameters or proportional factors.

    The important step is establishing dependency chains:

    1. Wingspan
    2. → Handlebar grip spacing
    3. → Left and right grip targets
    4. → Wingtip targets
    5. → Wing joint poses
    6. Wheelbase and frame proportions
    7. → Wheel axles and frame nodes
    8. → Bottom bracket and seat positions
    9. → Rack and accessory mounting points
    10. Chainring tooth count, sprocket tooth count, and chain pitch
    11. → Drivetrain pitch-circle dimensions
    12. → Chain tangent points and wrapping path
    13. Crank phase
    14. → Left and right pedal positions
    15. → Foot contact targets
    16. → Leg poses

    Proportional factors do not need to disappear, but they should be named, meaningful, and traceable. Rather than requiring a script to contain no numeric literals, evaluation should require that critical dimensions have no hidden constants outside the parameter system.

    5. Use Consistent Coordinate Systems

    A common failure in complex scenes is that individual parts look reasonable but have inconsistent orientations when assembled.

    Define a coordinate convention in advance:

    • One horizontal axis represents forward motion.
    • The other horizontal axis represents the bicycle’s left–right direction.
    • The vertical axis represents height.
    • The rear axle center or bottom bracket center serves as the main reference origin.

    Then define local coordinate systems for each subsystem. Pedals move relative to the cranks, and cranks move relative to the bottom bracket. The tool bag is mounted relative to the down tube, and the fishing net is positioned relative to the rack.

    These parent–child relationships reduce errors such as accessories staying in place when the wheelbase changes. An accessory should depend on its parent component’s local position and transform, not on isolated world coordinates.

    Generation order should also follow the dependency structure: establish the axles and frame first, then the drivetrain, then solve the character pose, and finally generate accessories and the environment.

    6. Generate the Chain from Geometry, Not Decoration

    The chain is an important test of spatial reasoning. A common weak implementation draws a fixed ellipse between the chainring and rear sprocket. It may look plausible from one viewpoint, but changing the chainring size often causes the chain to intersect or detach from the gears.

    For a simplified coplanar drivetrain, pitch circles can approximate the chain path.

    Given chain pitch (p) and tooth count (N), the ideal sprocket pitch radius is:

    [
    r = \frac{p}{2\sin(\pi/N)}
    ]

    This radius follows from the chord length between adjacent chain-pin positions. It is not the radius of the outer tooth-tip profile.

    Let the front and rear pitch radii be (R) and (r), with center distance (d). An external common-tangent approximation first requires:

    [
    d > |R-r|
    ]

    The tangent points can then be calculated, and two straight segments joined with two wrapping arcs to form a continuous path. Geometric validity does not guarantee that the complete mechanism can be assembled; clearances between components still need checking.

    This approach is suitable for visual modeling, but it is not a complete mechanical simulation. Real chains involve discrete links, tooth engagement, and polygonal effects. If the task requires accurate engagement of individual links, link count, closure conditions, and correspondence with tooth positions must also be handled.

    Total chain length is another easily overlooked constraint. Increasing the chainring size while keeping the center distance fixed generally changes the required path length:

    • If the task permits redesigning the chain, a new link count can be selected.
    • If chain length must remain fixed, the rear wheel position must be adjusted or a tensioning mechanism introduced.
    • If neither change is allowed, arbitrary parameter combinations cannot be guaranteed to work.

    Recognizing these feasibility limits is stronger evidence of reasoning than simply generating a curve that looks taut.

    7. Drive Character Poses with Contact Targets

    The pelican’s webbed foot should not be placed using fixed world coordinates. Its position must be derived from the current pedal position.

    Let the bottom bracket center be (C), crank length be (l), and crank angle be (\theta). The pedal’s two coordinate components in the rotation plane are determined by (l\cos\theta) and (l\sin\theta), relative to (C). The opposite pedal uses a phase offset of half a revolution, together with the appropriate lateral mounting offset.

    Once the pedal target is known, the leg pose can be solved. For a simplified two-segment joint chain, the target distance must fall within the reachable range determined by the segment lengths. If the target is outside that range, the system should report an unsatisfied constraint or adjust the body position according to a predefined rule—not stretch the limb indefinitely.

    The wings should follow the same target-driven approach:

    1. Calculate reasonable grip spacing from the wingspan.
    2. Extract left and right grip targets from the handlebar geometry.
    3. Solve wing poses within the allowed joint ranges.
    4. Check wingtip contact and intersections with the body or frame.

    Contact validation should cover at least position, orientation, and penetration. Tolerances should reflect scene units, object sizes, and intended use, and should be documented in the report. A single fixed tolerance is not an adequate quality standard for every scene.

    8. Parameter Perturbation Tests Are More Convincing Than a Single Render

    To evaluate parametric capability, change the inputs without editing the generation code.

    For example, increase the wingspan from 1.15 m to 1.35 m, change the front chainring from 44 to 52 teeth, and change the crank phase from 35 to 140 degrees. Then regenerate the scene.

    The goal is not primarily to compare how attractive the two renders are. Instead, check whether:

    • Handlebar width updates according to the defined rule.
    • Wingtips still correspond to the grips.
    • The chain is recalculated from the new pitch circles.
    • The webbed foot follows its updated pedal target.
    • The character pose remains reachable.
    • The tool bag, fishing net, and other accessories remain correctly mounted.

    Tests should include both single-parameter changes and combined changes. Single-parameter tests help locate missing dependencies; combined tests reveal coupling problems.

    Boundary tests are also necessary—for example, smaller wingspans, longer wheelbases, and crank angles near pose limits. A strong implementation should succeed for valid inputs and provide clear diagnostics for infeasible ones rather than silently producing invalid geometry.

    9. Validate Static Scenes and Dynamic Video Separately

    A static scene establishes spatial relationships at one instant. It does not establish correct motion over time.

    Evaluating code-driven video generation requires a time variable and checks for consistency across consecutive frames. In an idealized chain drive without slip, the rear sprocket’s angular speed relative to crank angular speed is the front chainring tooth count divided by the rear sprocket tooth count. Whether the rear wheel rotates in step also depends on whether the drivetrain is engaged; coasting cannot be ignored.

    Dynamic validation should examine:

    • Whether the foot maintains the specified contact state during motion.
    • Whether chain motion is consistent with sprocket rotation.
    • Whether rear-wheel angular speed matches the adopted drivetrain assumptions.
    • Whether wheel rolling matches ground-relative motion when the bicycle translates.
    • Whether joint poses remain smooth without sudden flips.
    • Whether accessories retain stable local attachment relationships across frames.

    Rotating the wheels without linking the cranks, chain, and character motion produces a partial animation, not a complete cycling system.

    10. Establish a Reproducible Validation Workflow

    Professional evaluation should deliver both the scene and evidence of its validity. A practical workflow is:

    Validate inputs → Generate geometry → Solve constraints → Run automated checks → Render multiple views → Produce a report

    Automated checks detect excessive distances, obvious penetration, open paths, unreachable targets, and missing objects. Multi-view renders support judgments about composition, naturalness of pose, and narrative quality. Neither can replace the other.

    The runtime environment should also be fixed, including scene units, execution method, dependencies, and output directory. Scripts should support headless execution and provide explicit failure messages. If a result has not actually been run, it should be marked as unverified rather than declared successful based on code inspection alone.

    The final report need not reduce everything to one score. Separate records for code completeness, spatial constraints, parameter robustness, dynamic consistency, and visual quality better explain failures and guide improvements.

    Conclusion: Evaluate Verifiable Relationships

    The most important feature of a 3D generation task is not the polish of a single image. It is whether a model can translate natural-language requirements into structured constraints and implement them in a scene that can be executed, modified, and checked.

    When wingspan changes, the grips and wings should update together. When chainring size changes, the chain path should be solved again. When crank phase changes, foot contact should remain valid. When inputs are infeasible, the system should explain why. These behaviors provide stronger evidence of spatial reasoning.

    For developers, the most useful evaluation sequence is to define constraints before generating the scene, verify relationships before judging appearance, and test parameter changes before discussing capability limits. That is how creative coding can move from a one-off demonstration toward maintainable engineering practice.