segmental-model

segmental-model is a command for Claude Code from godisego/hot-money. It costs 44 tokens per session (1,357 once invoked), scanned A, a copy of segmental-model, MIT.

A command for building a company's revenue forecast from separate business lines instead of using one growth rate for the whole company. It models three scenarios over three years and checks the total against current revenue.

In plain words
What is it for?
Use it to split a stock's company into three to five segments, assign each segment its own drivers and scenarios, project revenue, and compare the result with a top-down discounted-cash-flow model.
Why use it?
A single company-wide growth rate can hide very different trends in products, regions, or business lines, especially during a change in business mix.

Command for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is python skills/deep-analysis/scripts/compute_segmental.py discover <ticker>.

Part of the stock-deep-analyzer plugin — 4 skills, 15 commands, 1 agent, 1 hook shipped together

Good fit Use it to split a stock's company into three to five segments, assign each segment its own drivers and scenarios, project revenue, and compare the result with a top-down discounted-cash-flow model.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/godisego/hot-money
agentmods
npx agentmods add commands/godisego/hot-money/segmental-model

Made for: Claude Code.

Or install stock-deep-analyzer, the plugin that ships this one along with the rest of its 4 skills, 15 commands, 1 agent, 1 hook.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for segmental-model

README.md
[![agentmods](https://agentmods.dev/badge/commands/godisego/hot-money/segmental-model.svg)](https://agentmods.dev/commands/godisego/hot-money/segmental-model)
Your own site
<a href="https://agentmods.dev/commands/godisego/hot-money/segmental-model"><img src="https://agentmods.dev/badge/commands/godisego/hot-money/segmental-model.svg" alt="Measured on agentmods" height="20"></a>
Per session 44 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,357 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 92% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00044 $0.01357
Opus 5 $0.00022 $0.00678
Sonnet 5 $0.00009 $0.00271
Haiku 4.5 $0.00004 $0.00136

Measured 7d ago against content hash 38e09c8cf674, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

segmental-model scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

92% identical to segmental-model — 2 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

commands/segmental-model.md · 112 lines

How it starts

The opening of the file, as written. The whole thing — 112 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/segmental-model <股票代码或名称>

对目标股票做 bottom-up 分业务收入模型,跟自上而下的 DCF 互补校验。

为什么需要这个方法

现有 17 种机构方法里,DCF/3-statement/IC Memo 都是 top-down——从整体营收 × 单一增速假设推未来。遇到业务结构在转型的公司就失真:

  • 贵州茅台 直销比例 17% → 目标 50%+
  • 宁德时代 动力电池 vs 储能 vs 海外 三条曲线增速完全不同
  • Credo 收购 SiPh 后,Optics 线增速和 AEC 线差两倍

单一营收增速掩盖了这些分化。本方法把公司拆 3-5 条业务线,每条独立给 driver,三情景 3 年 projection,总量必须对账回当前营收。

工作流(agent 必须走完 5 步)

Step 1 · 生成骨架(脚本)

python skills/deep-analysis/scripts/compute_segmental.py discover <ticker>

5_chain.breakdown_top + 1_financials.revenue_history + 15_events,产出 .cache/<ticker>/segmental_skeleton.json

{
  "ticker": "600519.SH",
  "name": "贵州茅台",
  "currency": "CNY",
  "total_revenue_latest_yi": 1721.4,
  "segments": [
    {"name": "茅台酒", "latest_revenue_yi": 1460.3, "latest_share_pct": 84.83, ...},
    {"name": "系列酒", "latest_revenue_yi": 246.0, "latest_share_pct": 14.29, ...}
  ],
  "inflection_candidates": [
    "直销渠道占比持续提升",
    "1935 新品上市拓展年轻客群"
  ]
}

Step 2 · 读骨架 + 识别核心 thesis(agent)

Agent 必做:

  1. 打开 .cache/<ticker>/segmental_skeleton.json
  2. 结合 6_research.reports(卖方研报对业务分段的看法)+ 14_moat + 13_policy
  3. 识别 核心 inflection(1-2 条)——例如:
    • 茅台 = "直销占比 17% → 50%+"
    • 宁德 = "海外储能 0 → 30%+"
    • Credo = "copper → SiPh optics"
  4. 围绕 inflection 组织 segment 叙事

Step 3 · 填 driver(agent)

对每个 segment 写:

  • drivers: 价 × 量 × 市占 × 渗透 —— 至少列 2 个
    • ✓ 好例子:["ASP +5%/年", "shipment +20%/年"]
    • ✗ 坏例子:["行业景气"]
  • thesis_tag: growth_engine / cash_cow / declining / cyclical / turnaround
  • bull_growth_3y_cagr / base_growth_3y_cagr / bear_growth_3y_cagr 必须满足 bull ≥ base ≥ bear

Step 4 · 写回 + 校验(脚本)

.cache/<ticker>/segmental_model.json,然后:

python skills/deep-analysis/scripts/compute_segmental.py validate <ticker>

校验规则:

  • 🔴 sum(segment.latest_revenue) 必须对账回 total_revenue ±10%
  • 🔴 每个 segment bull ≥ base ≥ bear 单调
  • 🟡 Base 情景 3 年总增速 > 100% 需要明确收购/新业务 note
  • 🟡 每个 segment 必须有 ≥ 1 个 driver

Read the full file on GitHub · 112 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 112 lines · 44 tokens per session scan A 38e09c8cf674

Subscribe to this mod's changes

segmental-model is a command published in the GitHub repository godisego/hot-money (2 stars, last pushed 4mo ago), licensed MIT. It adds 44 tokens to every session and 1,357 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 92% identical to segmental-model, differing in 2 lines, and is treated as a copy.