Skip to main content
Glama
Komeiji-Shiki

trpg-dice-mcp

roll_dice

Roll dice for TRPGs with complex expressions such as 3d6+2, 4d6kh3, d%, and Fudge dice. Supports repeated rolls, hidden rolls, and custom rounding.

Instructions

掷骰并计算完整算术表达式。支持四则运算、括号、取整函数及全部修饰符。

示例:

  • 普通掷骰:expression="3d6+2"

  • 优弃:expression="4d6kh3"(4d6 取最高的 3 个)

  • 爆炸骰:expression="3d6!"(骰出 6 追加一骰)

  • 带除法:expression="(8d6)/2"

  • 百分骰:expression="d%"

  • Fudge骰:expression="4dF"

  • d66查表骰:expression="d66"

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsNo标签
timesNo重复掷骰次数
hiddenNo暗骰:true 时结果不进入 LLM 上下文
localeNozh
reasonNo掷骰原因,如「攻击哥布林」
roundingNo除法取整方式,默认 floor
expressionYes骰子表达式,如 3d6+2、4d6kh3、d%、(8d6)/2
Behavior3/5

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

Annotations provide no behavioral hints (all false), so the description carries the burden. It does not disclose that rolls are random, that results may be recorded (given get_roll_history sibling), or that hidden rolls are excluded from context—though the 'hidden' parameter schema touches on the latter. The description focuses on expression syntax rather than operational behavior, which is adequate but not rich.

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 a single introductory sentence followed by a well-formatted list of examples. It is front-loaded with the purpose, and every line adds value—no filler. The structure makes it easy to scan and understand the tool's capabilities quickly.

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 7 parameters, the description provides a solid overview and expression examples, but it does not explain parameters like 'times', 'hidden', 'locale', or 'reason'—though the schema descriptions cover them. It also does not mention recording behavior or how this relates to sibling tools. Given the schema's coverage, this is reasonably complete for a dice roller.

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 high (86%), and the description adds significant value for the core 'expression' parameter by providing concrete usage examples (e.g., '4d6kh3', '(8d6)/2', 'd66') that clarify syntax beyond the schema's brief description. It also mentions rounding functions, aligning with the 'rounding' parameter. Other parameters are left to the schema, which is acceptable given their self-descriptive schemas.

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?

The description clearly states that the tool rolls dice and evaluates arithmetic expressions, with a specific resource (dice expression) and scope (supports four operations, parentheses, rounding, and all modifiers). The examples differentiate it from siblings by showcasing general-purpose expression handling (e.g., 4d6kh3, d%, 4dF), implying broader capability than specialized tools like roll_pool or roll_fate.

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 provides clear context for use—any time a dice expression with arithmetic/modifiers is needed—but it does not explicitly state when NOT to use it or mention alternatives like roll_check or roll_table. Usage is implied through examples rather than explicit guidance.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Komeiji-Shiki/trpg-dice-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server