Agent-Built Tools and Long-Horizon Decision-Making: A Reproducible Evaluation Framework

    This article examines what makes agent evaluation genuinely difficult in complex, turn-based environments with incomplete information and delayed feedback. It covers how to design fair and comparable experiments, how agents should build their own tools within enforced constraints rather than bypassing them, how to combine memory, visual, and event observations to avoid blind spots, and how to structure long-horizon adversarial strategies. It concludes with a practical, auditable workflow for building repeatable long-range decision-making capability in both game benchmarks and enterprise scenarios such as ticket handling, equipment inspection, and multi-step approvals.

    For agents operating in complex environments, the real challenge is not single-step actions. It is forming verifiable judgments over time under incomplete information, opaque rules, and long-delayed feedback. A common public benchmark setup places an agent inside the same turn-based role-playing environment: the goal is broken into a chain of milestones, and the endgame contains hidden challenges significantly stronger than regular opponents. The prompt does not ask the agent to “finish the game as fast as possible,” but to act like a scientist: treat external walkthroughs as unverified claims, and record hypotheses, experiments, and progress in an unstructured notepad. The competition is therefore not about memorization, but about who can adapt to the environment and build their own workflow.

    First, Make the Benchmark a Comparable Experiment

    A fair comparison requires locking down at least four things.

    1. Identical environment: the same simulator version, the same initial state, and the same randomness control strategy—so one agent does not enjoy looser frame synchronization while another suffers frequent desyncs.
    2. Identical observations: memory reads, screen frames, and text logs must be provided simultaneously; otherwise you cannot attribute “understanding the screen” to the model itself.
    3. Identical action interface: allowed keys, timing, and failure retries must be enforced in the execution layer, not merely stated in the prompt.
    4. Identical resources: token budgets, decision turns, and wall-clock time must be accounted separately. The number of completed milestones only shows progress; tokens and turns reveal the cost. Reporting only “faster” without reporting how many observations and failed attempts were spent makes the conclusion unreproducible.

    The notepad should be treated as an experimental log, not another hidden prompt. Good records include: the current goal, hypotheses already ruled out, whether supporting evidence comes from memory or the screen, the next minimal experiment to run, and a rollback point after failure. An agent may spawn sub-processes dedicated to logging, pathfinding, or battle review—but every sub-process’s inputs and outputs must be traceable back to the main record. Otherwise, late in a long task you get “the notepad has conclusions the environment cannot corroborate”—self-confirmation.

    After Failure, Re-estimate the Environment Before Rewriting Actions

    A mature agent’s trust in its tools is conditional. When an action fails, the first response should not be to retry the same call in a loop, but to distinguish three causes: the interface was used incorrectly; the environment state changed; or the constraint itself is stricter than documented. Only the third, confirmed repeatedly by evidence, justifies promoting a repeated action into a new tool.

    One typical constraint is input shaping: to prevent simulator desynchronization, the execution layer forbids mixing multiple direction keys and a confirm key in a single submission. Tasks like naming characters or menu navigation become turn-expensive when only one key press is allowed per submission—but this does not mean the prompt can declare the “limit invalid.” The proper approach is to provide an “action sequence” abstraction in a controlled executor: the sequence still consists of the same legal keys, the executor dispatches them one by one at a fixed cadence, and checks after each step whether the simulator remains in sync. The agent writes a sequence description; it does not get a driver that bypasses validation. If a custom tool can send mixed inputs directly into the simulator while the main interface cannot, the constraint exists only on the facade, and the evaluation is already distorted. Environment rules should be invariants of the executor, not suggestions the model is trusted to follow.

    Therefore, self-built tools must pass three gates:

    1. Capability declaration: what the tool can and cannot do, with explicit parameter ranges.
    2. Policy validation: before execution, a sandbox checks the allowed key set, maximum sequence length, and frame intervals.
    3. Audit: every call logs the input, rejection reason, and simulator validation result.

    Treating constraints as an engineering problem means improving batching efficiency within the boundaries. Removing validation from the execution layer only measures exploit-finding, not decision-making.

    An illustrative action description can be deliberately narrow—for example, accepting only direction and confirm enums, with the runtime splitting steps:

    1. sequence:
    2. - {key: down, repeat: 1}
    3. - {key: confirm, repeat: 1}
    4. policy:
    5. max_steps: 32
    6. inter_key_frames: 2
    7. reject_chords: true

    There are no mixed key presses here, and no direct memory writes. The agent gains fewer decision turns; the evaluators retain synchronization and traceability.

    Memory Is Not the Whole World

    Many games store character coordinates, party data, and switch variables in memory, but intermediate states of physics puzzles may have no clean fields. For example, a puzzle may require pushing a block from a higher floor to a lower one, then forming a path across hazardous ground. Memory may only contain a boolean for “mechanism completed,” with no record of which cell the block currently occupies. Reading only memory, an agent may mistake a leftover decoy object for the target and loop forever in the same room.

    Observation should therefore be split into three layers:

    • Memory layer: good for scoring, party state, and known switches—cheap to query, structurally stable.
    • Screen/spatial layer: good for answering “is there a pushable object on this cell” or “is the path continuous.”
    • Event layer: records before/after differences of recent interactions, revealing state changes memory does not expose.

    When the layers conflict, do not default to memory-first or screen-first. Run a minimal intervention experiment: push one object and see which layer shows a physically consistent change. The loop-exit condition should be written into the notepad: if the same observation repeats past a threshold, force a switch of observation source or a change of experiment—do not walk the old path again.

    This is where multimodality earns its value. It is not “one more image”; it fills blind spots left by structured state. Engineering must control costs: only increase the screen sampling rate when a memory hypothesis has been falsified, or when a puzzle involves spatial relationships; otherwise stay with compact state to keep long-horizon tasks from being dragged down by visual tokens.

    Long-Horizon Combat Is Strategy Composition, Not a Single Trick

    Against opponents with clearly superior stats, a single high-damage burst is rarely sustainable. The safer approach is to decompose combat into repeatable sub-goals: maintain your own sustain, suppress the opponent’s key ability, drain resources with low-cost actions, and return to the field under established rules after being knocked down. Each loop needs a stopping condition. Sustain is not unlimited healing; it means the next round of attrition remains executable. Suppression is not stacking every debuff; it means removing the one capability the opponent depends on most. A revival loop must account for turn losses, so you do not burn healing resources just to “get back on the field.”

    This style of play takes time, so evaluation cannot look only at win/loss. Record simultaneously: the ratio of effective actions, the number of repeated invalid commands, whether strategy switches have notepad evidence, and whether the agent stays within constraints even at a stat disadvantage. Without these process metrics, a seven-hour grind cannot distinguish “effective strategy” from “random attrition.”

    A Practical Workflow

    In practice, structure a long task as a fixed loop: observe, write a falsifiable hypothesis, take a minimal action, check the three observation layers, update the notepad, and decide whether to continue, switch observation source, or consolidate stable actions into a tool. Once a tool is consolidated, it enters version management: any parameter change must re-pass sandbox test cases, including illegal sequences, overlong sequences, and simulator desync. Sub-agents handle narrow tasks only—menu navigation or battle review—while the main agent retains goals and authorization.

    One boundary must be explicit: self-built tools, batched actions, and sub-processes must all live inside interfaces pre-approved by the evaluator or the business owner. If a constraint proves too strict, the right response is to propose an interface improvement—not to rewrite the input path through a side channel. Otherwise efficiency numbers lose meaning, and “adapting to the environment” degenerates into “bypassing controls.”

    The same method applies to analogous enterprise scenarios such as ticket handling, equipment inspection, or long approval chains. Give the agent scientific-style recording, an auditable tool layer, and multi-source observation; evaluate with milestones, tokens, turns, and human review together; place safety constraints in the executor, not the prompt. What you get is not a one-off success story, but a repeatable long-horizon decision-making capability.