Skip to content

Orpheus-K/peekit

Repository files navigation

Peekit

English | 简体中文

Runtime eyes for AI agents.

Peekit is an AI-first runtime inspection MCP server. It gives coding agents measured evidence from H5 and Weixin Mini Program targets: page state, element text, DOM markup or WXML, rects, computed styles, console output, errors, interactions, before/after snapshots, and diagnosis hints.

Peekit is not designed as a human-operated CLI workflow. The npm package is the distribution vehicle for the MCP server.

Install

Add Peekit to an MCP client:

{
  "mcpServers": {
    "peekit": {
      "command": "npx",
      "args": ["-y", "@peekit/cli", "mcp"]
    }
  }
}

Then ask your coding agent natural-language UI questions:

Check why this button does not show a loading state after click.
Compare the measured spacing, color, and visibility of this page between H5 and Weixin mini program.
After the fix, verify with Peekit using before/after runtime evidence.

For local runtime paths, use ~/.peekit/local-setup.json for machine-wide paths and <repo>/.peekit/local-setup.json for project overrides. Weixin targets require weixin.automation.servicePortEnabled: true after the Developer Tools service port is enabled in security settings.

Tools

Peekit exposes these MCP tools:

  • peekit_inspect_environment
  • peekit_suggest_target_config
  • peekit_suggest_mcp_client_config
  • peekit_validate_target
  • peekit_explain_setup_blocker
  • peekit_list_targets
  • peekit_connect_target
  • peekit_get_current_page
  • peekit_open_page
  • peekit_query_element
  • peekit_query_all
  • peekit_capture_snapshot
  • peekit_perform_interaction
  • peekit_compare_snapshots
  • peekit_diagnose_issue
  • peekit_suggest_next_probe
  • peekit_record_case
  • peekit_replay_case
  • peekit_cross_target_compare

Current Capability

Target Status Notes
H5 Implemented Playwright-backed page, DOM, text, rect, computed style, console, errors, click, tap, input, scroll, hover
Weixin mini program Implemented Uses miniprogram-automator to connect Weixin Developer Tools and capture route, WXML, text, size, offset, style, console, errors, tap, input, and scroll
Alipay mini program Roadmap Not part of the alpha support scope; returns explicit unsupported evidence
ByteDance mini program Roadmap Not part of the alpha support scope; returns explicit unsupported evidence
QQ mini program Roadmap Not part of the alpha support scope; returns explicit unsupported evidence

Unsupported fields are reported explicitly so agents can reason from capability evidence instead of guessing.

Development

pnpm install
pnpm build
pnpm test

Package layout:

packages/
  core/
  mcp-server/
  adapter-h5/
  adapter-mp-weixin/
  adapter-mp-alipay/
  adapter-mp-bytedance/
  adapter-mp-qq/
  reporter/
docs/
examples/

See docs/ai-usage.md and docs/agent-contract.md for the agent workflow and runtime evidence contract. For real Weixin Developer Tools setup, see docs/weixin-troubleshooting.md. For alpha publishing, see docs/release.md.

About

Runtime eyes for AI agents. MCP-powered UI inspection for H5 and mini programs.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors