Skip to main content
Glama

item_affixes

Lists the prefixes and suffixes a base item can roll at a given item level, with affix levels, groups, weights, and magic or rare quality chances per game version.

Instructions

Which prefixes and suffixes a base item can roll at an item level, from a version's MagicPrefix and MagicSuffix tables (a vanilla patch or a mod), with the affix level (from item level, the base's level and its magic lvl) and each affix's group and weight. quality 'magic': each affix's exact chance to be on a dropped magic item. quality 'rare': the pool rares draw from (rare=1 affixes) with each affix's share of one pick; a rare takes 3-6 in turn, so that is not a per-item chance. item: a base item's code or name ('rin', 'Monarch'). ilvl: 1-99, the item level (a monster drop's is the monster's level). limit: affixes listed per side, most likely first. Limits: 1.10 and later Legacy rules only; staff mods, automagic and sockets are separate rolls and not listed. State the version.

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": {
      "item": "<item>",
      "ilvl": "<ilvl>"
    },
    "name": "item_affixes"
  }
}

Input Schema

NameRequiredDescriptionDefault
ilvlYes
itemYes
limitNo
qualityNomagic
versionNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses data provenance (version's MagicPrefix/MagicSuffix tables, vanilla patch or mod), how affix level is derived (item level, base level, magic lvl), weight/group semantics, ordering ('most likely first'), and hard limits (1.10+ Legacy rules only). The main unstated behavior is what version=null means when omitted, since the schema defaults it to null.

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

Conciseness3/5

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

No redundant sentences and the purpose is front-loaded, but it is a dense run-on with fragment clauses ('item: a base item's code or name') and topic switches mid-sentence, making it harder to scan than a short bullet-style layout would be. Every clause carries information, so the conciseness is good even though the structure is not.

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?

Given a 5-parameter, multi-mode lookup with an output schema present, the description covers source tables, derivation rules, mode semantics, ordering, and exclusions, which is nearly everything an agent needs before calling. The remaining hole is version default behavior when the caller omits it.

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 0%, so the description must carry all parameter meaning, and it does for four of five: item examples ('rin', 'Monarch'), ilvl range 1-99 with the monster-level interpretation for drops, limit as affixes per side ordered most-likely-first, and quality's dual magic/rare semantics. Version is only covered by 'State the version' with no explanation of the default-null case, leaving one gap.

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?

States a specific verb and resource: which prefixes and suffixes a base item can roll at a given item level, sourced from MagicPrefix/MagicSuffix tables. It immediately distinguishes itself from loot/drop-style siblings by naming the exact tables and the affix-level derivation, so an agent knows this is affix-pool data, not drop simulation.

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?

Gives concrete usage context by explaining what each quality mode returns ('magic' = exact per-item chance; 'rare' = share of one pick within a 3-6 affix draw, explicitly not a per-item chance) and states exclusions (staff mods, automagic, sockets are separate rolls). It also instructs 'State the version.' It stops short of naming an alternative tool for drop odds, so no explicit when-to-use-vs-sibling routing.

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