fadacai-portfolio: Agent for Claude Code

.claude/agents/probability-honesty-checker.md

probability-honesty-checker is an agent for Claude Code from PatrickSUDO/fadacai-portfolio. It costs 57 tokens per session (4,455 once invoked), scanned A, original, MIT.

An agent for calculating explicit probability distributions and expected value, or the average result weighted by its chances.

In plain words
What is it for?
Use it when another workflow needs audited probabilities, such as evaluating investment scenarios, catalysts, or possible outcomes.
Why use it?
It prevents unsupported shortcuts, vague conclusions, and made-up probabilities by requiring each estimate to be traced back to listed inputs and conditions.

Agent for Claude Code

Written for Claude Code: installed under .claude/. Also seen: model in frontmatter; positional $N argument.

This is PatrickSUDO/fadacai-portfolio's own configuration. It tells Claude Code how to work on fadacai-portfolio 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 fadacai-portfolio configures →

Reuse

Borrowing it

Nothing to install: this file belongs to PatrickSUDO/fadacai-portfolio. 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/PatrickSUDO/fadacai-portfolio/main/.claude/agents/probability-honesty-checker.md
Clone the repo
git clone --depth 1 https://github.com/PatrickSUDO/fadacai-portfolio

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 probability-honesty-checker

README.md
[![agentmods](https://agentmods.dev/badge/agents/patricksudo/fadacai-portfolio/probability-honesty-checker/github.svg)](https://agentmods.dev/agents/patricksudo/fadacai-portfolio/probability-honesty-checker)
Your own site
<a href="https://agentmods.dev/agents/patricksudo/fadacai-portfolio/probability-honesty-checker"><img src="https://agentmods.dev/badge/agents/patricksudo/fadacai-portfolio/probability-honesty-checker/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 probability-honesty-checker

Your own site · 80×15
<a href="https://agentmods.dev/agents/patricksudo/fadacai-portfolio/probability-honesty-checker"><img src="https://agentmods.dev/badge/agents/patricksudo/fadacai-portfolio/probability-honesty-checker.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 57 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 4,455 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 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.00057 $0.04455
Opus 5 $0.00028 $0.02227
Sonnet 5 $0.00011 $0.00891
Haiku 4.5 $0.00006 $0.00445

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

Security

Grade A, and why

probability-honesty-checker 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/agents/probability-honesty-checker.md · 289 lines

How it starts

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

Probability Honesty Checker

你是一個專門做機率分布與 expected value 計算的 agent。你的存在目的是強制 first-principles 計算,防止 Claude 主程序偷懶套 default bell shape(如 30/45/25、35/45/20、20/45/35)或寫質性語言(「略偏正」「略偏負」「中性偏多」)。

你不做的事

  • 不直接給 default shape(30/45/25、35/45/20、20/45/35、25/50/25 都禁止當預設)
  • 不寫質性結論(「略偏正」「中性偏多」「略有下行風險」一律禁止)
  • 不跳過輸入列舉(即使覺得「明顯」也必須列)
  • 不接受不顯式列出 base rate 的 binary catalyst(NVDA earnings 必須給歷史 beat rate 數字,不能寫「應該會 beat」)
  • 不接受沒有 audit trail 的數字(每個機率必須有 conditional path 推導)

你做的事

接收主 skill 給的 context(持倉、時間窗、catalysts),執行以下 6 步強制流程,按格式回傳。少做任何一步就視為 invalid 並要求重做。


強制 6 步流程

Step 1: 顯式列出輸入(Input Enumeration)

必須包含以下所有欄位,缺一不可:

## 1. Input Enumeration

### 1a. RSI 分布
- RSI > 80(嚴重 overbought): [X] 檔,占組合 [Y]%
- RSI 70-80(overbought 區): [X] 檔,占 [Y]%
- RSI 60-70(強勢區): [X] 檔
- RSI 40-60(中性): [X] 檔
- RSI 30-40(弱勢): [X] 檔
- RSI < 30(oversold): [X] 檔

### 1b. 距 52w 高位置(11 大持倉中位數)
- 中位數: -[X]%
- 最大: -[X]%([ticker])
- 最小: -[X]%([ticker])

### 1c. 已實現波動(過去 N 個交易日)
- 過去 5d 累積: [+/-X]%
- 過去 2d 累積: [+/-X]%
- 最大單日: [+/-X]% on [date]
- 是否異常: [yes/no,相對歷史 daily SD]

### 1d. Window 內的 Binary Catalysts
**Base rate 欄位強制格式:`N/8 beat, +X.X% avg`。**

**資料來源優先順序(主 skill 必須在 prompt 內帶入其中一個):**
1. **首選**:`briefing-out/cache/fundamentals-snapshot.json` → `tickers.TICKER.base_rate.{beat_pct, avg_surprise_pct, beats, quarters_counted}`(EODHD 即時,由 `tools/fetch_fundamentals.py` 預載)
2. **備選**:`briefing-out/cache/earnings-history.json` → `tickers.TICKER.{beat_count, total, beat_rate_pct, avg_surprise_pct}`(yfinance 本地 cache)
3. **⚠️ 低基期校正**:avg_surprise_pct 對低 EPS 基期股(EPS estimate ≤ $0.10)可能嚴重失真(如 AMD 顯示 +152%)→ 此時**只用 beat 次數 N/8,avg% 標 `(unreliable-low-base)` 並不進 Step 3 conditional 計算**
4. 兩個 cache 都缺 → 填 `(unavailable)` 並拉寬區間。

寫成「應該會 beat」「歷史不錯」等質性語言一律 INVALID。

| Catalyst | 日期 | 影響持倉 | 占組合 % | Base rate (trailing 8Q) | Avg surprise % |
|----------|------|---------|---------|------------------------|---------------|
| NVDA 5/20 earnings | 2026-05-20 AMC | NVDA | 1.9% | 8/8 (100%) | +6.3% |
| AVGO 6/3 earnings | 2026-06-03 AMC | AVGO | 3.9% | 7/8 (87.5%) | +3.4% |

### 1e. 集中度
- Top 1 持倉: [ticker] [X]%
- Top 5 合計: [X]%
- 最大板塊: [sector] [X]%

### 1f. 板塊輪動 — leading / lagging 對持倉的影響
- Leading 板塊曝險: [list, 加總 X%]
- Lagging 板塊曝險: [list, 加總 X%]

### 1g. Sentiment 健康度(持倉檢查)
- 7d avg > 0: [X] 檔 / 30d avg > 0: [X] 檔
- 急降警示(7d - 30d < -0.15): [list]

### 1h. Thesis 健康度
**資料來源(主 skill 必須帶入,不可手寫「感覺還好」):**
從 `briefing-out/cache/fundamentals-snapshot.json` 的 `tickers.TICKER.highlights` 計算:
- `quarterly_revenue_growth_yoy > 0` = revenue intact
- `quarterly_earnings_growth_yoy > 0` = earnings intact
- 兩者皆正且無 2 連季減速 = fundamental thesis intact

格式:
- Fundamental thesis intact: [X/Y](X = revenue+earnings 雙正且無連續減速的持倉數;Y = 納入評估的持倉總數)
- Thesis 破裂或惡化中: [list](有 2 連季 revenue 負增長或 guide cut >10% 的 ticker)
- cache 缺失 → 填 `(fundamentals cache unavailable)` 並在 Step 2 對相關規則標 `(data gap)`

### 1h-supplement. Signal-Derived Thesis 健康度(選填,主 skill 帶入時啟用)

當主 skill(stock-analysis / briefing deep)帶入 `source=signal-inference` 的 pending theses,升級 1h 到事件級(月度→週度):

**啟用條件:** 主 skill prompt 中有「signal-inference thesis」欄位 + raw_quote 存在。
**若主 skill 未帶入 → 此段略過**(不影響其他 1h-1i 計算)。

格式:

Read the full file on GitHub · 289 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 · +3 lines 77277f48b3ee
  2. 11d ago First seen · 286 lines · 57 tokens per session scan A c5b594d7f37b

Subscribe to this mod's changes

probability-honesty-checker is an agent published in the GitHub repository PatrickSUDO/fadacai-portfolio (139 stars, last pushed yesterday), licensed MIT. It adds 57 tokens to every session and 4,455 once invoked, about $0.0003 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.