Skip to main content
Glama

unslop_refactor_plan

Analyze a component or directory to generate a preset-tailored refactor blueprint, writing a Markdown report with before/after class and token replacements, scorecard, and prioritized file:line tasks.

Instructions

Analyze a component or directory and generate a step-by-step Design Transformation Blueprint tailored to a studio preset. Writes a Markdown refactor report (default 'UNSLOP-REPORT.md') to disk and returns the 7-pillar scorecard, exact before/after class and token replacements, and prioritized file:line refactoring tasks.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "unslop_refactor_plan"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathNoComponent file or directory path to analyze, relative to the server project root (defaults to '.').
ignoreNoOptional list of additional directory base names to exclude from analysis.
presetNoTarget studio design archetype used to compute exact replacement classes and CSS tokens (defaults to 'linear-precision').
reportNoOutput file path for the generated Markdown transformation blueprint, relative to project root (defaults to 'UNSLOP-REPORT.md').

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv2.1.2
    • changedInput schema / properties / ignore / description
      Previous value: -"Additional directory base names to skip."New value: +"Optional list of additional directory base names to exclude from analysis."
    • changedInput schema / properties / path / description
      Previous value: -"Component or directory to analyze, relative to the server project root."New value: +"Component file or directory path to analyze, relative to the server project root (defaults to '.')."
    • changedInput schema / properties / preset / description
      Previous value: -"Archetype used for exact replacement classes and tokens."New value: +"Target studio design archetype used to compute exact replacement classes and CSS tokens (defaults to 'linear-precision')."
    • changedInput schema / properties / report / description
      Previous value: -"Markdown report path (default: UNSLOP-REPORT.md)."New value: +"Output file path for the generated Markdown transformation blueprint, relative to project root (defaults to 'UNSLOP-REPORT.md')."
  2. First observedv2.1.1

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the burden and does disclose the key side effect: it writes a Markdown file to disk with a default filename, and it discloses what is returned (scorecard, before/after replacements, prioritized file:line tasks). Gaps remain on whether the source files themselves are modified and whether an existing report is overwritten.

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?

Two dense sentences with the action and the disk-write artifact front-loaded and the return contents enumerated second; no filler wording.

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?

For a 4-parameter tool with no output schema and no annotations, the description covers the output payload and the file-write side effect adequately. It falls short of fully specifying whether source code is mutated or the report is overwritten, which matters given the 'refactor' framing.

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 the schema already explains path, ignore, preset enum, and report path including defaults. The description adds only the meaning that the preset drives 'exact replacement classes and CSS tokens' — useful but marginal over the schema.

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 specific verb+resource: analyze a component or directory and generate a Design Transformation Blueprint, plus the concrete artifact it writes (a Markdown refactor report). This distinguishes it in practice from siblings like unslop_apply_preset or unslop_list_presets, though it never names an alternative to route against.

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 by the phrasing 'tailored to a studio preset' and the report output, but there is no explicit when-to-use/when-not guidance and no comparison to unslop_audit, which an agent could easily confuse with this analysis tool.

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