Skip to main content
Glama

kb_define_variable

Defines or updates a named RAM variable at a specific Game Boy address with type u8, u16, bool, or enum, enabling annotated memory inspection and code understanding.

Instructions

Name a RAM variable at the given address.

    Type must be one of: u8, u16, bool, enum. UPSERT on address.
    

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": {
      "address": "<address>",
      "name": "<name>",
      "type": "<type>"
    },
    "name": "kb_define_variable"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYes
typeYes
addressYes
descriptionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3/5.0
Behavior3/5

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

No annotations exist, so the description carries the full burden. It does disclose the valuable UPSERT-on-address semantics (idempotent create-or-replace) and enumerates allowed type values that the schema omits. It does not say what 'enum' type requires (presumably a previously defined enum), whether non-RAM addresses fail, or what the prior definition loses on upsert.

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?

Three short lines, front-loaded with the action and ending with the critical constraint and idempotency note. Nothing is padded, though the terseness slides into under-specification rather than tightness.

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?

For a 4-parameter mutation tool with no annotations and no output schema, this is only partially sufficient. The UPSERT behavior and type enum are covered, but the return value, the 'description' parameter, and the dependency of the 'enum' type on kb_define_enum are all left unexplained.

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?

Schema description coverage is 0%, so the description must compensate and largely does not. It clarifies 'type' (u8/u16/bool/enum) and hints at 'address' (RAM address) and 'name', but the fourth parameter 'description' is never mentioned, and no format constraints (address range, naming rules) are given.

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?

States a concrete verb and resource: name a RAM variable at a given address. The sibling set (kb_define_enum, kb_define_struct, kb_define_function) makes naming-vs-typing distinction reasonably clear from the verb+resource alone, though the description never explicitly contrasts itself with those tools.

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

Usage Guidelines2/5

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

No when-to-use or when-not-to-use guidance. An agent cannot tell from the text whether this should be called before or after kb_define_enum/kb_define_struct, or what happens when a variable is already named at that address beyond the single word 'UPSERT'.

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