Data Visualization
粘贴订单或事件 CSV,一页得到增长分析全家桶:带热力图的队列留存三角、RFM 五分位评分映射到十个标准生命周期分层、以及严格顺序漏斗。
用三种语言从你的代码中调用此工具。
curl -X POST 'http://127.0.0.1:3003/zh/api/tools/cohort-retention-rfm-funnel-analyzer' \
-H 'Content-Type: application/json' \
-d '{"ordersCsv":"user_id,date,amount\nu1,2026-01-05,120\nu1,2026-02-03,80\nu1,2026-03-02,60\nu1,2026-04-01,40\nu2,2026-01-08,200\nu2,2026-02-20,150\nu3,2026-01-15,90\nu4,2026-02-02,300\nu4,2026-03-05,250\nu4,2026-04-06,220\nu5,2026-02-10,60\nu6,2026-02-14,75\nu6,2026-03-20,50\nu7,2026-03-01,500\nu7,2026-04-02,400\nu8,2026-03-12,110\nu9,2026-03-25,45\nu10,2026-04-03,160","cohortPeriod":"month","periodsCount":3,"analysisDate":"2026-04-06","funnelSteps":"signup, cart, checkout, purchase — needs an event column"}'以 JSON 形式 POST 提交输入参数。文件类型参数需先单独上传。
POST http://127.0.0.1:3003/zh/api/tools/cohort-retention-rfm-funnel-analyzer| 参数名 | 类型 | 必填 | 说明 |
|---|---|---|---|
| ordersCsv | textarea | 是 | — |
| cohortPeriod | select | 是 | — |
| periodsCount | number | 否 | — |
| analysisDate | text | 否 | — |
| funnelSteps | text | 否 | — |
HTML 结果
{
"result": "<div>Processed HTML content</div>",
"error": "Error message (optional)",
"message": "Notification message (optional)",
"metadata": {
"key": "value"
}
}将此工具加入你的 Model Context Protocol 服务,让 AI 智能体可以列出并调用它。
将以下内容加入你的 MCP 客户端配置:
{
"mcpServers": {
"elysiatools-cohort-retention-rfm-funnel-analyzer": {
"name": "cohort-retention-rfm-funnel-analyzer",
"description": "粘贴订单或事件 CSV,一页得到增长分析全家桶:带热力图的队列留存三角、RFM 五分位评分映射到十个标准生命周期分层、以及严格顺序漏斗。",
"baseUrl": "http://127.0.0.1:3003/mcp/sse?toolId=cohort-retention-rfm-funnel-analyzer",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}连接到 SSE 端点后,列出已开放的工具:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}通过工具 id 调用,参数由其参数表构建:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "cohort-retention-rfm-funnel-analyzer",
"arguments": {
"ordersCsv": "user_id,date,amount\nu1,2026-01-05,120\nu1,2026-02-03,80\nu1,2026-03-02,60\nu1,2026-04-01,40\nu2,2026-01-08,200\nu2,2026-02-20,150\nu3,2026-01-15,90\nu4,2026-02-02,300\nu4,2026-03-05,250\nu4,2026-04-06,220\nu5,2026-02-10,60\nu6,2026-02-14,75\nu6,2026-03-20,50\nu7,2026-03-01,500\nu7,2026-04-02,400\nu8,2026-03-12,110\nu9,2026-03-25,45\nu10,2026-04-03,160",
"cohortPeriod": "month",
"periodsCount": 3,
"analysisDate": "2026-04-06",
"funnelSteps": "signup, cart, checkout, purchase — needs an event column"
}
}
}有问题或反馈?请联系 [email protected]