Skip to main content
Glama

Simulate a battle

simulate_battle

Runs many simulated battles between a party and a troop to report win rate, turn counts, remaining HP, and damage or deaths using the project's real stats and formulas.

Instructions

Run many simulated battles of a troop against a party and report win rate, turns, how much HP the party keeps and who does the damage or dies. Uses the project's real stats (class curves, equipment, traits), damage formulas, variance, critical hits, hit/evasion rates, agility turn order, target weighting (TGR) and enemy action ratings. Party members use skillIds in order (first affordable one, healing only when an ally is below 60% HP), falling back to the Attack skill. Not modelled: states, buffs, items, guarding, TP, enemy conditions on states/switches (treated as false). Seeded, so results are reproducible. Default party: the starting party at their initial level.

Input Schema

NameRequiredDescriptionDefault
runsNo
seedNo
levelNoSet every party member to this level
partyNo
troopIdYes
maxTurnsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.5.1

TDQS

A3.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, and the description carries the full burden well. It discloses real stat usage, damage formulas, variance, crits, hit/evasion, turn order, target weighting, enemy action ratings, skill selection priority, healing threshold, unmodelled mechanics, seeded reproducibility, and the default party composition.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but front-loads the purpose and outputs before enumerating mechanics, limitations, and defaults. Every sentence carries information relevant to understanding or invoking the simulation, though the long mechanics sentence could be split for readability.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema and no annotations, the description does substantial work: it explains return metrics, simulation mechanics, unmodelled systems, reproducibility, and defaults. It remains slightly incomplete on some parameter semantics and limits, but is otherwise sufficient for an agent to call the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is only 17%, so the description needs to compensate. It adds meaningful semantics for party skillIds ordering, healing behavior, level defaults, and seed reproducibility, but it leaves runs, maxTurns, and the required troopId unexplained beyond the schema's bare types.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb and resource: running many simulated battles of a troop against a party and reporting win rate, turns, HP retention, and damage/death outcomes. It is unmistakably distinct from siblings like analyze_progression or playtest_start, but it does not explicitly name or contrast with those alternatives.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for balance simulation by describing the simulation scope, defaults, and limitations. However, it never states when to prefer this tool over alternatives such as balance_report, analyze_progression, or playtest_start, nor does it give explicit exclusions beyond model limitations.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.