Skip to content

feat: map_matching_tool renders as a live GL JS map#193

Closed
mattpodwysocki wants to merge 6 commits into
feat/search-app-toolsfrom
feat/map-matching-app-tool
Closed

feat: map_matching_tool renders as a live GL JS map#193
mattpodwysocki wants to merge 6 commits into
feat/search-app-toolsfrom
feat/map-matching-app-tool

Conversation

@mattpodwysocki
Copy link
Copy Markdown
Contributor

@mattpodwysocki mattpodwysocki commented May 27, 2026

Same pattern. Drops map_matching_app_tool; existing tool emits dual UI hints sharing renderMapMatchingAppHtml. 717 tests pass. Stacked on #192.

Fifth in the MCP Apps series. Snaps a raw GPS trace to the road network
and renders both the raw trace (dashed orange) and the matched route
(solid blue) on an interactive Mapbox GL JS map. Includes a small
legend; the camera fits to the combined bounds of both traces.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
mattpodwysocki and others added 4 commits May 27, 2026 11:44
Same pattern.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
# Conflicts:
#	CHANGELOG.md
#	src/tools/index.ts
#	src/tools/toolRegistry.ts
Same pattern. Drops map_matching_app_tool; existing tool emits meta.ui
(MCP Apps) + inline rawHtml (MCP-UI). Shared renderMapMatchingAppHtml
draws raw trace as dashed orange, matched route as solid blue, with
polyline-string decoding for the matched geometry.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@mattpodwysocki mattpodwysocki changed the title feat: map_matching_app_tool — raw GPS trace vs snapped route feat: map_matching_tool renders as a live GL JS map Jun 1, 2026
@mattpodwysocki mattpodwysocki marked this pull request as draft June 1, 2026 20:43
@mattpodwysocki
Copy link
Copy Markdown
Contributor Author

Superseded by #199.

This PR (and the rest of the per-tool app stack: #190, #191, #192, #193, #194, #195) declares its own meta.ui.resourceUri and emits inline createUIResource via @mcp-ui/server. In practice that approach has two blockers:

  1. Chained tool calls only render the last iframe. Claude Desktop dedupes/short-circuits earlier iframes in a chain, so geocode→directions or isochrone→union flows only paint the final tool's map.
  2. Depends on @mcp-ui/server, which feat: render_map_tool — single visualization primitive (server-side refs) #199 removes.

#199 funnels all rendering through one terminal render_map_tool primitive. Every data tool stores a MapAppPayload server-side and returns a mapbox://temp/map-payload-<uuid> ref; the LLM passes the refs to render_map_tool, which merges them and renders. Closing in favor of that approach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant