SuperAPI AI Directory

trend-analysis

Data & analytics

View repository

Updated 10-16 08:43

About this skill

Load context

On first use: Read ../../CLAUDE.md to obtain scenario-level configuration (historical data sources/seasonality definitions/forecasting models).


/trend-analysis — Trend analysis

Examples

→ Example: The user says "Help us analyze the trend of gross margin over the past three years and identify the structural causes"; the system should invoke this skill to perform trend decomposition and attribution analysis.

→ Example: The user says "Supplier concentration is rising; help me do a trend analysis of this risk"; the system should invoke this skill to perform supply risk trend analysis.

→ Example: The user says "The market share of our main products has been declining for consecutive periods, and we need a trend report for the board of directors"; the system should invoke this skill to generate a market share trend report.

Step 1: Data acquisition and preparation

Data extraction:

□ 数据来源:[BI 系统/ERP/财务系统]
□ 分析对象:[指标名称,如"收入"]
□ 分析维度:[按月/按季/按年]
□ 分析期间:[YYYY-MM 至 YYYY-MM]([X] 期数据点)
□ 粒度:[月度/季度/年度]
□ 数据记录数:[X] 条

Data quality check:

□ 缺失值:[X] 期 — 处理方式 [插补/删除区间]
□ 异常值:[X] 个 — [描述]
□ 数据可比性:[✅ 一致(口径未变)/ ⚠️ 口径变化 [描述]]
□ 总体质量:[✅ 高 / ⚠️ 中 / 🔴 低]

Step 2: Trend decomposition

Time series decomposition model:

□ 分解方法:[加法模型(Y = T + S + C + I)/ 乘法模型(Y = T × S × C × I)]
□ 选择依据:[数据特征]

□ 趋势成分(T, Trend):
  → 长期增长/下降方向:[上升/下降/平稳]
  → 年均增速:[X]%(复利)
  → 趋势方程:[Y = [系数] × t + [截距]](如线性拟合)

□ 季节成分(S, Seasonality):
  → 季节模式:[有/无] — [描述]
  → 旺季:[Q4/月12/月1/月2](收入最高)
  → 淡季:[Q1/月1/月2/月3](收入最低)
  → 季节波动幅度:[X]%(旺季 vs 淡季均值差异)

□ 周期成分(C, Cycle):
  → 周期长度:[X] 年(经济周期/行业周期)
  → 当前所处周期位置:[复苏/繁荣/下行/触底]

□ 不规则成分(I, Irregular):
  → 不规则波动幅度:[X]%(标准差/均值)
  → 是否存在显著异常:[是/否 — [描述]]

Step 3: Trend analysis

Historical trend statistics:

□ 增长/下降总结:
  → 分析期间总变化:[+X]%(从 [X] 到 [X])
  → 年均复合增长率(CAGR):[X]%
  → 最高点:[YYYY-MM] — 值 [X]
  → 最低点:[YYYY-MM] — 值 [X]

□ 阶段性分析:
  → 阶段 1([YYYY-Q1] 至 [YYYY-Q2]):
    · 趋势:[快速增长/稳定/下降]
    · 增速:[X]%(季环比)
    · 主要驱动:[因素]
  → 阶段 2:[...]

Seasonality analysis (if present):

□ 季节指数(以年度均值 = 100 为基准):
| 月份/季度 | 季节指数 | 说明 |
|-----------|---------|------|
| 1月/Q1   | [X]      | 低于均值 |
| 2月/Q1   | [X]      | 低于均值 |
| ...      | ...      | ...    |
| 12月/Q4  | [X]      | 高于均值 |

□ 季节性调整:
  → 原始值:[X] 万
  → 季节调整后:[X] 万(去除季节性影响)

Step 4: Forecasting modeling

Forecasting model selection:

□ 模型选择依据:[数据特征/样本量/预测长度]
□ 采用模型:[简单移动平均/指数平滑/Holt-Winters/线性回归]

□ 模型参数:
  → 移动平均期数(如适用):[X] 期
  → 趋势平滑系数(α):[X]
  → 季节平滑系数(β):[X]

□ 模型拟合度:
  → R²(决定系数):[X]
  → MAPE(平均绝对百分比误差):[X]%
  → RMSE(均方根误差):[X]

Future forecast:

□ 预测期间:[YYYY-MM 至 YYYY-MM]([X] 期)
□ 预测值:
| 期间 | 预测值 | 95% 置信区间 |
|------|--------|------------|
| [YYYY-MM] | [X] | [X-X] |
| [YYYY-MM] | [X] | [X-X] |

□ 趋势预测(季节调整后):
  → 未来 [X] 期趋势方向:[上升/下降/平稳]
  → 预测增速:[X]%(季环比/年环比)

Step 5: Anomaly detection

Anomaly point identification:

□ 识别方法:[3σ 原则/IQR 方法/统计检验]
□ 异常阈值:[X]%(偏离趋势 [X]% 以上)

□ 识别出的异常点:
| 期间 | 实际值 | 趋势预测值 | 偏离度 | 类型 |
|------|--------|-----------|--------|------|
| [YYYY-MM] | [X] | [X] | [+X]% | [高点/低点/异常] |

□ 异常原因分析(初步):
  → [异常点1]:[可能原因]
  → [异常点2]:[可能原因]

Step 6: Generate trend analysis report

═══════════════════════════════════════
趋势分析报告
分析对象:[指标名称]
分析维度:[按月/按季]
分析期间:[YYYY-MM 至 YYYY-MM]
生成时间:[YYYY-MM-DD HH:MM]
═══════════════════════════════════════

【趋势概览】
□ 长期趋势:[上升/下降/平稳] — 年均 [X]%
□ 季节性:[有(波动 [X]%)/无]
□ 周期:[有([X]年周期)/无]

【关键指标】
□ 分析期间起点值:[X]
□ 分析期间终点值:[X]
□ 总变化:[+X]%
□ CAGR:[X]%
□ 最高点:[YYYY-MM] — [X]
□ 最低点:[YYYY-MM] — [X]

【季节性】(如有)
□ 旺季:[Q4/月12]
□ 淡季:[Q1/月2]
□ 季节波动幅度:[X]%

【预测】
□ 模型:[方法]
□ 模型拟合度:R²=[X],MAPE=[X]%
□ 未来 [X] 期预测:
| 期间 | 预测值 | 置信区间 |
|------|--------|---------|
| [YYYY-Q1] | [X] | [X-X] |
| [YYYY-Q2] | [X] | [X-X] |

【异常点】
□ 识别 [X] 个异常点
□ 主要异常:[YYYY-MM] — 偏离 [X]% — 原因 [初步判断]

【趋势拐点信号】(如有)
□ [指标] 趋势由正转负/由负转正:[日期]
□ 结构性变化信号:[描述]

═══════════════════════════════════════
置信度:[✅ 高(基于 [X] 期数据)/ ⚠️ 中(数据较短)/ 🔴 低]
模型可靠性:[✅ 良好 / ⚠️ 存在异常点干扰]
═══════════════════════════════════════

Escalation trigger conditions

  • A trend inflection point is found (growth turns to decline or vice versa)
  • Forecasting model MAPE > [X]% (poor model fit)
  • Major anomaly points exist that affect trend judgment
  • The seasonal pattern changes (peak/off-season shifts)
  • A major deviation exists between the forecast value and the budget/target (> [X]%)
  • The cyclical component shows signals of an economic/industry cycle turning point

Finance Skills — trend-analysis atomic skill