Evaluating and Selecting LLM Agents in the Post-Training Era

    A practical guide to evaluating and selecting large language model agents after the post-training era, covering benchmark saturation, building internal evaluation suites, cost per successful task, and model-agnostic engineering integration.

    1. The Problem: Why Benchmarks Diverge from Real-World Experience After a Stable API Launch

    After a major model’s stable API was released, community discussion focused on two questions: whether its agent capabilities had improved significantly, and whether it could approach leading closed-source models on long-horizon coding tasks. Shortly afterward, however, the discussion faded. The reason was not that the base model had become weaker, but that a systematic gap had emerged between evaluation results and actual usage experience.

    This kind of gap is common in engineering practice and usually comes from three layers:

    • Benchmark saturation: The code-repair benchmarks widely used early on are nearing their ceiling, compressing score differences among top models into the noise range.
    • Changing task shapes: Real development is a long chain of “read the codebase, locate the issue, make multiple rounds of edits, run and verify,” while most older benchmarks are single-turn, single-file, and short-context.
    • Training objective mismatch: A model may complete reinforcement learning on its own platform, where the reward signal is inconsistent with external toolchains, directory structures, and dependency management approaches.

    The conclusion up front: leaderboard rankings can only serve as an initial screening signal, not as a selection criterion. What truly determines real-world results is whether the post-training stage is isomorphic with your engineering environment.

    2. Rebuilding the Evaluation System: What Makes a Benchmark Trustworthy

    2.1 Four Characteristics of a Trustworthy Benchmark

    • Contamination control: Tasks and solutions do not enter public corpora; use time-based splits or a private holdout.
    • Long horizon: A single task allows more than ten tool calls, testing planning, backtracking, and self-verification.
    • Realistic environment: Includes a complete feedback loop with dependency installation, test execution, and log reading.
    • Reproducibility: Fixed container images and dependency versions, with quantifiable result variance.

    2.2 A Minimal Approach to Building an Internal Benchmark

    External leaderboards are only useful for horizontal comparison; vertical decisions must rely on your own evaluation set. Organize it by “task family + difficulty tier + checker script”:

    1. # Internal evaluation suite structure example
    2. suite: repo_agent_eval
    3. tasks:
    4. - id: bugfix_001
    5. family: bugfix
    6. difficulty: L2
    7. setup: {image: base-2026, deps_lock: true}
    8. checker: pytest -q tests/test_regression.py
    9. budget: {max_steps: 40, max_tokens: 400000}
    10. - id: refactor_007
    11. family: refactor
    12. difficulty: L3
    13. checker: lint && pytest -q
    14. budget: {max_steps: 60, max_tokens: 800000}
    15. metrics: [pass_rate, avg_steps, token_cost, wall_time, retry_rate]

    The key metrics should not be pass rate alone. Average steps, retry rate, and cost per task also matter, because these three directly determine your production bill and response latency.

    3. Why the Relationship Between Parameter Scale and Capability Is Weakening

    The simple rule that “bigger is stronger” is failing because the structure of capability sources has changed:

    1. Pre-training determines breadth of knowledge and the language foundation, with diminishing marginal returns.
    2. Post-training (supervised fine-tuning + reinforcement learning + tool-use training) determines task success rate and is the main source of current gains.
    3. Architectural efficiency determines usable capacity under the same compute, such as sparsification, attention optimization, and inference cache design.

    As a result, a typical situation arises: a model with a smart base and excellent architecture can still show a clear drop in general-purpose performance in external environments if its post-training stage uses a single reward signal and a proprietary tool interface. The engineering response is not to switch models, but to fill in an “environment adaptation layer.”

    4. Cost and Value: Breaking the Bill into Accountable Items

    Value for money does not mean a low unit price; it should be converted into “total cost per successful task”:

    1. cost_per_success = (input_tokens * p_in + output_tokens * p_out
    2. + tool_calls * p_tool + retries * retry_overhead)
    3. / successful_tasks

    Optimization paths, ordered by payoff:

    • Context governance: Inject retrieval on demand instead of stuffing in the entire repository; summarize and compress prior turns.
    • Cache reuse: Enable caching for stable prefixes (system prompts, repository conventions) to reduce repeated billing.
    • Tiered routing: Send simple tasks to smaller models and escalate complex refactoring to larger models.
    • Budget guardrails: Set step and token limits, and fall back to a human when exceeded, so long-tail tasks do not consume the budget.

    5. Engineering Integration: Bringing General Capabilities into Your Repository

    • Standardize the tool layer: Unify the interfaces for reading and writing files, running tests, and retrieving symbols, independent of the model.
    • Close the feedback loop: Return compilation errors, test failures, and static-analysis output in a structured form to improve the self-correction rate.
    • Observability: Connect logging services and monitoring alerts, and build dashboards for success rate, latency, and the distribution of failure causes.
    • Elastic capacity: Deploy inference services in containers, with auto-scaling and message queues to smooth peaks.
    • Data security: Access sensitive code over a private network, manage credentials through a key management capability, and never write them into prompts.

    6. Deployment Checklist

    • Have you built a private holdout evaluation set and cross-validated it against external leaderboards?
    • Have you tracked cost per successful task rather than only comparing unit prices?
    • Have you implemented a model-agnostic tool abstraction layer for easy horizontal replacement?
    • Have you set guardrails for steps, tokens, and timeouts?
    • Do you have a mechanism to feed failed samples back into post-training data and prompt iteration?

    7. Conclusion

    We have entered a stage where post-training sets the ceiling: architecture and parameters provide the starting point, while post-training and the tool ecosystem determine the endpoint. For developers, the rational approach is to use your own real tasks as the yardstick, and to replace the pursuit of a single leaderboard ranking with reproducible evaluation, accountable cost, and a model-agnostic engineering architecture. If you need managed hosting, you can build an evaluation and inference pipeline on general capabilities such as the container platform, object storage, logging service, and monitoring alerts offered by Baidu AI Cloud, keeping model selection neutral and portable.