agentleFS
zerlinpizerlinpi/amazon-ads-skills/skills/anomaly-detection/SKILL.md

anomaly-detection

Skill8 starsChanged 53 days agoMITView on GitHub

Detect unexplained anomaly signals and alert-worthy Amazon Ads metric movements against historical baselines, separating true anomalies from promotions, inventory, pricing events and normal variance before escalation. 中文:用于异常信号识别、告警分级和误报过滤,不替代深度根因诊断。

9 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

1 rule. 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 6 edited versions we read keep these.

  • 0

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    When a conclusion depends on live MCP/API/connector data, load ../../references/connector-capability.md before interpreting missing or …

    line 18

“Common” is measured: kept by at least 6 in 10 of the 6 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Anomaly Detection

Connector capability gate

When a conclusion depends on live MCP/API/connector data, load ../../references/connector-capability.md before interpreting missing or empty fields. If a machine-readable capability snapshot is available, identify the exact required capability IDs and run ../../scripts/evaluate_connector_capability_gate.py before metric interpretation.

  • Pass — continue with the Skill's normal evidence, sufficiency, lineage and safety checks.
  • Degraded — do not make a high-confidence dependent recommendation; keep the result to Directional, Hold, Alternate Source, Missing Data, or Manual Review.
  • Blocked — do not treat the dependent observation as action-safe until the capability is resolved or an allowed alternate source is verified.
  • missing_evidence_policy = never_zero — Partial, Unsupported, Unknown, or absent connector capability is never a numeric zero, unchanged state, or proof that the platform lacks the feature.

This gate is read-only and does not authorize live Amazon Ads mutation.

目标

检测“值得行动”的变化,而不是简单比较今天和昨天。

Routing boundary

  • 这是异常信号判定 / 告警 triage Skill:回答“这个变化是否真的异常,还是活动、库存、价格、季节或数据问题可以解释”。
  • 如果任务只是例行扫描多个 Campaign 的健康状态、Watch/Critical watchlist 或周趋势监控,交给 ../campaign-health-monitor/SKILL.md。
  • 如果异常已经表现为 sustained business-impact decline,而且用户要知道“为什么下降、损失从哪里来、哪一个原因最有证据”,升级到 ../performance-drop-diagnosis/SKILL.md。
  • 异常本身不是动作授权;即使 severity 为 Critical,也不直接推导 bid/budget/negative/placement 变更。

输入

最低要求:

  • 当前观察窗口;
  • 历史基线窗口;
  • impressions、clicks、spend、orders、sales;
  • date/marketplace/currency。

推荐:

  • CPC/CTR/CVR/ACOS/ROAS;
  • budget status;
  • placement/search term;
  • price、promotion、inventory、Buy Box、Listing 状态;
  • 近期优化动作日志。

基线选择

优先:

  1. 同一实体过去 4-8 周滚动分布;
  2. 同星期/同 daypart 可比窗口;
  3. 同季节历史;
  4. 相似实体代理基线。

流量很低时不要使用过度精确的统计结论。

检测维度

  • Delivery anomaly:impressions/clicks 突降;
  • Cost anomaly:CPC/spend 激增;
  • Conversion anomaly:CVR/orders/sales 异常下滑;
  • Efficiency anomaly:ACOS 恶化或 ROAS 下滑;
  • Budget anomaly:过早耗尽或意外不花费;
  • Mix anomaly:placement/search-term 流量结构改变。

去误报检查

发现异常后,先检查:

  • Prime Day / Best Deal / Lightning Deal / Coupon;
  • 价格变化;
  • 库存/Buy Box/Listing;
  • campaign/bid/budget 最近刚调整;
  • 新品刚上线;
  • 归因延迟;
  • 周末/节假日/季节性;
  • 数据管道缺数。

如果变化能被事件解释,标记 explained_event,而不是 Critical anomaly。

Severity

Info

偏离较小或样本低,只记录趋势。

Watch

偏离值得关注,但需更多数据确认。

Critical

满足:

  • 偏离显著;
  • 业务影响较大;
  • 样本充分或持续多个窗口;
  • 无已知合理事件解释。

Critical 只表示值得优先升级调查,不等于已经完成 sustained decline 的因果归因。需要深度损失桥接、控制变更、零售状态与证据强度判断时交给 performance-drop-diagnosis。

根因树

例如 sales 下降:

Sales ↓
├─ Traffic ↓ ?
│  ├─ Impressions ↓
│  └─ CTR ↓
└─ Conversion ↓ ?
   ├─ CPC ↑ → clicks 减少
   ├─ CVR ↓
   ├─ Price/Promotion changed
   ├─ Inventory/Buy Box issue
   └─ Search term / placement mix changed

该树用于 anomaly triage 和下一步路由,不把“possible cause”自动升级成确认根因。

输出格式

每个异常:

  • entity;
  • severity;
  • metric;
  • current vs baseline;
  • duration;
  • estimated business impact;
  • possible causes;
  • event/confounder checks;
  • confidence;
  • recommended investigation/action;
  • next validation time/window。

如果异常已经 sustained 且业务影响明确,输出中应标记 escalate_to: performance-drop-diagnosis,而不是在 anomaly Skill 内继续扩展为完整深度诊断。

自动化约束

异常检测可以触发其他 Skills,但不直接触发真实账户写入。即便 severity=Critical,也先生成 Suggest/Shadow 动作并通过 ../../references/decision-boundaries.md。

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.