analyze-mcp-server
安装方式
先用 Prompt 核对来源与依赖。也可下载安装包。
用 AI 助手安装
复制提示词,让助手先核对固定版本和依赖。
查看 Prompt收起 Prompt
先检查当前 Agent 是否已安装 SkillPI Skill Finder。如果尚未安装,请按官方仓库的说明安装并启用:https://github.com/Findskills/skillpi。然后使用 Skill Finder 打开此 SkillPI 详情页并定位 "analyze-mcp-server":https://skillpi.com/zh/skills/deepskill-cfc1631efcd330684a0cb1d448191acd854de0eb8a275788f190d8f1dbcead2f。安装前核对上游来源和版本:https://github.com/amplitude/builder-skills。来源不一致时停止并说明差异。核对通过后,用 Skill Finder 安装目标 Skill,并报告安装路径和来源版本。
来源与配置
github.com
配置方式待核实
请查看原始来源中的适用工具、依赖和权限要求。
安装实测待补充
当用户需要了解Amplitude MCP Analytics SDK埋点的MCP服务器使用情况时使用:分析MCP服务器中按工具拆解的使用量与错误,读取每个工具的调用理由以理解调用者意图,并生成按优先级排序的可操作修复建议。触发条件包括用户询问MCP服务器使用报告、工具错误分析、意图分析、理由聚类、MCP洞察,或提及[MCP]前缀事件、工具调用理由、工具调用错误,或刚完成MCP埋点并希望查看结果。该技能需要Amplitude MCP连接器支持。
介绍来源: third_party · amplitude · 0.0.1 参考来源
SkillPi 解读
- 输入和输出
- 翻译待完成,请参阅来源文档。
- 软件、账号及付费要求
- 翻译待完成,请参阅来源文档。
- 实测状态
- 未测试
文件浏览
Frontmatter
name: analyze-mcp-server
description: >-
Analyze MCP server usage instrumented with Amplitude's MCP Analytics SDK: break
usage and errors down by tool, read the rationales within each tool to see what
callers are trying to do, and produce a prioritized write-up of actionable fixes.
Use this skill whenever the user asks to understand how their MCP server is being
used, what agents/users are trying to do with it, why tool calls are failing, what
to fix or improve in their MCP server, or asks for an "MCP usage report", "tool
error analysis", "intent analysis", "rationale clustering", or "MCP insights". Also
trigger when the user mentions [MCP]-prefixed events, tool rationale, tool call
errors, or just finished instrumenting their MCP server and wants to see what the
data says. Requires the Amplitude MCP connector.Analyze MCP Server — Intent & Error Analysis
Produce a report that answers three questions about an MCP server instrumented with Amplitude's MCP Analytics SDK:
- Which tools are used, and which ones fail? (per-tool volume + error rate)
- What are callers trying to do with each tool, and where does each intent break? (rationales within a tool × error message)
- What should the team fix first? (fixes grounded in error evidence, not vibes)
The core move that makes this analysis valuable: tool locates the fix; rationale explains
the intent behind it. An overall error rate says "4.5% of calls fail." Broken down by tool
it says "query_chart fails 22% of the time" — now you know what to open. Adding the
rationales within that tool says "the failures are dashboard-refresh agents hitting the
batch-size limit" — now you know why, and the fix writes itself. Rationale is largely
tool-scoped (each tool has its own reason-for-calling), so tool is the primary axis and
rationale is the second cut inside it — clustering rationales globally just re-derives the
tool boundaries while mixing incomparable intents.
Prerequisites
-
Amplitude MCP connector active. If it isn't, stop and ask the user to add the Amplitude connector in their tools/connector settings — there is no fallback data source.
-
A project containing the SDK's events. The SDK emits SDK-owned default events, all prefixed
[MCP], and — critically — every default property they carry is also[MCP]-prefixed, they might have custom properties.Events:
[MCP] Tool Call Response— the workhorse: one event per tool invocation that reached a tool callback (success or error).[MCP] Tool Call Rejected— atools/callthat failed before any tool ran (unknown/ disabled tool, input-schema validation). This is where hallucinated/typo'd tool names land, carried on[MCP] Attempted Tool Name(kept off the reserved[MCP] Tool Name).[MCP] Session Initialized,[MCP] Session Ended,[MCP] Tools Listed.
Key properties on
[MCP] Tool Call Response:[MCP] Tool Name,[MCP] Client Name,[MCP] Client Version,[MCP] Session ID,[MCP] Auth Type,[MCP] Rationale,[MCP] Is Error,[MCP] Error Message,[MCP] Error Type(returned_errorvsthrown_exception— separates a tool that reported failure from one that crashed),[MCP] Response Duration,[MCP] Response Size,[MCP] Request Size. -
Event/property names can still drift between SDK versions. Never assume — verify with the taxonomy tools in Phase 0. The canonical names above come from the SDK's
constants.ts(EVENT_PROPERTY_KEYS); if the project's data disagrees, trust the project and adapt.
Phase 0 — Locate and validate the data
- Call the Amplitude context tool (no projectId) to list projects. If more than one plausible project exists and the user hasn't specified, ask.
- Confirm the
[MCP]events exist in the chosen project (search for events or list events;get_eventsfilters by exact name only, so use search for the[MCP]prefix discovery). - Pull event properties for
[MCP] Tool Call Response(and[MCP] Tool Call Rejected) to confirm the exact property names — remember they are[MCP]-prefixed and Title Cased (e.g.[MCP] Rationale, nottool rationale). Bind whatever you find to the names used in the queries below. - Run one volume/recency query: totals of
[MCP] Tool Call Response,[MCP] Session Initializedover the last 60 days, weekly interval. This tells you the usable date window and whether there's enough data. Under ~5k tool calls total, warn the user that per-tool breakdowns will be thin and percentages unstable — still proceed, but say so in the report.
Record: project ID, date window, total call volume. Every later query uses the same range so numbers stay comparable.
Phase 1 — Break down by tool (the spine)
This is the primary map; everything else drills into it.
- Volume by tool: totals of
[MCP] Tool Call Response, grouped by[MCP] Tool Name, groupByLimit ~100. - Errors by tool: same, plus filter
[MCP] Is Error is "true". - Rejected calls by attempted name: totals of
[MCP] Tool Call Rejectedgrouped by[MCP] Attempted Tool Name. These never reach a callback, so they are invisible to the two queries above — but a high-volume attempted name that isn't a real tool is one of the most actionable findings there is (a rename or hallucination agents keep guessing).
Compute per-tool call volume, error count, and error rate, and rank tools two ways: by call volume (what's load-bearing) and by error volume (what's costing the most failures). Pick the top 3–5 tools for deep-dive — bias toward high error volume, not just high traffic, and honor the user's choice if they named specific tools. A low-traffic tool with a 90% error rate can outrank a busy healthy one.
Phase 2 — Rationales within each top tool (the "why")
For each top tool, sample its rationales — totals of [MCP] Tool Call Response grouped by
[MCP] Rationale, filtered to that one tool ([MCP] Tool Name is "<tool>"), groupByLimit
~150. Then read them and group by what the caller is trying to accomplish with this tool,
not by wording. Guidance:
- Within a single tool you'll usually find 2–5 intent groups, not nine — the tool already
narrows the purpose. Name them by intent (e.g. for a
query_charttool: "live dashboard refresh", "ad-hoc exploration", "scheduled report generation"). - Weight by call volume (each rationale value carries its total), not by distinct strings.
- Watch for a junk group: "placeholder", "ignore", "noop", "test", "dummy", single letters. Its size is a rationale-hygiene finding, and junk must not contaminate real intents.
- Rationales like "Retry after rate limit" / "Retrying X" signal retry loops — note them.
- Non-English rationales are normal; group them by meaning.
- Compute rationale coverage per tool (share of the tool's calls with a non-empty rationale). If it's low (<50%), the intents describe only a slice — say so, and "improve rationale coverage at instrumentation time" becomes a recommendation itself.
- Compute top-intent share per tool (the largest intent group as a % of the tool's rationale-covered calls). This is the concentration signal: ~90% means the tool serves one job and you can optimize hard for it (tighten the schema/description around that path); a flat spread (top intent ~30%) means the tool is overloaded and may deserve splitting, or its errors will be spread across unrelated intents. Report the number and, when the top intent is dominant, name it next to the tool.
Cross-tool workflows (secondary): some rationales describe a multi-tool goal
("resolve chart id before refreshing the dashboard"). Where a single intent clearly spans
tools (e.g. search_events → create_chart → create_dashboard), call it out as a workflow
in the cross-cutting section — it's the one thing a pure tool-by-tool view misses.
Phase 3 — Error drill-down per tool
For each top tool, run (filtered to that tool + [MCP] Is Error is "true"):
- grouped by
[MCP] Error Message→ why it fails - optionally split by
[MCP] Error Type(returned_errorvsthrown_exception) when a message is ambiguous — a crash and a well-formed refusal both raise[MCP] Is Error, but only one is a bug in the tool.
Where a tool has a dominant intent group from Phase 2, qualify the errors by rationale
(add the rationale-contains filter) to get the "this intent breaks this way" sentence.
Classify each significant error message into an archetype — the archetype determines the fix:
| Archetype | Signature | Fix pattern |
|---|---|---|
| Stale/hallucinated tool name | [MCP] Tool Call Rejected with [MCP] Attempted Tool Name = a renamed or plausible-sounding tool |
Server-side aliases for renamed tools; rejection responses that name the closest real tool so agents self-correct in one shot |
| Missing required param | validation error, "Required", path names a param | Loosen the schema (accept single value or array, add defaults), or make the tool description state requirements so agents get it right pre-flight |
| Schema shape mismatch | "Expected object, received string" etc. | Add coercion server-side, or an inline example in the tool description |
| Hard limit collision | "Maximum of N …", "too_big" | Raise the limit, auto-chunk server-side, or state the limit in the parameter description — agents currently only learn limits by failing |
| Range/retention violation | "time range too large", "does not retain data before …" | Auto-coerce (e.g. downgrade granularity) instead of erroring; advertise retention/range limits in the context payload |
| Chicken-and-egg param | a context/discovery tool requires the very ID it exists to provide | Make discovery tools work with zero required args, defaulting from the auth token |
| Permission denied | role/permission language | Distinct error class so "not allowed" is separable from "broken"; often also a docs/onboarding gap |
| Recurring scheduled error | same message repeating daily on the same tool | Fix the job's caller if internal; for the product, flag as silently-degrading automation — nobody is watching a chat window |
| Transient/upstream | 5xx, timeouts, rate limits | Retry-after hints in the error body; check whether retries actually happen (see loop funnel) |
The best error messages state the fix ("re-run with start >= …"). Hold every high-volume error message to that standard — "make this error as actionable as your best one" is often a legitimate recommendation.
Phase 4 — Optional context metrics
Add if time permits; they sharpen the story:
- Repeat-error loop: 3-step funnel, each step
[MCP] Tool Call Responsewith[MCP] Is Error is "true", holding[MCP] Tool Nameconstant, ~1h conversion window. Shows what share of erroring users spiral into loops on the same tool. (Steps need not be consecutive events — say "3+ errors on the same tool within an hour", not "3 consecutive".) - Error → recovery: 2-step funnel, error then success, holding tool name constant. High recovery + high loop rate together mean the cost is wasted tokens/latency, not abandonment — a materially different conclusion.
- Client mix: uniques grouped by
[MCP] Client Name. Large "unknown" share or near-duplicate client names (casing, plugin-prefixed variants) are instrumentation findings worth reporting.
Phase 5 — Verify, then write
Before writing, re-verify at least one headline number a second way (e.g. overall error rate via a separate two-event totals query). Recompute every percentage you quote from raw totals. If a number can't be verified, cut it or label it an estimate.
Report structure
Use this template — organized tool-first:
# MCP Server Analysis — <server/project name>
Data: <project>, <date window>, <N> tool calls, overall error rate <X>%.
Method note: tool breakdowns are exact query results; within-tool intents are model-derived
from rationales (directional). Rejected-call names come from [MCP] Tool Call Rejected.
## Tools at a glance
<table: tool | calls | errors | error rate | top intent (share %) | rationale coverage>
<one line on rejected/attempted tool names if material; call out junk rationales if material>
## Deep dive: top 3–5 tools (ranked by error volume)
For each tool:
**Tool: <name> — <calls>, <error rate> — what it's for: <one-sentence>**
- Intents (rationales within this tool): <group : share>, …
- 1–4 numbered recommendations. Each states the evidence (error message + count),
the archetype, and the concrete fix. Lead with the fix that removes the most error volume.
## Cross-cutting findings
<cross-tool workflows, loop/recovery rates, client-name hygiene, rationale hygiene, internal test traffic, …>
## The one-sentence takeaway
<the single change that removes the most failure volume, with its number>
Style: numbers next to every claim; name the error messages verbatim (truncated) so engineers can grep for them; recommendations phrased as actions ("Ship alias for query_chart → query_charts"), not observations ("tool naming could be improved").
Charts in the output
Render supporting Amplitude charts where the client supports it, using the ad-hoc chart
query + render tools (build an eventsSegmentation/funnels definition, then render it).
Be deliberate about what can and cannot be a chart:
- Chartable — anything query-backed. These are real Amplitude segmentation/funnel
results, so render them: calls and errors by tool (grouped by
[MCP] Tool Name), error rate over time, rejected calls by[MCP] Attempted Tool Name, the per-tool repeat-error loop and recovery funnels, and client mix by[MCP] Client Name. The tool breakdown is the natural hero chart. - Not chartable — the within-tool intent groups. Grouping rationales into intents happens in this model; those groupings don't exist as an Amplitude property, so there's no saved chart for "calls by intent." Present intents as a table built from the rationale totals, and say plainly that intent figures are model-derived (directional) while the charts you render are exact query results. Don't imply a rendered chart backs the intent grouping.
Query Cookbook
All queries are eventsSegmentation or funnels definitions against the project ID from
Phase 0. Adjust event/property names to whatever Phase 0 verified. Shapes that are known
to work:
Tools breakdown (Phase 1):
{"type":"eventsSegmentation","app":"<PROJECT_ID>","name":"[MCP] Calls by Tool",
"params":{"range":"Last 30 Days",
"events":[{"event_type":"[MCP] Tool Call Response",
"group_by":[{"type":"event","value":"[MCP] Tool Name"}]}],
"metric":"totals","countGroup":"User","groupBy":[],"interval":30,"segments":[{"conditions":[]}]}}
Errors-by-tool: add {"subprop_type":"event","subprop_key":"[MCP] Is Error","subprop_op":"is","subprop_value":["true"]}
to filters. groupByLimit ~100.
Rejected calls (Phase 1): totals of [MCP] Tool Call Rejected grouped by
[MCP] Attempted Tool Name — catches hallucinated/renamed tool names that never fire an error
on [MCP] Tool Call Response.
Rationales within a tool (Phase 2):
{"type":"eventsSegmentation","app":"<PROJECT_ID>","name":"[MCP] Rationales for <tool>",
"params":{"range":"Last 30 Days",
"events":[{"event_type":"[MCP] Tool Call Response",
"filters":[
{"subprop_type":"event","subprop_key":"[MCP] Tool Name","subprop_op":"is","subprop_value":["<tool>"]},
{"subprop_type":"event","subprop_key":"[MCP] Rationale","subprop_op":"is not","subprop_value":["(none)"]}],
"group_by":[{"type":"event","value":"[MCP] Rationale"}]}],
"metric":"totals","countGroup":"User","groupBy":[],"interval":30,"segments":[{"conditions":[]}]}}
Use groupByLimit ~150. Set the time-series limit to 0 or low — only totals matter. Drop the
is not (none) filter once to measure that tool's rationale coverage.
Per-tool errors (Phase 3): same shape, ONE event, [MCP] Tool Name is "<tool>" +
{"subprop_key":"[MCP] Is Error","subprop_op":"is","subprop_value":["true"]}, group_by
[MCP] Error Message (or [MCP] Error Type). Add a [MCP] Rationale contains [...] filter to
qualify errors by intent.
Loop funnel (Phase 4):
{"type":"funnels","app":"<PROJECT_ID>","name":"[MCP] Repeated Error Loop",
"params":{"range":"Last 30 Days",
"events":[<error-filtered Tool Call Response> x3],
"cs":3600,
"holdingConstant":[{"type":"event","value":"[MCP] Tool Name"}],
"countGroup":"User","segments":[{"conditions":[]}]}}
Recovery funnel: 2 steps, second step filter [MCP] Is Error is not true. Read the
"Total" row of funnel output; daily rows are often zero-filled and misleading.
Known pitfalls:
- Every SDK property is
[MCP]-prefixed and Title Cased —[MCP] Tool Name,[MCP] Rationale,[MCP] Is Error,[MCP] Error Message,[MCP] Response Duration,[MCP] Response Size. Bare names won't match. - Group-by values only render when a single event in the definition carries the group_by. Put only ONE grouped event per query; volume/error-count totals (no group-by) can share one.
propavgis not a valid metric; property aggregations usesums/value_avgwith the property in the event group_by. Skip property aggregations if they fight back — they are not core to this analysis.- High-cardinality group-bys (
[MCP] Session ID) will not work; don't try. - Free-text properties (
[MCP] Rationale,[MCP] Error Message) can be long — keep groupByLimits modest and let volume ranking do the work.
当前收录版本
0.0.1
质量评测
满分100 · 来自 SkillPi LAB 实验室的评测报告。
亮点
- 提供工具级使用量与错误率拆解,直接定位高成本故障点
- 通过调用理由聚类揭示代理真实意图,超越表层指标
- 生成按错误量排序的可操作修复建议,驱动工程决策
亮点
- 触发词覆盖全面:支持'MCP使用报告'、'工具错误分析'、'意图分析'等多种表述
- 明确限定前置条件(需Amplitude MCP连接器),避免误触
- 识别[MCP]前缀事件与埋点完成场景,贴合实际工作流
待提升项
-
缺少独立When to Use章节 原报告严重程度:轻微
主文档未设置显式的'When to Use'章节,尽管frontmatter的description已涵盖使用场景
改进建议:建议在Phase 0前增加'When to Use'小节,提升可读性
亮点
- 五阶段流程清晰(数据验证→工具拆解→意图分析→错误归因→报告生成)
- 提供完整报告模板与Amplitude查询代码片段,可直接落地
- 严格区分模型推导指标(意图分组)与查询指标(工具统计),避免误导
待提升项
-
文档长度接近上限 原报告严重程度:轻微
skill_body约450行,虽未超过500行限制但接近阈值
改进建议:考虑将Query Cookbook移至单独文件并通过引用链接,提升维护性
亮点
- Phase 0强制验证数据源与属性命名,防止因SDK版本差异导致查询失败
- 对低数据量场景给出明确警告,管理预期
- 错误分类体系完整(8大类型),每类匹配具体修复模式
取前四项原始分值的算术平均,四舍五入取整。可通过收录报告核对各项评分与说明,运行记录需单独查证。
正文静态检测
100 / 100 · skillpi-20261123-no-r3-v1
正文未命中当前规则。
分数仅反映正文中的规则命中,供使用前参考。附件与运行行为不在此评分范围内。
权限与使用前检查
根据当前主文档自动整理,命中内容可能是示例或防护说明;不是实际权限声明,也未覆盖附件、外部依赖或运行行为。
未从主文档识别到上述常见操作,不能据此判断无需权限或没有风险。
安全评级与访问范围
safe · 静态证据核验,不代表运行安全保证。
翻译待完成,请参阅来源文档。
使用前请由宿主核对并授权实际文件读写、外部服务和联网目的地;本站的核验不会授予任何运行权限。
用户讨论
还没有已核实的点评。