Skip to main content
Glama
flutter-devtools-mcp

flutter-devtools-mcp

by draganbajic

compare_snapshots

Compare two saved memory snapshots to see heap usage differences, classes that grew or shrank, new allocations, and freed memory, validating whether a fix reduced memory usage.

Instructions

Compare two previously saved memory snapshots to see what changed. Shows heap usage diff, which classes grew or shrank, new allocations, and freed memory. Perfect for validating that a fix actually reduced memory usage.

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": {
      "before": "<before>",
      "after": "<after>"
    },
    "name": "compare_snapshots"
  }
}

Input Schema

NameRequiredDescriptionDefault
afterYesName of the "after" snapshot
beforeYesName of the "before" snapshot

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the full burden: it says what the diff reports (heap usage, class growth/shrink, new allocations, freed memory), which is useful behavioral context. It does not state that the operation is read-only, whether an active app connection is required, or how large diffs are presented, leaving real gaps.

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 sentences, front-loaded with the action, then capabilities, then the motivating use case. No filler beyond the slightly promotional 'Perfect for' phrasing.

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 two-parameter read/analysis tool with no output schema, the description covers the input prerequisite and the shape of the returned information. Missing pieces are lifecycle details such as connection requirements and whether snapshots are scoped to a session.

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 coverage is 100%, so 'before' and 'after' are already documented in the schema with their meanings. The description only implies the ordering ('two previously saved snapshots') and adds no format or naming detail beyond 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 and resource ('Compare two previously saved memory snapshots') plus what the diff exposes. It is clearly distinct from save_snapshot and list_snapshots in intent, though it does not name a sibling to contrast with explicitly.

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?

The 'Perfect for validating that a fix actually reduced memory usage' line gives a use case and 'previously saved' implies the snapshots must already exist. There is no explicit when-not guidance or pointer to alternatives.

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