File size: 15,406 Bytes
53fc389 2c4b679 53fc389 98e35f9 53fc389 2c4b679 53fc389 6d2c480 98e35f9 6d2c480 53fc389 2c4b679 e038e0c 2c4b679 e038e0c 2c4b679 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 2c4b679 53fc389 98e35f9 53fc389 49f16e5 53fc389 49f16e5 53fc389 6d2c480 2c4b679 6d2c480 98e35f9 2c4b679 6d2c480 53fc389 98e35f9 53fc389 98e35f9 53fc389 98e35f9 53fc389 2c4b679 53fc389 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 | ---
pretty_name: "Plan B — Contrarian Deep-Value US Equities & AI 10-K Analysis"
license: cc-by-nc-4.0
language:
- en
size_categories:
- n<1K
task_categories:
- tabular-classification
- tabular-regression
- text-generation
- time-series-forecasting
tags:
- finance
- equities
- stocks
- sec-edgar
- xbrl
- value-investing
- fundamental-analysis
- 10-k
- form-4
- insider-trading
- financial-nlp
configs:
- config_name: daily_rankings
default: true
data_files:
- split: train
path: daily_rankings.jsonl
- config_name: ai_10k_memos
data_files:
- split: train
path: ai_10k_memos.jsonl
- config_name: insider_trades
data_files:
- split: train
path: insider_trades.jsonl
- config_name: scan_stats
data_files:
- split: train
path: scan_stats.jsonl
---
<p align="center"><img src="https://huggingface.co/datasets/elsiddik/planb-deep-value/resolve/main/assets/banner.svg" alt="Plan B — Contrarian Deep-Value US Equities" width="100%"/></p>
<p align="center">
<img src="https://img.shields.io/badge/license-CC--BY--NC--4.0-blue" alt="license"/>
<img src="https://img.shields.io/badge/scans-12%20daily-f0b90b" alt="scans"/>
<img src="https://img.shields.io/badge/tickers-66%20screened-22d3ee" alt="tickers"/>
<img src="https://img.shields.io/badge/rows-836%20total-26a69a" alt="rows"/>
<img src="https://img.shields.io/badge/source-SEC%20XBRL%20%2B%20FINRA-8b94a7" alt="source"/>
</p>
# Plan B — Contrarian Deep-Value US Equities & AI 10-K Analysis
> **Daily quantitative & fundamental research dataset** covering deeply discounted, financially resilient, and heavily beaten-down US operating companies across the **NYSE** and **Nasdaq**. Every trading day, Plan B screens ~6,000 SEC XBRL filers using primary **SEC EDGAR XBRL**, **3-year weekly price action**, **Form 4 open-market insider flow**, **FINRA short interest & short volume** (via Massive), **news sentiment**, and **LLM-synthesized 10-K/20-F deep-value memos**.
---
## 📊 Dataset Snapshot
| Metric | Value |
| :--- | :--- |
| **Coverage Window** | `2026-11-02` → `2026-11-13` (12 daily scans) |
| **Unique Shortlisted Companies** | 66 NYSE / Nasdaq tickers |
| **Daily Ranking Observations** | 427 rows (131 features per row) |
| **Structured AI 10-K/20-F Memos** | 21 filings analyzed |
| **Open-Market Form 4 Insider Trades** | 376 verified transactions |
| **Update Frequency** | Daily (automated post-market scan) |
| **License** | `CC-BY-NC-4.0` (Research & Non-Commercial) |
---
## 📈 At a Glance
| **Screening funnel** | **Score distribution** |
| :---: | :---: |
| <img src="https://huggingface.co/datasets/elsiddik/planb-deep-value/resolve/main/assets/funnel.svg" alt="Screening funnel" width="100%"/> | <img src="https://huggingface.co/datasets/elsiddik/planb-deep-value/resolve/main/assets/score_dist.svg" alt="Score distribution" width="100%"/> |
| **Sector mix** | **Drawdown vs. score** |
| :---: | :---: |
| <img src="https://huggingface.co/datasets/elsiddik/planb-deep-value/resolve/main/assets/sector_mix.svg" alt="Sector mix" width="100%"/> | <img src="https://huggingface.co/datasets/elsiddik/planb-deep-value/resolve/main/assets/value_drawdown.svg" alt="Drawdown vs. score" width="100%"/> |
---
## 📁 Dataset Tables
Every table is provided in both **CSV** (Kaggle, Pandas, R, DuckDB) and **JSON Lines (`.jsonl`)** (Hugging Face `datasets`, Spark, LLM pipelines).
| Table / Config | Files | Primary Key | Description |
| :--- | :--- | :--- | :--- |
| **`daily_rankings`** *(default)* | `daily_rankings.csv`<br>`daily_rankings.jsonl` | `(date, ticker)` | Daily ranked contrarian shortlist (~40 companies/day) with 131 quantitative, XBRL, FINRA short, insider, and AI verdict features. |
| **`ai_10k_memos`** | `ai_10k_memos.csv`<br>`ai_10k_memos.jsonl` | `(ticker, accession)` | Skeptical value-investor memos generated from Item 1, Item 1A, and Item 7 of each company's latest SEC Form 10-K or 20-F. |
| **`insider_trades`** | `insider_trades.csv`<br>`insider_trades.jsonl` | `(ticker, owner, kind, date, shares, form4_url)` | Open-market insider purchases (`P`) and sales (`S`) parsed from SEC Form 4 XML filings over the trailing 180 days. |
| **`scan_stats`** | `scan_stats.csv`<br>`scan_stats.jsonl` | `date` | Daily universe screening funnel: total filers, usable XBRL fundamentals, priced equities, shortlisted count, and paper track record. |
---
## 🚀 Quickstart
<details open>
<summary><b>Python (<code>datasets</code> — Hugging Face)</b></summary>
```python
from datasets import load_dataset
# Load default config (daily_rankings)
rankings = load_dataset("elsiddik/planb-deep-value", "daily_rankings", split="train").to_pandas()
print(rankings[["date", "rank", "ticker", "score", "pe", "ev_ebit", "dd_3y", "ai_verdict"]].head())
# Load structured 10-K AI memos & Form 4 insider trades
memos = load_dataset("elsiddik/planb-deep-value", "ai_10k_memos", split="train").to_pandas()
insiders = load_dataset("elsiddik/planb-deep-value", "insider_trades", split="train").to_pandas()
```
</details>
<details>
<summary><b>Python (<code>pandas</code> — Kaggle / Local CSV)</b></summary>
```python
import pandas as pd
df = pd.read_csv("daily_rankings.csv")
memos = pd.read_csv("ai_10k_memos.csv")
insiders = pd.read_csv("insider_trades.csv")
# Filter highest-conviction ideas with net cash and unplanned insider buying
top_ideas = df[(df["net_cash"] > 0) & (df["insider_unplanned_buy_value"] > 0)].sort_values(["date", "rank"])
print(top_ideas[["date", "ticker", "name", "score", "pe", "ev_ebit", "net_cash_pct", "ai_verdict"]].head(10))
```
</details>
---
## 🎯 Screening & Ranking Methodology
Plan B follows a strict **Graham–Klarman–Buffett** deep-value discipline (excluding financials SIC 6000–6799).
| Pillar | Hard Quantitative Gate (must pass all 3 simultaneously) |
| :--- | :--- |
| **Cheap** | `P/E ≤ 12` **or** `EV/EBIT ≤ 8` **or** `NCAV / Market Cap ≥ 1.0` (Benjamin Graham net-net) |
| **Safe** | Positive equity, `current_ratio ≥ 1.2`, `liabilities ≤ 2.0× equity` (or net cash), `3Y dilution ≤ 25%`, and `CFO > 0` if `NI < 0` |
| **Hated** | Price down ≥ **40%** from 3-year weekly high (`dd_3y ≤ -0.40`), `Market Cap ≥ $50M`, `Price ≥ $1.00` |
<details>
<summary><b>Composite Score Formula (0–100), Bonuses, Penalties & AI Adjustment</b></summary>
- **Base Weighting:** 40% **Cheap** (`cheap_score`) + 30% **Safe** (`safe_score`) + 30% **Hated** (`hated_score`, blending price drawdown and headline negativity `news_neg`).
- **Bonuses:** Net open-market Form 4 insider buying (up to +12 pts), same-day cluster buying, and 3-year share count reduction via buybacks (+4 pts).
- **Penalties:** Share dilution, negative free cash flow, accrual divergence, one-off profits following loss years, high goodwill/M&A intensity, and elevated off-exchange short-volume pressure.
- **AI 10-K Adjustment:** After reading the 10-K/20-F filing, the composite score is adjusted by the AI analyst's verdict (`CONTRARIAN BUY CANDIDATE`, `WATCH`, or `AVOID`) and conviction (`0–100`).
</details>
---
## 📖 Data Dictionary
<details>
<summary><b>1. <code>daily_rankings</code> (131 Columns)</b></summary>
| Column | Type | Description |
| :--- | :--- | :--- |
| `date` | `string` | Scan date (`YYYY-MM-DD`). |
| `rank` | `int` | Daily rank (`1` = highest composite score). |
| `ticker`, `name`, `cik`, `exchange`, `sector` | `string`/`int` | Ticker symbol, SEC registrant name, SEC CIK identifier, exchange (`NYSE`/`Nasdaq`), and SIC industry description. |
| `score` | `float` | Final Plan B composite score (`0–100`). |
| `cheap_score`, `safe_score`, `hated_price_score`, `hated_score` | `float` | Normalized sub-scores (`0.0–1.0`) for valuation, balance-sheet safety, price drawdown, and combined hated score. |
| `news_neg`, `hate_why` | `float`/`string` | Headline negativity score (`0.0` loved → `1.0` hated) and short explanation of market pessimism. |
| `first_seen`, `return_since_first` | `string`/`float` | Date the ticker first entered the shortlist and cumulative price return since `first_seen`. |
| `bonus`, `flags` | `list` / `string` | Score bonuses (e.g., insider buying, shrinking shares) and accounting/risk flags. |
| `price`, `mcap`, `ev` | `float` | Latest share price (USD), market capitalization (USD), and enterprise value (`Market Cap + Debt - Cash`, USD). |
| `dd_3y`, `ret_1y`, `high_3y`, `high_52w`, `low_52w`, `off_low` | `float` | Drawdown from 3-year high (`-0.75` = down 75%), 1-year return, 3-year/52-week highs & lows, and percentage above 52-week low. |
| `pe`, `ev_ebit`, `pb` | `float` | Price-to-Earnings, Enterprise Value-to-EBIT (capped at `0` when EV is negative), and Price-to-Book ratio. |
| `earnings_yield`, `ebit_ev`, `fcf_yield`, `book_yield` | `float` | Inverse valuation yields: `NI / MCap`, `EBIT / EV`, `FCF / MCap`, and `Equity / MCap`. |
| `ncav`, `netnet`, `net_cash`, `net_cash_pct` | `float` | Net Current Asset Value (`CA - Total Liabilities`), `NCAV / MCap`, Net Cash (`Cash - Debt`), and `Net Cash / MCap`. |
| `current_ratio`, `liab_eq`, `fcf`, `profit_years` | `float`/`int` | Current assets / current liabilities, total liabilities / equity, free cash flow (`CFO - CapEx`), and profitable years out of the last 3 FYs (`0–3`). |
| `share_chg_3y`, `rev_growth`, `buyback_yield`, `div_yield`, `goodwill_pct`, `acq_pct` | `float` | 3-year share count change, YoY revenue growth, buybacks/MCap, dividends/MCap, goodwill/assets, and acquisitions/assets. |
| `period`, `fy`, `assets`, `ca`, `cl`, `cash`, `equity`, `goodwill`, `debt`, `debt_known`, `liab` | `mixed` | Raw SEC XBRL balance-sheet values (USD) and reporting period (`CY2026Q3I`, etc.). |
| `shares`, `shares_old`, `shares_old_period` | `float`/`string` | Latest common shares outstanding and shares outstanding 3 years prior. |
| `ni`, `ni_1`, `ni_2`, `oi`, `cfo`, `capex`, `buyback`, `dividends`, `acquisitions`, `rev`, `rev_1` | `float` | Raw SEC XBRL annual income statement and cash-flow values (USD) for the latest and prior fiscal years. |
| `insider_buy_value`, `insider_sell_value`, `insider_buyers_count`, `insider_cluster` | `float`/`int`/`bool` | Trailing 180-day open-market Form 4 purchase USD total, sale USD total, distinct buyer count, and `true` when ≥3 distinct insiders bought (cluster buying). |
| `f_score`, `f_tested` | `int` | Piotroski F-score (`0–9`) and the number of its 9 tests with enough XBRL data to run. |
| `z_score`, `m_score`, `accruals` | `float` | Altman Z-score (`<1.81` distress), Beneish M-score (`>-1.78` flags possible earnings manipulation), and accruals ratio `(NI − CFO) / Assets`. |
| `pe_ttm`, `fcf_ttm`, `rev_ttm`, `ni_ttm`, `cfo_ttm`, `gross_margin` | `float` | Trailing-twelve-month metrics (`FY + YTD − prior YTD`): P/E, free cash flow, revenue, net income, operating cash flow (USD), and gross margin. |
| `ar`, `ppe`, `retained_earnings`, `gp`, `gp_1`, `dep`, `dep_1`, `sga`, `sga_1` | `float` | Raw XBRL items used by the forensic scores: receivables, net PP&E, retained earnings, gross profit, depreciation & amortization, and SG&A (latest FY and prior FY). |
| `pri_period`, `pri_assets`, `pri_liab`, `pri_ca`, `pri_cl`, `pri_ar`, `pri_ppe`, `pri_shares` | `mixed` | Balance-sheet values from the same SEC instant one year earlier, used for year-over-year quality tests. |
| `short_pct_float`, `short_ratio`, `short_chg_mom` | `float` | Short interest as % of float, days-to-cover ratio, and change vs the prior report (biweekly FINRA settlement when `short_src`=`finra`, else Yahoo month-over-month). |
| `held_pct_insiders`, `held_pct_institutions` | `float` | Share of the company held by insiders and by institutions. |
| `short_src`, `short_vol_avg`, `short_vol_last`, `float_shares`, `float_pct`, `avg_daily_volume` | `mixed` | Short-interest source (`finra`), average & latest daily off-exchange short-volume ratio (`0–1`), Massive free-float share count, free-float % (`0–1`), and FINRA average daily share volume. |
| `insider_buyers_sameday`, `insider_unplanned_buy_value` | `int`/`float` | Max distinct insiders buying on one day (Massive Form 4/5 aggregation) and insider purchase USD excluding 10b5-1 pre-planned trades. |
| `activist_form`, `activist_date`, `activist_name`, `activist_pct` | `mixed` | Latest Schedule 13D/13G stake filed against the company (form, date, reporting person, % of class). |
| `tenk_date`, `tenk_accession`, `tenk_form`, `tenk_url` | `string` | Filing date, SEC accession number, form type (`10-K` / `20-F`), and direct SEC EDGAR archive URL. |
| `ai_verdict`, `ai_conviction`, `ai_balance_sheet`, `ai_value_trap_risk`, `ai_one_liner` | `mixed` | AI 10-K analyst summary fields (`CONTRARIAN BUY CANDIDATE` / `WATCH` / `AVOID`, conviction `0–100`, balance sheet rating, value-trap risk, and one-line thesis). |
</details>
<details>
<summary><b>2. <code>ai_10k_memos</code> (21 Columns)</b></summary>
| Column | Type | Description |
| :--- | :--- | :--- |
| `ticker`, `name`, `cik`, `exchange`, `sector` | `string`/`int` | Company identifiers and SIC industry classification. |
| `accession`, `filing_date`, `read_on`, `filing_url` | `string` | SEC accession number, filing date, scan date analyzed, and direct EDGAR filing URL. |
| `verdict`, `conviction`, `balance_sheet`, `value_trap_risk` | `string`/`int` | Overall verdict, conviction (`0–100`), balance-sheet rating (`fortress`/`solid`/`stretched`/`weak`), and value-trap risk (`low`/`medium`/`high`). |
| `one_liner`, `business`, `why_hated`, `capital_allocation`, `management` | `string` | Concise investment synthesis covering the business model, market pessimism, buybacks/dividends/M&A, and leadership. |
| `bull`, `bear`, `red_flags` | `list` / `string` | Bullet lists of key bull points, bear points, and accounting/governance/footnote red flags from the 10-K. |
</details>
<details>
<summary><b>3. <code>insider_trades</code> (11 Columns)</b></summary>
| Column | Type | Description |
| :--- | :--- | :--- |
| `date` | `string` | Transaction date (`YYYY-MM-DD`). |
| `ticker`, `company_name`, `cik` | `string`/`int` | Issuer ticker, company name, and SEC CIK. |
| `owner`, `title` | `string` | Reporting insider name and relationship/officer title (`CEO`, `CFO`, `Director`, `10% owner`). |
| `kind` | `string` | Open-market transaction code: `P` (Purchase) or `S` (Sale). |
| `shares`, `price`, `value` | `float` | Number of shares traded, execution price per share (USD), and total dollar value (USD). |
| `form4_url` | `string` | Direct URL to the primary SEC Form 4 XML filing on EDGAR. |
</details>
---
## 🛡️ Data Integrity, Privacy & Caveats
- **Zero Credentials / Zero PII Guarantee:** Every export passes an automated security gate (`assertNoCredentials`) that enforces an explicit column allowlist, scrubs email addresses, and scans against secret/token patterns before writing or uploading.
- **XBRL Tagging Nuances:** SEC fundamentals reflect company-reported US-GAAP XBRL tags. Unusual tagging or dual-class share structures can occasionally distort market cap or debt ratios; always cross-check the linked SEC filing (`tenk_url`).
- **Research Only:** This dataset is for quantitative, academic, and machine-learning research only and never constitutes financial or investment advice.
|