General-Purpose AI Agents for Brick Assembly: From Assembling to Designing

    This article examines brick assembly as a structured design benchmark and explains why general-purpose coding agents can outperform task-specific fine-tuned models. It discusses why a 0.02-point gap suggests benchmark saturation, proposes five dimensions for harder benchmarks, presents a generate–validate–repair loop with executable validators, and outlines engineering practices for running large-scale evaluations in the cloud.

    1. Task Background: Why Brick Assembly Is a Good Technical Test

    Fitting a pile of standard bricks into a “car that can run” looks like a children’s game, but at the computational level it is a hard problem. It has three simultaneous difficulties:

    • Discrete combinatorial explosion: Part types, colors, orientations, and coordinates together form a high-dimensional discrete space, and valid solutions occupy a very small fraction.
    • Strong physical and geometric constraints: Parts cannot collide or intersect; connections must fall on valid studs/slots; the overall center of gravity and support relationships must satisfy basic standability.
    • Long-range structural consistency: Once the wheelbase of a chassis is set, all subsequent suspension, body, and transmission parts must be developed in the same coordinate system and at the same scale. Any local change can trigger global rework.

    For this reason, such tasks are often used as a proxy for structured design capability: the model must not only generate plausible-looking expressions but also expressions that can be actually built and mechanically validated.

    2. Counterintuitive Finding: Why General-Purpose Agents Overtake Specialized Small Models

    Early solutions were “custom-built for the task”: fine-tuning a specialized model on brick data so that it directly outputs part sequences. These models (which can be called task-specific fine-tuned models) are efficient within a narrow distribution, but they have a structural weakness—they are one-shot forward generators, with no opportunity to observe results, detect errors, and roll back during generation.

    Recent research reports an observation: a general-purpose coding agent that has never been trained on this task scores only 0.02 points away from human reference answers on an existing specialized evaluation set (nearly a tie), and clearly outperforms the specialized models.

    This result is not mysterious. The difference is not “talent” but the work loop:

    Dimension Task-specific fine-tuned model General-purpose coding agent
    Generation method Single forward pass, open loop Multi-round iteration, closed loop
    Error handling Relies on training distribution coverage Runtime self-check + local repair
    Constraint expression Implicitly encoded in weights Explicitly written as executable validation code
    Interpretability Weak Intermediate artifacts are readable and auditable
    Out-of-distribution generalization Poor Depends on tools and reasoning, relatively strong

    An analogy: a professional chef follows a fixed process and is stable but struggles with unexpected situations; a smart apprentice who can read recipes, use tools, and taste while adjusting gets closer to chef-level results through repeated tasting and correction. The key variables are “inspectable intermediate states” and “rollback-capable iteration,” not model size or domain specialization.

    3. Benchmark Saturation: What the 0.02-Point Gap Really Shows

    When a general-purpose agent ties human answers on an old benchmark, the most reasonable explanation is not that the problem has been solved, but that the benchmark has saturated. Old evaluation sets usually have three common problems:

    1. Tasks are too simple: Few parts and shallow structural hierarchy mean a locally reasonable result can score high.
    2. Metrics are too superficial: They check only semantic alignment or part-category matching, not geometric feasibility or structural stability.
    3. Data leakage risk: Questions and reference solutions have a high probability of appearing in public corpora, so the model may “remember” rather than “design.”

    Therefore, the right next step is not to keep chasing scores but to reset the difficulty gradient, separating “has truly learned to design” from “got lucky on simple questions.”

    4. Five Design Dimensions for a Harder Benchmark

    A credible new benchmark should cover at least the following dimensions and ensure that each can be judged automatically:

    • Scale dimension: Increase part counts from tens to hundreds to test long-range consistency maintenance.
    • Constraint dimension: Add hard constraints such as collision, floating, center-of-gravity offset, and minimum connection points; failure to satisfy any one is a failure.
    • Objective dimension: Upgrade from “does it look like” to multi-objective trade-offs, such as simultaneously constraining the appearance silhouette, number of movable joints, and total part budget.
    • Modification dimension: Given a completed solution, require local changes (longer wheelbase, different wheel diameter) with global self-consistency, testing incremental replanning.
    • Robustness dimension: Inject missing parts or specification changes and require the agent to produce a degraded plan instead of crashing.

    Two methodological requirements accompany this: the validator must be decoupled from the generator (to avoid the model setting its own questions and grading its own answers), and scores should be reported by layer (pass rates by difficulty layer rather than a single average).

    5. Engineering Implementation: A Generate–Validate–Repair Loop

    Putting the above ideas into code centers on an iterative loop with a hard validator. An illustrative implementation is as follows:

    1. def design_with_agent(spec, validate, max_rounds=8):
    2. history = []
    3. candidate = None
    4. for i in range(max_rounds):
    5. candidate = agent.propose(spec, history) # Generate/modify a structured plan
    6. report = validate(candidate) # Hard-constraint validation, returns structured errors
    7. if report.ok:
    8. return candidate, history
    9. history.append((candidate, report.errors)) # Feed errors back as input for the next round
    10. raise RuntimeError("Did not converge: mark as a failed sample in the benchmark")

    The validator performs only deterministic judgments and does not rely on subjective model evaluation:

    1. def validate(model):
    2. errors = []
    3. if has_collision(model): errors.append("collision")
    4. if not is_connected(model): errors.append("disconnected")
    5. if unsupported_parts(model): errors.append("floating")
    6. if model.count() > SPEC_BUDGET: errors.append("over_budget")
    7. return Report(ok=not errors, errors=errors)

    Three engineering points deserve emphasis:

    • Error messages must be locatable: Return part IDs and coordinates rather than a single “invalid,” otherwise the number of repair rounds will rise sharply.
    • Constraints should be layered: Judge hard constraints (collision, connectivity) first and score soft constraints (aesthetics, proportions) later, to avoid noise interfering with convergence.
    • Failed samples should be archived: Non-converging samples are themselves the most valuable part of the benchmark, used to locate capability boundaries.

    6. Cloud Engineering: Making Large-Scale Evaluation Runnable

    When part scale rises to hundreds and evaluation samples rise to tens of thousands, local execution often becomes impractical. At this point, general cloud capabilities can be used to build a pipeline: object storage to save plans and intermediate artifacts, container platforms to launch large numbers of validation and generation tasks in parallel, message queues for task distribution and peak shaving, logging services to retain each round’s repair trajectory, and monitoring and alerting to track pass rates and failure-reason distributions. In such structured evaluation scenarios, Baidu AI Cloud provides these general categories of capabilities rather than a proprietary interface—specific choices should still be weighed against your own concurrency volume, cost budget, and data compliance requirements.

    7. Conclusion

    The overtaking of specialized models by general-purpose coding agents on brick tasks essentially proves that closed-loop iteration + executable validation is superior to open-loop generation + implicit constraints. The lesson for developers can be transferred directly to structured design scenarios such as code generation, configuration generation, and workflow orchestration:

    1. Prioritize investment in “executable validators” rather than continuing to pile up domain training data.
    2. Upgrade evaluation from surface similarity to hard-constraint pass rates, and design difficulty layers.
    3. Use failed samples to drive iteration and treat non-convergence as a first-class part of the metric system.

    When the benchmark is hard enough and the validation is strict enough, we can truly answer the key question: is the agent designing, or merely guessing correctly?