Skip to main content
Glama

Change a MiSTer.ini setting

mister_set_ini
Idempotent

Modify or clear a configuration key in MiSTer.ini or an alternate .ini file, with dry-run diffs and a timestamped backup before writing to SD storage.

Instructions

<use_case> Modify or clear a configuration key in MiSTer.ini (or alternate ini). </use_case> <important_notes>

  • Creates a timestamped .bak backup on SD storage before writing.

  • Rate-limited to guard against rapid SD card wear.

  • Dangerous system keys (main, bootcore, shared_folder) are disallowed. </important_notes>

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": {
      "key": "<key>",
      "value": "<value>"
    },
    "name": "mister_set_ini"
  }
}

Input Schema

NameRequiredDescriptionDefault
keyYesA MiSTer.ini key, e.g. vscale_mode (misterfpga://ini-keys lists them).
fileNoMiSTer.ini, or an alternate such as MiSTer_crt.ini (mister_get_ini lists them).MiSTer.ini
hostNoMiSTer name from mister_get_status. Omit when the call already says which (a ref does).
valueYesThe new value, checked against the key's type and range. null removes the key.
dry_runNoShow the change (diff) without writing it.
sectionNoMiSTer (global), arcade, arcade_vertical, video=<WxH@Hz>, or a core name like SNES.MiSTer

Output Schema

NameRequiredDescriptionDefault
keyYes
newYes
oldYes
diffYes
fileYes
hostYes
backupYes
detailYes
outcomeYes
sectionYes
warningsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.9/5.0
Behavior5/5

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

Beyond the annotations (write, idempotent, non-destructive), the description discloses three traits the structured fields cannot: a timestamped .bak backup is written before any change, the tool is rate-limited to protect SD card wear, and dangerous system keys (main, bootcore, shared_folder) are rejected. Those are exactly the operational facts an agent needs before invoking a mutating tool.

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?

Two short, front-loaded blocks with the action first and the constraints after; nothing is wasted. The <use_case> sentence largely restates the title, which is mild redundancy but does not obscure the content.

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 six parameters, full schema coverage, annotations, and an output schema, the remaining burden on the description is behavioral, and it covers backup, rate limiting, and key restrictions well. It does not mention that dry_run returns a diff without writing (only in the schema), a minor gap for a mutation tool.

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

Parameters3/5

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

Schema description coverage is 100%, so key, value, file, host, dry_run, and section are already documented in the schema, including that null removes a key and that value is type/range checked. The description adds nothing parameter-specific beyond implying alternate ini files are supported. Baseline 3 is appropriate when the schema carries the burden.

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 states a specific verb+resource: "Modify or clear a configuration key in MiSTer.ini (or alternate ini)." That is far more precise than the title alone and makes clear this is the write counterpart to a read tool. It does not explicitly name a sibling or scope boundary, which keeps it just short of a 5.

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 through the use_case block and the note that dangerous system keys are disallowed, which tells the agent when this tool will refuse. There is no explicit guidance on alternatives (e.g., when to prefer reading via mister_get_ini first) and no mention of using dry_run to preview rather than commit, so routing guidance is only partial.

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