Skip to content

Latest commit

 

History

History
116 lines (83 loc) · 5.52 KB

File metadata and controls

116 lines (83 loc) · 5.52 KB

AI Berkshire Codex Project Guide

This is the English operating guide for using AI Berkshire in Codex. It replaces the need to read the upstream Chinese CLAUDE.md during normal Codex work.

Project Overview

AI Berkshire is a value-investing research skill collection originally built for Claude Code. It uses four investment perspectives:

  • Warren Buffett: business quality, cash generation, valuation, margin of safety
  • Charlie Munger: industry structure, incentives, inversion, failure modes
  • Duan Yongping: business essence, consumer value, simplicity, long-term compounding
  • Li Lu: long-term certainty, risk control, management quality, downside protection

Project Structure

skills/          Original upstream Claude Code skill definitions in Chinese
codex/skills-en/ English Codex operational skill instructions
tools/           Helper tools, including financial verification and report audit
reports/         Research report outputs
assets/          Images and static assets
docs/            User-facing documentation

Report Placement

Company-specific reports should go under reports/{company_name}/ when the work is clearly about one company.

Industry, theme, funnel, portfolio, and multi-company reports can stay at reports/ root unless an existing folder already fits better.

Use the existing repository style when a matching folder already exists. Do not move old reports merely to normalize structure.

Report Naming

Use these naming patterns unless the user asks for a different file name:

Skill Naming Pattern Example
investment-team reports/{company}/ with role files and final report reports/PDD/final-report.md
investment-research {company}-research-{YYYYMMDD}.md reports/Tencent/Tencent-research-20260626.md
investment-checklist {company}-checklist-{YYYYMMDD}.md reports/Tencent/Tencent-checklist-20260626.md
industry-research {industry}-industry-{YYYYMMDD}.md reports/nuclear-power-industry-20260626.md
industry-funnel {industry}-funnel-{YYYYMMDD}.md reports/ai-compute-funnel-20260626.md
private-company-research {company}-private-{YYYYMMDD}.md reports/ByteDance/ByteDance-private-20260626.md
earnings-review {company}-earnings-{period}.md reports/Tencent/Tencent-earnings-2026Q1.md
thesis-tracker {company}-thesis.md reports/Tencent/Tencent-thesis.md
portfolio-review portfolio-latest.md reports/portfolio-latest.md
management-deep-dive {company}-management-{YYYYMMDD}.md reports/Tencent/Tencent-management-20260626.md

For Korean company or industry names, using Korean file names is acceptable when that is clearer for the user. For operational examples and generated scaffolding, prefer English names.

Investment Research Rules

  • Base analysis on facts and data. Do not start from a bullish or bearish conclusion.
  • Separate confirmed facts, estimates, and opinions.
  • Label uncertain claims clearly as estimates, assumptions, or open questions.
  • Every major judgment should include the strongest opposing evidence.
  • Do not use vague confidence language when data is missing. Say what is missing.
  • Current prices, financial data, news, policy, executive changes, product information, and regulations must be checked with up-to-date web sources.
  • Key financial data should be checked against at least two independent sources when possible.
  • Do not present the output as personalized financial advice.

Report Language

  • Respond to the user in Korean by default.
  • Keep Codex operating instructions and tool-facing text in English.
  • If the user asks for a report, write the report in Korean unless the user requests English or another language.
  • Preserve original Chinese upstream files and historical reports unless the user explicitly asks to translate those assets.

Team Workflows

Some upstream skills assume Claude Code Team or Task tools. In Codex:

  • Use subagents only when available and useful.
  • If equivalent subagents are unavailable, perform each role sequentially in the same conversation.
  • Clearly label role sections, such as Business Model, Financial Valuation, Industry Competition, and Risk/Management.
  • Combine the role outputs into a final judgment that separates facts, estimates, and opinions.

Financial Verification

Use tools/financial_rigor.py for exact calculations:

python3 tools/financial_rigor.py verify-market-cap \
  --price 510 \
  --shares 9.11e9 \
  --reported 4.65e12 \
  --currency HKD

Use tools/report_audit.py for sampled report data checks:

python3 tools/report_audit.py extract --report reports/example.md --dry-run

Market cap must be manually checked as:

stock price x shares outstanding = calculated market cap

Always state currency and unit, especially HKD, CNY, USD, shares, millions, billions, and hundred-million units.

Git Rules

  • Do not commit, push, or open a pull request unless the user explicitly asks.
  • If the user asks to publish changes, inspect git status first and avoid including unrelated files.
  • Do not push intermediate scratch files unless the user specifically wants them preserved.

Upstream Compatibility

  • Treat skills/*.md, CLAUDE.md, and historical Chinese reports as upstream reference material.
  • Treat codex/skills-en/*.md, this file, and AGENTS.md as the active Codex operating layer.
  • Interpret upstream ~/ai-berkshire paths as /Users/kangmingyu/dev/ai-berkshire.
  • Interpret upstream WebSearch references as the currently available web search tools.