Skip to main content
Glama
This server has been deprecated

Rebranded to ComposeLint AI. Repository has been moved to TechsOneAi/ComposeLintAI.

set_token

Destructive

Modifies .kt source files to surgically edit a design token value, enabling AI coding agents to apply targeted Jetpack Compose token changes.

Instructions

DESTRUCTIVE: Modifies .kt files. Surgically edit a design token value in source code.

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": {
      "token_name": "<token_name>",
      "value": "<value>"
    },
    "name": "set_token"
  }
}

Input Schema

NameRequiredDescriptionDefault
valueYes
token_nameYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added
  2. Removed
  3. First observedv0.1.0

TDQS

C2.9/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, readOnlyHint=false, and idempotentHint=false, so the safety profile is covered structurally. The description adds genuinely useful context beyond that by stating it modifies Kotlin source files, which tells the agent code on disk changes. It does not say what happens when the token is missing or whether the edit must be approved afterward, which matters given approval-related siblings.

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 sentences with the destructive warning front-loaded, so the most important signal is read first. "Surgically" is slightly decorative but also conveys that the edit is narrow, so little is wasted.

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?

An output schema exists, so return values need no explanation, but the definition is thin for a destructive mutation. For a two-required-parameter write tool with zero schema coverage, the agent still lacks token_name syntax, value format, not-found behavior, and whether the change needs a separate approval step.

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 carry the burden for both parameters, and it does not. It never explains what form token_name takes (fully qualified path? group-qualified?) or what value accepts (hex code, dimension with units, alias reference), leaving the agent to guess at two required inputs.

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?

"Surgically edit a design token value in source code" gives a specific verb (edit) and resource (design token value) and names the file type it touches (.kt). It is clearly distinguishable from add_token or set_text in intent, though it never explicitly contrasts itself with those siblings.

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?

The description supplies no when-to-use guidance, no prerequisites, and no exclusions. "Surgically" hints that it performs a minimal in-place edit rather than a bulk rewrite, but there is no statement of when this should be chosen over add_token, set_text, or replace_pattern.

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