Funnel Calibrator
Funnel Calibrator
一个 MCP 服务器,它根据销售漏斗的实际表现来重新校准广告决策——而不是根据对其的假设。
⚠️ 状态:正在开发中。 脚手架与设计决策已提交;MCP 服务器实现将于 2026 年 8 月 24 日落地。答辩:2026 年 8 月 25 日。
KSE AI Agentic Lab——个人实验实验室作业(第 7 周,MCP 集成)。
它解决的问题
本项目基于一个正在运营的乌克兰货到付款(COD)电商业务,通过 Meta 广告销售女装。它的漏斗包含五个阶段:
Meta ads ──► Lead ──► Call-centre approval ──► Shipment ──► Buyout at post office ──► Profit由于付款发生在交货时,广告支出的结果在资金投入的那一刻并不可知。要等两到四周之后,顾客取件或拒收时,结果才会明朗。该业务用两个覆盖整个产品组合的常数来弥合这一时间差——65% 的通过率和 52.5% 的买断率——并用它们计算每个产品仍能盈亏平衡的最大单条线索成本(Stop CPL),以及应当优化到的目标值(Goal CPL)。
这些常数是应用在单个产品上的组合平均值,而单个产品与其的偏差可能非常悬殊。 来源业务中的实测例子:某制造商的买断率实际为 37%,而假设为 52.5%;某产品的通过率实测为 53%,而假设为 65%;买断率与价格带强相关,从 690–790 ₴ 的约 93% 到 1290 ₴ 以上的约 55%。
当某个产品的实际**指标优于预期时,其真实盈亏平衡 CPL 会低于业务所依据的数字——于是广告目标可能落在真实盈亏平衡点之上*。广告后台里流量看起来很正常,而每条线索都在亏钱;这种亏损要到几周后的月度财务结算时才会显现出来。
这是一个开环控制系统:测量结果从未回到决策环节。Funnel Calibrator 将闭环闭合。
Related MCP server: KrystalView MCP Server
功能
服务器从历史订单数据中测量每个产品自身的漏斗费率,重新计算该产品的真实 CPL 边界,并针对修正后的数值审计拟定的广告决策——返回的是结构化证据,而不是一个有待无条件接受的结论。
有两个问题让这件事比一般情况更难度,两者都在工具契约中被显式处理:
截尾。 近期订单尚未完全可判定——在途的包裹既不是买断也不是退货。若把它们的数值直接计入,会人为地压低测量出来的费率。服务器会剔除未满可配置成熟窗口的数据队列组,并报告它搁置了多少订单。
样本量小。 按产品、尺码、颜色拆分后,计数很快会变小。每次测量都会标明样本量和可靠性情况,且当数值低于一个可配置阈值时,服务器拒绝下结论,而不是输出虚假的信噪。
架构
┌─────────────────────────────────────────────────────────────┐
│ Agent (Claude Agent SDK) │
│ │
│ ├── MCP ──► Obsidian Local REST API [existing] │
│ │ decision journal: reads the day's objective │
│ │ and prior conclusions, writes calibrated │
│ │ verdicts back as a durable record │
│ │ │
│ └── MCP ──► Funnel Calibrator [custom] │
│ measure → recalibrate → recommend → audit │
│ │ │
│ ▼ │
│ local snapshot dataset │
│ (anonymised order cohorts + unit economics) │
└─────────────────────────────────────────────────────────────┘自定义服务器以独立进程方式运行,通过 stdio 通信,并且可以不依赖智能体独立启动。
元素流
从 Obsidian 仓库中读取当天的广告目标和昨天的结论。
从数据快照中测量每个产品池的漏斗费率(感知截断和样本量)。
重新计算该产品真实的
Stop/GoalCPL,以及与假设基线(assumed baseline)的偏差。诊断一个产品表现远超预期的原因——不同起因对应不同的解决策略——并推荐下一步行动。
根据修正后的界限审计当天拟定中的广告决策。
将校准后的结论及其证据链写回仓库。
每一步都依赖上一步的输出:仓库的内容决定测量什么,测量决定修正后的边界,边界决定拟定决策被成立还是被推翻。
自定义工具
工具 | 职责 |
| 单个产品的实测通过率 / 买断率 / 退货率,包含队列截断和样本量门槛。主要数据源工具。 |
| 根据实测比例重新计算真实 |
| 定位失败的具体类型——页面吸引力弱、竞价不足、素材疲劳、结构性亏损——并返回对应的下一步动作。 |
| 校验拟定决策是否在修正后的所得边界内;返回 |
完整的输入/输出模式、错误条件、副作用和运行示例:docs/tool-contracts.md。
为什么是这四个工具、它们为什么位于 MCP 边界,以及设计上放弃了些什么:docs/design-rationale.md。
数据源
一个本地、匿名化的历史订单队列快照数据集,由业务 CRM 导出,生成脚本为 scripts/export_snapshot.py。运行时无需身份验证和任何外部网络访问,从而演示结果具有确定性且可复现。
所有个人可识别信息——客户姓名、电话号码、地址、运单号——在导出时都被去除。快照只保留校准所需的字段:产品编码、订单状态、时间戳、金额以及对应订单的价值。匿名化策略和数据模式请见 data/README.md。
快速上手
前置条件: Python ≥ 3.11 和 uv。只有运行智能体流程时才需要安装了 Local REST API 插件的 Obsidian,而运行服务器本身则不需要。
git clone https://github.com/denkor1015-debug/funnel-calibrator.git
cd funnel-calibrator
uv sync以独立模式运行 MCP 服务器(它通过 stdio 使用 MCP 协议,并等待客户端连接):
uv run funnel-calibrator使用 MCP Inspector 以交互方式查看暴露的工具:
npx @modelcontextprotocol/inspector uv run funnel-calibrator配置从环境变量读取;复制模板并编辑:
cp .env.example .env两个 MCP 连接的 Agent 配置: agent/mcp_config.example.json。
仓库结构
src/funnel_calibrator/ MCP server: tool definitions, calibration math, policy engine
scripts/ snapshot exporter (CRM ──► anonymised local dataset)
data/ snapshot dataset + anonymisation policy
docs/ tool contracts, design rationale, defence checklist
agent/ MCP client configuration for both connections
tests/ unit tests for calibration and policy logic构建计划
仓库脚手架、架构和设计准入
带 PII 剔除的快照导出器
measure_sku_funnel——截断与样本量门槛recalibrate_cpl_silhouette——重新计算单位经济recommend_next_action——失效原因诊断audit_ad_verdict——决策审计Obsidian MCP 集成与端到端智能体流程
失败路径处理与演示
工具契约文档与答辩脚本
作业要求对照表
要求 | 对应位置 |
Part A——已经被批准的现有 MCP 服务器 | Obsidian Local REST API;契约见 |
Part B——自编 MCP 服务器,并且 ≥ 3 个实质性工具 |
|
Part C——工具契约文档 |
|
Part D——具备可运行性要求 | 无机密提交;采用环境变量配置;本地数据集运行时无需网络连接 |
设计说明 |
|
答辩脚本 |
|
许可证
MIT——见 LICENSE。
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityNot gradedmaintenanceEnables comprehensive management of Google Ads accounts by allowing users to create campaigns, manage keywords, and generate performance reports through a context-aware interface. It features a three-layer architecture that integrates product knowledge and historical campaign data to support intelligent decision-making.
- AlicenseAqualityBmaintenanceEnables AI agents to access website analytics, including visitor sessions, UX friction, conversion funnels, and anomaly alerts.6MIT
- AlicenseAqualityAmaintenanceReal-time Amazon Sponsored Products (SP) ad placements, keyword tracking, and comprehensive review data for AI Agents. Enables LLMs to autonomously conduct competitor ad audits, consumer sentiment analysis (VOC), and product optimization.196MIT
- FlicenseNot gradedqualityCmaintenanceExposes product analytics metrics from an internal data warehouse via MCP, enabling agents to query metrics, product summaries, and event breakdowns.
Related MCP Connectors
Revenue-first analytics installed and verified by AI agents through Talivia
271 agent-payable tools: competitive intel, finance, KYC, compliance, ESG. x402 per-call.
AI marketing agent for Google Ads, Meta, GA4, TikTok, LinkedIn, Shopify, HubSpot and more.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/denkor1015-debug/funnel-calibrator'
If you have feedback or need assistance with the MCP directory API, please join our Discord server