Agent skill

Investment Thesis Tracker

by xbtlin in xbtlin/ai-berkshire

Builds a written investment thesis for a stock with sell conditions set before buying, then runs periodic checks of its core assumptions after each earnings report.

MITAuto-check passedBusiness, Finance & HR

SKILL.md written in Chinese; this summary is our English description.

Install Investment Thesis Tracker

skills CLI
$ npx skills add xbtlin/ai-berkshire --skill thesis-tracker -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install xbtlin/ai-berkshire thesis-tracker --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/xbtlin/ai-berkshire.git skills-src && mkdir -p .claude/skills && cp -r skills-src/codex-skills/thesis-tracker .claude/skills/thesis-tracker && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
thesis-tracker
GitHub stars
17k
Token cost
~1.3k tokens
SKILL.md length
440 words
Files
1
Skills in repo
22
Repo updated
First seen
Licence
MIT

At a glance

Builds a written investment thesis for a stock with sell conditions set before buying, then runs periodic checks of its core assumptions after each earnings report.

  • Works in 4 steps: 最新财报数据(如果有新的季报/年报) → 近期重大事件(管理层变动、监管政策、竞争动态) → 当前股价和估值指标 → …
  • Writing down why you bought a stock and when you would sell
  • SKILL.md covers Codex adapter note, 设计理念, 执行流程 and 模式A:建立投资论文, plus 2 more sections
  • Calls python3

What it does

The skill covers the work that follows a stock purchase. Given a company name, it checks whether a thesis file already exists in the reports folder: if not, it builds one, and if so, it runs a tracking check. Other inputs force a rebuild or run a quarterly check from the latest financial report. The premise is that sell conditions should be written down before buying, so holding decisions come from evidence rather than hope or panic.

Building a thesis starts with gathering the current price, valuation multiples and latest report figures, which a financial rigor script then verifies. The core thesis has to be answered in five one-sentence points and fit within 200 characters; if it cannot be written, the buy decision was unclear. It is then broken into three to seven verifiable assumptions, each with a verification method, a check frequency and a current status.

When your agent uses it

  • Writing down why you bought a stock and when you would sell
  • Running a quarterly check of a holding against its assumptions
  • Rebuilding a thesis that no longer matches the business
  • Keeping a disciplined record of assumptions and valuation anchors

Example prompts

  • “Set up an investment thesis for Meituan.”
  • “Run a quarterly check on my Tencent thesis using the latest earnings report.”
  • “Rebuild the thesis for Nvidia from scratch.”

Requirements

  • Web search access for prices and financial data
  • Python 3 for the tools/financial_rigor.py script

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. 最新财报数据(如果有新的季报/年报)
  2. 近期重大事件(管理层变动、监管政策、竞争动态)
  3. 当前股价和估值指标
  4. 内部人交易记录(大股东增减持)

What it can do on your machine

Read from SKILL.md and the folder at commit efa220f. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • python3

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Investment Thesis Tracker loads about 1.3k tokens when it runs. Until then it costs about 21 tokens; SKILL.md has 440 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~21
When it runs · the whole SKILL.md, loaded when a task matches
~1.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from xbtlin/ai-berkshire at commit efa220f, republished under its MIT licence (© xbtlin). 440 words, ~1,300 tokens.

Download SKILL.mdSave it as .claude/skills/thesis-tracker/SKILL.md (or your agent's skills folder).
name
thesis-tracker
description
AI Berkshire skill: 投资论文追踪:买入后的纪律系统. Source: skills/thesis-tracker.md.

Codex adapter note

This skill is generated from skills/thesis-tracker.md so Claude Code and Codex users share one canonical workflow.

  • Treat $ARGUMENTS as the user's request in the current Codex thread.
  • When the source mentions Claude-only surfaces such as Task, Agent, WebSearch, Bash, Read, or Write, use the closest Codex capability available in this session: subagents when available, web search when needed, shell commands for local tools, and normal file edits for workspace files.
  • Use shared project tools from tools/ in this repository. Prefer running commands from the repository root with paths like python3 tools/financial_rigor.py ...; if the current thread starts outside the repo, locate the actual checkout path first instead of assuming a fixed home-directory path.
  • Before starting research, run the date command to confirm today's date; treat it as the baseline for "latest" data and state the data cutoff date in the report header. Never assume the current date from training data.
  • Preserve the research quality rules from AGENTS.md: cross-check financial data, use exact arithmetic tools for valuation/math, and clearly label uncertainty and source gaps.

投资论文追踪:买入后的纪律系统

对 $ARGUMENTS 执行投资论文追踪检查。

支持输入格式:

  • 公司名 — 首次使用时建立投资论文,后续使用时追踪检查
  • 公司名 建立论文 — 强制重新建立投资论文
  • 公司名 季度检查 — 基于最新财报进行论文检查

"买入只是开始。真正的工作是持有期间的持续跟踪。" —— 李录

"当事实改变时,我就改变想法。你呢?" —— 凯恩斯

设计理念

大多数投资者的流程是:研究 → 买入 → 祈祷。缺少买入后的系统化跟踪,导致:

  • 该卖的时候舍不得卖("再等等,会涨回来的")
  • 不该卖的时候恐慌卖出("跌了20%,是不是我错了")
  • 忘记了当初为什么买的("我买这个是因为什么来着?")

巴菲特和李录的做法是:买入前就写下卖出条件。然后每个季度检查论文是否完整。

执行流程

第一步:判断操作模式

检查是否已存在该公司的投资论文文件(reports/{公司名}-thesis.md):

  • 如果不存在 → 进入建立论文模式
  • 如果存在 → 进入追踪检查模式
  • 如果找不到但用户表示已有 → 询问文件路径

模式A:建立投资论文

A0:数据收集

使用 WebSearch 获取当前股价、估值指标(PE/PB/股息率)、最新财报核心数据,用于填写估值锚点。如果已有该公司的 /investment-research 或 /investment-team 报告,优先从中读取。

使用 tools/financial_rigor.py verify-valuation 校验估值数据。

A1:核心论文(必须用200字以内写清楚)

投资论文必须回答以下5个问题,每个问题一句话:

我以 ___元 买入 ___公司,因为:
1. 这门生意的本质是___,我理解它的赚钱方式
2. 它的护城河是___,而且在变宽/稳定
3. 管理层___,值得信赖的原因是___
4. 当前价格相当于内在价值的___折,安全边际来自___
5. 即使我错了,下行风险可控,因为___

如果5句话写不完整,这个论文本身就有问题——说明买入决策不够清晰。

A2:核心假设清单

把投资论文拆解成可验证的具体假设:

#核心假设验证方式验证频率当前状态
1例:收入增速维持15%+季报收入增速每季度🟢 成立
2例:毛利率稳定在60%+季报毛利率每季度🟢 成立
3例:管理层持续回购回购公告/现金流表每季度🟢 成立
4例:竞争对手未取得突破行业数据/竞对财报每半年🟢 成立
5............

通常3-7个假设。太少说明思考不够深入,太多说明论文不够聚焦。

Show full SKILL.md (187 more words)Show less
A3:红线清单(触发任何一条 = 必须重新评估)
#红线条件严重程度触发后动作
1例:管理层诚信出问题(财务造假、关联交易)致命立即清仓
2例:核心业务连续2季度收入下滑严重减仓50%,重新评估
3例:护城河被明确突破(竞对获得同等能力)严重启动深度研究,考虑退出
4例:监管政策根本性改变商业模式严重重新评估内在价值
5例:管理层大规模减持(非计划性)警告深入调查原因

段永平:"卖出只有三个理由:1.发现买错了;2.公司基本面变了;3.找到了更好的。"

A4:估值锚点
指标买入时乐观目标中性目标悲观情景
股价
PE
市值
内在价值估算
安全边际
A5:保存论文

将投资论文写入 reports/{公司名}-thesis.md,包含:

  • 建立日期
  • 买入价格和仓位
  • 核心论文(5句话)
  • 核心假设清单
  • 红线清单
  • 估值锚点
  • 追踪记录表(初始为空)

模式B:追踪检查

B1:读取现有论文

读取 reports/{公司名}-thesis.md,加载:

  • 核心论文
  • 核心假设清单
  • 红线清单
  • 上次检查记录
B2:收集最新数据

使用 WebSearch 收集:

  1. 最新财报数据(如果有新的季报/年报)
  2. 近期重大事件(管理层变动、监管政策、竞争动态)
  3. 当前股价和估值指标
  4. 内部人交易记录(大股东增减持)
B3:逐条检查核心假设

对每个核心假设,用最新数据验证:

#核心假设上次状态最新证据当前状态变化
1收入增速15%+🟢 成立Q4收入增速12%🟡 边际弱化⚠️
2毛利率60%+🟢 成立毛利率61.2%🟢 成立—
3...............

状态定义:

  • 🟢 成立 — 最新数据支持该假设
  • 🟡 边际弱化 — 数据仍在可接受范围,但趋势不利
  • 🔴 受损 — 数据明确不支持该假设
  • ⚫ 破裂 — 假设已被推翻
B4:红线检查

逐条检查红线清单:

#红线条件是否触发证据
1管理层诚信问题❌ 未触发—
2核心业务连续2季下滑❌ 未触发—

任何一条红线触发 → 在报告中用醒目标注,给出明确的行动建议。

B5:估值更新
指标买入时上次检查当前变化
股价
PE(TTM)
内在价值估算
安全边际
B6:输出追踪报告
报告结构
一、论文健康度评分(满分10分)
二、核心假设检查结果(表格)
三、红线检查结果(表格)
四、本期关键变化(不超过500字)
五、估值更新
六、结论与行动建议
七、下次检查需关注的重点
论文健康度评分标准
评分含义建议动作
计算公式:健康度 = 10 - (⚫破裂假设数×3) - (🔴受损假设数×2) - (🟡弱化假设数×1) - (红线触发数×5),最低1分最高10分。
评分含义建议动作
9-10所有假设成立,论文比买入时更强考虑加仓
7-8核心假设成立,个别边际弱化继续持有
5-61-2个假设受损,但核心逻辑未变持有但提高警惕
3-4多个假设受损,论文基础动摇考虑减仓
1-2红线触发或核心假设破裂强烈建议卖出
结论必须明确回答
  1. 论文还完整吗? 完整 / 边际弱化 / 受损 / 破裂
  2. 该怎么做? 加仓 / 持有 / 减仓 / 清仓
  3. 下次检查时间:下一个季报发布后 / 某个特定事件后
B7:更新论文文件

将本次检查记录追加到 reports/{公司名}-thesis.md 的追踪记录表中:

检查日期健康度核心变化动作建议
2026-04-097/10收入增速放缓至12%,但利润率改善持有

关键原则

  • 买入前就写好卖出条件 — 冷静时做的决策比恐慌时做的好
  • 论文要具体到可验证 — "公司很好"不是论文,"ROE>25%且趋势稳定"才是
  • 红线一旦触发就行动 — 最怕的是"再等等看",这是亏大钱的开始
  • 论文破裂 ≠ 股价下跌 — 股价跌30%不一定要卖,论文破裂才要卖
  • 诚实面对错误 — 论文建错了就承认,不要为了面子硬撑

© xbtlin, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in codex-skills/thesis-tracker of xbtlin/ai-berkshire.

Open the folder on GitHubat commit efa220f

Compare with similar skills

Investment Thesis Tracker next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Investment Thesis Tracker compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Investment Thesis Tracker this skillxbtlin/ai-berkshire17k—~1.3kAutomated safety check: PassMIT
AI-Trader Market IntelHKUDS/AI-Trader23k—~1.1kAutomated safety check: PassNone
Eastmoney Market DataHKUDS/Vibe-Trading35k—~1kAutomated safety check: PassMIT
Stock Deep Analysis Workflowwbh604/UZI-Skill7.1k—~9.1kAutomated safety check: NotesMIT
Zhengxi Fund Manager Views Librarylyra81604/zhengxi-views1.7k—~1.6kAutomated safety check: PassMIT
SEC EDGAR Filings FetcherHKUDS/Vibe-Trading35k—~1.4kAutomated safety check: PassMIT

Similar skills

  • AI-Trader Market Intel

    HKUDS/AI-Trader

    Reads AI-Trader's read-only market snapshots, grouped financial news and events board through its market-intel endpoints, for context before trading or posting.

    23k GitHub stars~1.1k tokensUpdated 3 mo ago
    Business, Finance & HRAuto-check passed
  • Eastmoney Market Data

    HKUDS/Vibe-Trading

    Index of Eastmoney's free, no-token market data interfaces for China A-shares and Hong Kong stocks: fund flows, dragon-tiger lists, margin trading, reports and news.

    35k GitHub stars~1k tokensUpdated today
    Business, Finance & HRAuto-check passed
  • Runs a staged deep analysis of a single stock on China A-share, Hong Kong and US markets, ending in an HTML report with valuation models and investor-panel scores.

    7.1k GitHub stars~9.1k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check: notes
  • Zhengxi Fund Manager Views Library

    lyra81604/zhengxi-views

    Answers questions with sourced quotes from one Chinese fund manager's public writings, applies his stated investment method and compares his words with real fund holdings.

    1.7k GitHub stars~1.6k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check passed
  • SEC EDGAR Filings Fetcher

    HKUDS/Vibe-Trading

    Fetches U.S. SEC EDGAR data: resolves tickers to CIK numbers, lists recent 10-K, 10-Q and 8-K filings with document URLs, and pulls XBRL financial series.

    35k GitHub stars~1.4k tokensUpdated today
    Business, Finance & HRAuto-check passed
  • Longbridge Earnings

    helsome/folio

    Earnings analysis — pre- and post-earnings. An agent skill from helsome/folio.

    269 GitHub starsUsed in 1 repo~2.5k tokens
    Business, Finance & HRAuto-check passed

More from xbtlin/ai-berkshire

All 22 skills in this repo
  • Scans a long-running industry trend for supply chain chokepoints, aiming to find second- and third-layer suppliers that the market has not yet priced in.

    17k GitHub stars~2.6k tokensUpdated yesterday
    Auto-check passed
  • Deep Company Article Series

    xbtlin/ai-berkshire

    Plans and writes a three-to-eight-part long-form article series that breaks down one company, built on fact-checked financials, valuation and management analysis.

    17k GitHub stars~2k tokensUpdated yesterday
    Auto-check passed
  • Earnings Report Deep Reading

    xbtlin/ai-berkshire

    Reads a company's filings and earnings call material in depth, rates how complete the sources are and extracts the key figures into a structured review.

    17k GitHub stars~1.4k tokensUpdated yesterday
    Auto-check passed
  • Runs four parallel analyst personas over one earnings report, then an editor and reader-review pass turn the findings into a publishable article.

    17k GitHub stars~2.3k tokensUpdated yesterday
    Auto-check passed
  • A four-step research framework for finding and tracking high-growth core companies in one industry: map the sector, ask core questions, verify, then hold to the turning point.

    17k GitHub stars~974 tokensUpdated yesterday
    Auto-check passed
  • A research rule set for pulling company financials from prioritized sources by market and cross-checking every key figure against two independent sources.

    17k GitHub stars~1.4k tokensUpdated yesterday
    Auto-check passed

Questions about Investment Thesis Tracker

What does Investment Thesis Tracker do?

Builds a written investment thesis for a stock with sell conditions set before buying, then runs periodic checks of its core assumptions after each earnings report. The skill covers the work that follows a stock purchase. Given a company name, it checks whether a thesis file already exists in the reports folder: if not, it builds one, and if so, it runs a tracking check.

When should I use Investment Thesis Tracker?

Investment Thesis Tracker fits situations like: writing down why you bought a stock and when you would sell; running a quarterly check of a holding against its assumptions; rebuilding a thesis that no longer matches the business; keeping a disciplined record of assumptions and valuation anchors.

How do I install Investment Thesis Tracker in Claude Code?

Run `npx skills add xbtlin/ai-berkshire --skill thesis-tracker -a claude-code`. Or copy the skill folder (codex-skills/thesis-tracker in xbtlin/ai-berkshire) into .claude/skills/thesis-tracker in your project. Claude Code loads it when a task matches its description.

How do I install Investment Thesis Tracker in Codex?

Run `npx skills add xbtlin/ai-berkshire --skill thesis-tracker -a codex`. Or copy the skill folder (codex-skills/thesis-tracker in xbtlin/ai-berkshire) into .agents/skills/thesis-tracker in your project. Codex loads it when a task matches its description.

Can I use Investment Thesis Tracker in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add xbtlin/ai-berkshire --skill thesis-tracker -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/thesis-tracker, .gemini/skills/thesis-tracker, .github/skills/thesis-tracker and .opencode/skills/thesis-tracker in your project.

What does Investment Thesis Tracker need to run?

Going by SKILL.md and its folder, Investment Thesis Tracker needs the command-line tools its instructions call (python3). Our summary lists: Web search access for prices and financial data; Python 3 for the tools/financial_rigor.py script.

Does Investment Thesis Tracker access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Investment Thesis Tracker safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Investment Thesis Tracker use?

Investment Thesis Tracker is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Investment Thesis Tracker use?

About 1.3k tokens (SKILL.md is roughly 5.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Investment Thesis Tracker?

Skills that share tags, products or a category with Investment Thesis Tracker: AI-Trader Market Intel (HKUDS/AI-Trader, 23k stars), Eastmoney Market Data (HKUDS/Vibe-Trading, 35k stars), Stock Deep Analysis Workflow (wbh604/UZI-Skill, 7.1k stars) and Zhengxi Fund Manager Views Library (lyra81604/zhengxi-views, 1.7k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Investment Thesis Tracker?

xbtlin (a GitHub user) maintains it in xbtlin/ai-berkshire, which has 16,652 GitHub stars. The repository holds 22 skills in this directory. The repository was last updated on October 6, 2026.

Source: xbtlin/ai-berkshire on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.