Skip to main content
Glama
Terranslayer

D&D 5e Tool Server

by Terranslayer

resolve_attack

Resolve D&D 5e attack rolls against target AC, incorporating advantage, disadvantage, natural 20 critical hits, and natural 1 automatic misses.

Instructions

解析攻击骰。nat20 必中且暴击,nat1 必失。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
advantageNo
target_acYes
attack_bonusYes
disadvantageNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior3/5

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

With no annotations provided, the description carries the behavioral burden, and it does disclose the important special cases: nat20 always hits and crits, nat1 always misses. However, it omits the core resolution behavior, such as comparing d20 + attack_bonus against target_ac and how advantage/disadvantage affect the roll.

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

Conciseness5/5

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

The description is extremely concise, with no wasted words, and it front-loads the core purpose before adding the key natural-roll rules. Every clause earns its place.

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

Completeness2/5

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

Given four parameters, two of which are booleans, no annotations, and no output schema, the description is under-specified. It leaves the main hit/miss math and the effect of advantage/disadvantage unstated, so an agent would need external D&D knowledge to call the tool correctly in non-trivial cases.

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

Parameters2/5

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

The schema has 0% description coverage, so the description must compensate, but it never explains attack_bonus, target_ac, advantage, or disadvantage. It adds only the d20/nat context, leaving the meaning of all four parameters to be inferred from their names and standard D&D conventions.

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 clearly states a specific action, '解析攻击骰' (resolve attack roll), and adds the critical nat20/nat1 rules, making the tool's purpose evident. However, it does not explicitly contrast itself with siblings such as resolve_check or roll_dice, so it falls short of full differentiation.

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?

Usage is implied by the name and wording: the tool should be used when resolving an attack roll. But the description gives no explicit guidance about when not to use it or which sibling tool to prefer for related cases like general checks or damage rolls.

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