capital-flow

A stock-selection model that estimates whether money is flowing into or out of shares by combining trading volume with price changes. It can use daily data or more detailed minute-by-minute trading data.

In plain words
What is it for?
Use it to calculate net money flow, rank stocks, filter a stock universe, build equally weighted portfolios, and set review periods of roughly one to three months.
Why use it?
It provides a way to examine buying and selling pressure, while highlighting that results can be distorted by low trading activity, very frequent data, or the stock-price trend itself.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/feicoder/skill-factory/capital-flow
Any agent
npx skills add FeiCoder/Skill-Factory --skill capital-flow
Clone the repo
git clone --depth 1 https://github.com/FeiCoder/Skill-Factory

Made for: Claude Code, Codex.

Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 931 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found 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 $0.00045 $0.00931
Opus 5 $0.00023 $0.00465
Sonnet 5 $0.00009 $0.00186
Haiku 4.5 $0.00005 $0.00093

Measured 2d ago against content hash 946bf0d15c79, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

capital-flow 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 2d 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.

produced_skill/stock-selection/capital-flow/SKILL.md · 124 lines

What it actually says

资金流选股

基本概念

资金流是反映股票供求关系的指标,能够观察微观市场交易者的真实意图及对股价的影响。

巴菲特的观点

"股市从短期看是投票机,从长期看一定是称重机"

资金流定义

资金流入:股价上涨时的成交额 资金流出:股价下跌时的成交额 资金净流量:流入 - 流出

计算公式

资金净流量 = Σ(Volume × sign(Pi - Pi-1))
其中:
- Volume: 成交量
- Pi: i时刻收盘价
- Pi-1: 上一时刻收盘价

资金流测算方法

1. 日数据法

  • 当日价格上涨全部计为流入
  • 价格下跌计为流出

2. 高频数据法(推荐)

使用高频数据(分钟级或更高)计算:

  • 成交价 ≥ 卖方最优价 → 流入
  • 成交价 ≤ 买方最优价 → 流出

招商资金流模型(CMSMF)

招商证券开发的资金流模型:

  • 采用高频数据
  • 以报价作为比较基准
  • 衍生指标:
    • 资金流信息含量
    • 资金流强度
    • 资金杠杆倍数

策略模型

逆向选择理论

A股市场存在信息不对称:

  1. 机构投资者率先对信息做出反应
  2. 羊群效应的散户投资者追涨杀跌
  3. 市场对信息反应过度

逆向选择策略

  • 卖出前期资金流入、价格上涨的股票
  • 买入前期资金流出、价格下跌的股票

选股步骤

  1. 确定股票池

    • 剔除上市不满1个月的股票
    • 剔除涨跌停及停牌的股票
    • 剔除信息含量<10%的股票
  2. 指标打分

    • 按各资金流指标排序
    • 百分制整数打分法
  3. 求和排序

    • 各指标得分求和
    • 选取排名靠前的N只股票
  4. 组合构建

    • 等量权重
    • 1-3个月定期调整

实证案例

沪深300股票池

资金规模 调仓周期 效果
1亿 1个月 较好
3亿 3个月 最佳
10亿 1个月 一般

全市场股票池

资金规模 调仓周期 效果
1亿 1个月 较好
3亿 1个月 最佳(全市场小盘股波动大)

注意事项

  1. 高频依赖性:资金流指标对高频数据有依赖性
  2. 信号钝化:超高频下计算结果可能钝化
  3. 同步指标:资金净流入与股价上涨高度相关
  4. 异常处理:小盘股、低成交量时可能失真

实践建议

  • 选择合适的资金流测算频率(日/周/月)
  • 结合其他因子使用
  • 考虑资金规模对流动性的影响
  • 设置合理的调仓周期

适用场景

  • 短线交易选股
  • 市场情绪判断
  • 机构资金动向跟踪
  • 配合多因子模型使用
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. 2d ago First seen · 124 lines · 45 tokens per session scan A 946bf0d15c79

Subscribe to this mod's changes

capital-flow is a skill published in the GitHub repository FeiCoder/Skill-Factory (10 stars, last pushed 6mo ago), licensed MIT. It adds 45 tokens to every session and 931 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

twitter-reader

Read Twitter/X for financial research using opencli (read-only). Use this skill whenever the user wants to read their Twitter feed, search for financial tweets, view bookmarks, look up user profiles, or gather market sentiment from Twitter/X. Triggers include: "check my feed", "search Twitter for", "show my…

himself65/finance-skills · 161 tokens

chenhao-limit-up

Use when evaluating A-share limit-up (涨停板) setups through Chen Hao's sentiment and momentum lens: market emotion cycles, board strength, follow-through, and short-term aggressive momentum trading.

questflowai/investorskills · 44 tokens

copy-trading-solana

Copy trade Solana wallets - mirror trades automatically.

alsk1992/CloddsBot · 15 tokens

southwest

Search Southwest Airlines fares and points pricing via Patchright browser automation. SW is not in any GDS or API. Covers all fare classes, Companion Pass value, and fare drop monitoring.

borski/travel-hacking-toolkit · 40 tokens

alpaca-trade-api-sdk

Integrate and build on the @alpacahq/alpaca-trade-api TypeScript SDK for the Alpaca Trading and Market Data APIs (the unified Alpaca client, ergonomic order builders, normalized market-data shapes, pagination, typed errors, resilience, and real-time streaming). Use when writing or reviewing code that imports…

alpacahq/alpaca-trade-api-js · 123 tokens

alphagbm-greeks

Greeks dashboard for any option contract or multi-leg position. Covers first-order Greeks (Delta, Gamma, Theta, Vega, Rho) and second-order Greeks (Charm, Vanna, Volga). Returns individual and position-level Greeks with scenario heatmaps. Use when: checking option sensitivities, managing position risk, understanding…

AlphaGBM/skills · 128 tokens