@loupfeed/demo-mcp
v0.2.1
Published
loupfeed demo engine MCP server — lets an agent (Claude Code, Claude Desktop, …) discover an app's navigable surface, ground scenario files in the resulting map, and play them back humanized while recording walkthrough videos.
Readme
@loupfeed/demo-mcp
The agent surface of the loupfeed demo engine (#6): an MCP server that lets Claude Code (or any MCP client) produce recorded, human-looking product walkthroughs of your app.
The division of labour: the agent writes scenario files; the engine
guarantees the playback invariant — visible cursor travel, clicks only on
elements actually in the viewport, wheel-burst scrolling, human typing cadence
(see @loupfeed/demo-core).
Tools
| Tool | Purpose |
| --- | --- |
| demo_discover | Crawl the app → app map (route templates, scenario-ready selectors, nav edges). Sign in via prologueSteps or a storage state. |
| demo_get_map | Re-read the stored map — ground every scenario in it. |
| demo_validate_scenario | Schema-check a draft; returns exact issues to fix. |
| demo_save_scenario | Validate + persist scenarios/<name>.scenario.json. |
| demo_play | Humanized playback, recorded; per-step results + video path. |
| demo_list_recordings | The takes produced so far. |
Artifacts live under LOUPFEED_DEMO_DIR (default .loupfeed-demo/).
${VAR} placeholders in scenarios resolve from the server's environment
at play time — credentials never enter scenario files or the conversation.
Setup (Claude Code)
claude mcp add demo \
--env LOUPFEED_DEMO_DIR=.loupfeed-demo \
--env [email protected] \
--env DEMO_PASSWORD=… \
-- npx -y @loupfeed/demo-mcpplaywright is a peer dependency — install it and its browsers where the
server runs (npx playwright install chromium).
The agent loop
Give your agent instructions along these lines (this is the "demo director" skill):
When asked for a demo: 1)
demo_discoverthe app (useprologueStepswith${DEMO_EMAIL}/${DEMO_PASSWORD}placeholders if sign-in is needed); 2) read the map and write a scenario for the requested flow, using the map's selectors verbatim,readsteps between meaningful moments, andexpectVisibleassertions after each transition; 3)demo_validate_scenario, fix issues,demo_save_scenario; 4)demo_playand hand the user the video path. If a step fails, read the failure screenshot next to the recording, adjust the scenario, and re-play — same seed reproduces the same take.
