Evaluating Open-Source AI Agents: Tool Use, Retrieval, and Benchmarking Pitfalls

    This article examines how open-source models perform when equipped with tools versus when forced to rely on pure reasoning. Using a "fridge meal planning" test case and a math benchmark score gap, it breaks agent capability into four layers, outlines a reproducible evaluation harness design, lists common scoring pitfalls, and discusses a neutral selection path for production deployment.

    1. Background: What a “Fridge Meal Planning” Test Reveals

    On the day a cloud vendor published a technical report for an open-source model, it ran a set of hands-on tests. One scenario was especially telling: the tester uploaded a photo of a fully packed fridge and asked the model to plan nine meals for a family of three over the next three days, with two extra constraints—no more than 100 units of additional grocery spending, and no more than 40 minutes of cooking per meal.

    The model’s execution path was informative. It first zoomed into regions of the photo and inventoried them layer by layer, identifying tomatoes, cucumbers, zucchini, frozen mixed vegetables, bread, and condiments, while estimating quantities. A few items were uncertain: a pink vacuum-sealed package on the middle-left shelf could be chicken, pork chops, ham, or fish; a large white container on the right door could be yogurt, cream, or cheese sauce. The model explicitly flagged these four uncertainties as “to be confirmed” and handled those ingredients conservatively in the menu that followed. It then produced a shopping list and a three-day menu. The tester added a twist: two extra guests would join on the second evening—one vegetarian, one with a peanut allergy—with the budget unchanged and the third day unaffected. The model recalculated inventory, rearranged allocations, and provided an anti-waste fallback plan.

    The same report contained another number: on a set of difficult math problems, the model scored 13.0, while a leading closed-source frontier model scored 97.5. Placing the two results side by side clarifies the report’s real message: these models are trained to be agents that are good at getting work done and using tools. Once the tools are removed and the model must rely solely on its own reasoning, a clear gap remains compared with closed-source frontier models. This article unpacks what that gap is, how to quantify it, and whether the quantification method itself is biased.

    2. Terminology: Agents, Tools, and Harnesses

    Before diving in, let’s pin down the terms to avoid ambiguity later.

    • Agent: the full sequence of actions a model takes within an environment. For example, if you only say “fix the bug where login expiration throws an error in the repository,” the model must open a terminal, inspect directories, read code, modify files, run tests, read errors, modify again, and rerun until all tests pass or time runs out.
    • Tools: the external capabilities the agent calls during that sequence—terminal, editor, retrieval, browser, and so on.
    • Harness (or scaffold): the external program that defines the available tool set, maximum number of steps, per-step time limit, failure criteria, and final scoring rules.

    These three form a closed loop: the harness defines the “exam rules,” tools determine “how far the hand can reach,” and the agent is responsible for “using the hand well within the rules.” Evaluation conclusions are highly sensitive to all three—swap the harness and scores can shift across the board.

    3. Capability Layers: Separating “Getting Work Done” from “Thinking”

    The comparison above reveals a commonly conflated fact: end-to-end task success rate and pure reasoning ability are not the same dimension. It helps to split capability into four layers and measure each separately.

    1. Perception and grounding: Can the model reliably extract structured facts from images, documents, and logs, and explicitly flag uncertain items?
    2. Tool orchestration: Can it maintain state such as inventory, budget, and dietary restrictions without loss over dozens of steps, and correctly choose actions like zoom, crop, retrieval, and calculation?
    3. Long-horizon consistency: After multiple rounds of added constraints, can it perform incremental recalculation rather than starting over or silently violating earlier constraints?
    4. Pure reasoning without tools: What is the upper limit of independent mathematical and logical derivation when external capabilities are disabled?

    The fridge case mainly covers the first two layers; the math problem set only tests the fourth. Using a single-layer score to infer overall capability is one of the most common misjudgments in model selection.

    4. Designing a Reproducible Evaluation

    For conclusions to be credible, the evaluation must be reproducible. A minimal viable harness should include the following elements:

    1. task:
    2. input: image + natural_language_constraints
    3. constraints:
    4. budget: 100
    5. max_minutes_per_meal: 40
    6. guests_delta: {day: 2, vegetarian: 1, peanut_allergy: 1}
    7. harness:
    8. tools: [image_zoom, crop, calculator, inventory_db]
    9. max_steps: 60
    10. step_timeout_ms: 8000
    11. failure_policy: hard_fail_on_constraint_violation
    12. scoring:
    13. constraint_satisfaction: 0.4
    14. plan_quality: 0.3
    15. uncertainty_reporting: 0.2
    16. cost_efficiency: 0.1

    Three design points matter. First, constraints must be machine-verifiable—budget and time limits should be judged by a program, not by human eyeballing. Second, uncertain items should be scored separately, encouraging the model to say “I’m not sure” rather than fabricate. Third, an ablation group is mandatory: running the same task with tools enabled and disabled is the only way to separate “tool gain” from “model intrinsic capability.”

    5. Metric Definitions and Common Pitfalls

    • Definition drift: Different harnesses have different step limits, timeouts, and retry policies, so scores are not directly comparable.
    • Prompt leakage: Writing reference answers or evaluation samples into the system prompt significantly inflates scores.
    • Lenient scoring: Judging only the final answer without checking intermediate constraints lets most real defects slip through.
    • Single-point sampling: A single run has high variance; fix the random seed and repeat multiple times, reporting mean and confidence intervals.
    • Tool compensation: The stronger the tools, the more easily they mask reasoning weaknesses, so a no-tool control group must be retained.

    6. Engineering Practice: A Neutral Selection Path on Baidu AI Cloud

    To bring this kind of capability into production, follow three principles: observable, rollback-capable, and evaluable. On the model serving side, focus on inference throughput and concurrency. On the tool side, use a container platform to host sandboxed execution, object storage to persist intermediate artifacts, and a message queue to decouple tasks. On the observability side, connect logging and monitoring/alerting services, and keep a trace for every tool call. The evaluation pipeline should be a standing capability—any change to the model or the harness should trigger a regression run.

    When selecting, don’t rely on a single leaderboard. Look at three things: end-to-end success rate on the target task, constraint violation rate, and cost per task. For high-risk scenarios, keep a human confirmation step and expose uncertain items explicitly to the user—this is often more valuable than pursuing a higher automation rate.

    7. Conclusion

    What makes that technical report worth reading is not any single score, but the evaluation paradigm it inadvertently offers: measure “seeable, callable, memorable” separately from “deep thinking.” The engineering takeaway is straightforward—first fix the rules with a harness, then use ablation experiments to isolate tool gain, and finally build an auditable capability profile using verifiable constraints and uncertainty reporting.