Skip to main content
Glama

Preview style

preview_style
Read-only

Generate a live link to an interactive MapLibre style map served locally; it redraws when the style file changes, with no viewer page or web server to start.

Instructions

Gives the user a link to an interactive map of a style, served by this server on their machine, so there is no viewer page to write, no web server to start and no browser to open for them. Given a file, the map follows it and redraws when the file changes. Given the style as an object, the map shows a changed style when you pass it together with the link, as link. Pass the style as an object, a URL or a file path.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoURL of a style JSON document.
linkNoA link that this tool gave before for a style passed as an object. The map there then shows this style, and a page that has it open redraws.
pathNoPath to a style JSON file, relative to the directory the server runs in.
styleNoThe style as a JSON object.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.9.2

TDQS

A3.6/5.0
Behavior4/5

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

Annotations only give readOnlyHint and openWorldHint=false, so the description carries useful extra context: the map is served on the user's machine, needs no browser/web server setup, follows a file and redraws on change, and supports reusing a prior link to update an open page. This is genuinely behavioral detail beyond the structured fields.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose is front-loaded, but the phrasing is rambling ('no viewer page to write, no web server to start and no browser to open for them') and the final sentence restates the input modes already covered. Some sentences do not fully earn their place.

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, zero-required tool with a nested style object and no output schema, the description adequately covers all input modes and the live-reload/redraw semantics an agent needs. It is reasonably complete, though it omits any mention of the returned link's format or lifetime.

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 documents url, link, path, and style. The description's explanation of the link/style interaction largely restates the schema's own description for 'link', adding little syntax or format detail beyond it, so baseline 3 applies.

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 clearly states a specific verb+resource: it provides a link to an interactive map of a style, served locally by the server. This is distinguishable from rendering siblings, but no sibling tool (e.g., render_style, show_map) is named, so it falls 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?

It explains the three input modes (file path, URL, style object) and the live-reload behavior, which implies usage, but it never states when to prefer this over render_style, show_map, or render_page. No explicit when-not-to-use guidance is given.

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