Skip to main content
Glama

Peace in Space Game

Preview an attack

preview_attack
Read-onlyIdempotent

How an attack by your piece fleet would go, against the enemy piece target or the enemy system planet (give one): from where it stands, or from tile x, y it would move to first (as an attack with x, y from legal_actions does). Changes nothing.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "fleet": "<fleet>",
      "code": "<code>"
    },
    "name": "preview_attack"
  }
}

Input Schema

NameRequiredDescriptionDefault
xNoPreview from this tile, as if moved there first. -1: from where it stands.
yNoThe tile's row, with x.
codeYesThe game's code (like K7M-3XQ), from the player's message. If it names none, get one from new_game rather than asking them.
fleetYesThe attacking ship (one of yours).
planetNoAn enemy system to attack. Give target or planet.
targetNoAn enemy ship to attack. Give target or planet.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior3/5

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

Annotations already declare readOnly, idempotent and non-destructive, so 'Changes nothing' is largely reinforcement. The description does add real behavior beyond the annotations — the two evaluation modes (from current position vs. as if relocated to x, y first) — but says nothing about what the preview returns, which is the whole point of the tool and is not covered by an output schema.

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?

A single dense sentence with the key constraint front-loaded and no filler. The nested parentheses around the x, y explanation make it slightly harder to parse than it needs to be.

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

Completeness3/5

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

Six parameters with two required and no output schema: the description handles input selection well but leaves the return value entirely unexplained, which is a meaningful gap for a prediction tool. The `code` parameter is untouched in the description, though the schema documents it fully.

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

Parameters4/5

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

Schema coverage is 100%, so baseline is 3; the description earns a bump by tying x, y to the attack actions returned by legal_actions, giving the agent a concrete source for valid coordinates. The target-or-planet exclusivity is restated rather than newly explained, since the schema already says 'Give target or planet.'

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

Purpose5/5

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

Names a specific verb (preview) and a specific resource (an attack by `fleet` against `target` or `planet`), and explicitly separates itself from the acting sibling with 'Changes nothing.' An agent can tell this apart from `act` and `legal_actions` without opening any schema.

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

Usage Guidelines4/5

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

The dry-run framing plus the parenthetical 'as an attack with x, y from legal_actions does' tells the agent this is for evaluating an attack before committing one, and points at the sibling that supplies valid coordinates. It stops short of an explicit 'use instead of act when…' rule or a statement of when not to call it.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources