ai-berkshire: Instructions file for Claude Code

CLAUDE.md

ai-berkshire CLAUDE.md is an instructions file for Claude Code from xbtlin/ai-berkshire. It costs 1,799 tokens per session, scanned A, original, MIT.

A Claude Code guide for AI Berkshire, a collection of investment-research workflows based on several investing frameworks. It describes the report folders and naming patterns for different research tasks.

In plain words
What is it for?
Use it when creating investment-team reports, company research, checklists, management analysis, industry studies, or other reports that must follow the repository’s folder and filename conventions.
Why use it?
It makes research files easier to find and keeps reports organized consistently across companies, industries, portfolios, and comparison studies.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md. Also seen: reads .claude/ paths; mentions Claude Code.

This is xbtlin/ai-berkshire's own configuration. It tells Claude Code how to work on ai-berkshire itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything ai-berkshire configures →

About the project

AI Berkshire is a collection of Claude Code and Codex skills that structures investment research around the methods of four value-investing thinkers and uses multiple agents for adversarial analysis. It is intended for investors who want a disciplined process for researching companies and making valuation-based decisions.

xbtlin/ai-berkshire · 16,258 stars · on GitHub

Reuse

Borrowing it

Nothing to install: this file belongs to xbtlin/ai-berkshire. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/xbtlin/ai-berkshire/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/xbtlin/ai-berkshire

Made for: Claude Code.

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 ai-berkshire CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/xbtlin/ai-berkshire/claude-md/github.svg)](https://agentmods.dev/instructions/xbtlin/ai-berkshire/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/xbtlin/ai-berkshire/claude-md"><img src="https://agentmods.dev/badge/instructions/xbtlin/ai-berkshire/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ai-berkshire CLAUDE.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/xbtlin/ai-berkshire/claude-md"><img src="https://agentmods.dev/badge/instructions/xbtlin/ai-berkshire/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,799 This file is loaded in full into every session.
When invoked 1,799 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.01799 $0.01799
Opus 5 $0.00899 $0.00899
Sonnet 5 $0.00360 $0.00360
Haiku 4.5 $0.00180 $0.00180

Measured 3d ago against content hash 197d07f02360, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

ai-berkshire CLAUDE.md 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 3d 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.

CLAUDE.md · 124 lines

How it starts

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

AI Berkshire — 项目指令

项目概述

基于 Claude Code 的价值投资研究 Skill 合集。四大师框架:巴菲特、芒格、段永平、李录。 GitHub: xbtlin/ai-berkshire

项目结构

skills/          — 投研 Skill 定义(.md),复制到 ~/.claude/commands/ 使用
tools/           — 辅助工具(financial_rigor.py 精确计算、twstock_data.py 台股FinMind取数)
reports/         — 投资研究报告输出
assets/          — 图片等静态资源

报告目录结构

所有报告按公司名建文件夹,公司相关的所有报告放在对应文件夹内:

reports/
├── AI产业研究/              — AI产业链全景研究(置顶)
│   ├── AI五层蛋糕-产业全景研究-20260605.md
│   └── AI五层蛋糕-公众号-20260605.md
├── 腾讯/                    — 腾讯所有研究报告
│   ├── 腾讯-research-20260408.md
│   ├── 腾讯-earnings-2025Q4.md
│   ├── 腾讯-management-20260409.md
│   └── 腾讯-thesis.md
├── 拼多多/                  — 拼多多所有研究报告
├── 泡泡玛特/                — 泡泡玛特所有研究报告
├── 核电-industry-20260409.md — 行业报告放根目录
├── AI算力-funnel-20260509.md  — 漏斗筛选报告放根目录
├── AI-轮动判断-20260509.md    — 主题级综合判断报告放根目录
├── portfolio-latest.md       — 组合报告放根目录
└── 多公司对比-checklist-20260408.md — 多公司报告放根目录

报告命名规范

Skill 文件命名格式 示例
/investment-team {公司名}/ 目录内含4个视角+最终报告 reports/拼多多/最终报告.md
/investment-research {公司名}-research-{YYYYMMDD}.md reports/腾讯/腾讯-research-20260408.md
/investment-checklist {公司名}-checklist-{YYYYMMDD}.md reports/腾讯/腾讯-checklist-20260408.md
/industry-research {行业名}-industry-{YYYYMMDD}.md(根目录) reports/核电-industry-20260409.md
/industry-funnel {行业名}-funnel-{YYYYMMDD}.md(根目录) reports/AI算力-funnel-20260509.md
/private-company-research {公司名}-private-{YYYYMMDD}.md reports/字节跳动/字节跳动-private-20260408.md
/earnings-review {公司名}-earnings-{期间}.md reports/腾讯/腾讯-earnings-2025Q4.md
/earnings-team {公司名}/ 目录内含4个大师视角+研究底稿+公众号文章+读者评审 reports/腾讯/腾讯-earnings-2025Q4.md(公众号定稿)
/thesis-tracker {公司名}-thesis.md(长期维护) reports/腾讯/腾讯-thesis.md
/portfolio-review portfolio-latest.md(根目录,持续更新) reports/portfolio-latest.md
/management-deep-dive {公司名}-management-{YYYYMMDD}.md reports/腾讯/腾讯-management-20260409.md

Read the full file on GitHub · 124 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. 3d ago Changed · +11 lines · +199 tokens per session 197d07f02360
  2. 10d ago First seen · 113 lines · 1,600 tokens per session scan A caf69557c004

Subscribe to this mod's changes

ai-berkshire CLAUDE.md is an instructions file published in the GitHub repository xbtlin/ai-berkshire (16,258 stars, last pushed 2d ago), licensed MIT. It adds 1,799 tokens to every session, about $0.0090 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-30.

Related

Other instructions, from other repositories

next.js AGENTS.md

AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.

vercel/next.js · 7,296 tokens

codex AGENTS.md

AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.

openai/codex · 5,153 tokens

vscode buildNext.instructions.md

Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).

microsoft/vscode · 6,785 tokens

spec-kit AGENTS.md

AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.

github/spec-kit · 7,104 tokens

vscode oss-third-party-notices.instructions.md

Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).

microsoft/vscode · 5,001 tokens

langchain AGENTS.md

AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.

langchain-ai/langchain · 4,469 tokens