← Zheyuan YuProject notes

2026 · Python · private repository

quantnews

Turning news and filings into ranked, risk-gated equity trade ideas.

  • 8 yrsof SEC Form-4 history (2018–2026)
  • ~5,000insider events tracked
  • ~14.5kevents, walk-forward calibrated
  • 5signal sources, S&P 100

The problem

Most market-moving information shows up as text: news headlines, SEC filings, earnings calls. I wanted something that reads all of it, turns it into ranked trade ideas with clear risk limits, and keeps a record of which ones I took and how they did, so I could actually tell what worked instead of guessing.

How it works

A daily job collects RSS, SEC EDGAR 8-K items and Form 4 insider trades, earnings-call transcripts, and analyst revisions, and an LLM scores each one for direction and how confident it is.

Sizing isn’t just the model’s score. It also depends on the market regime (SPY and QQQ breadth) and a few risk-off rules: an earnings window or a cluster of insider selling cuts a position’s size instead of trusting a stale signal. Ideas I actually trade become tracked theses, each with an entry, stop, target, and a note on why I closed it.

From headline to sized position
  • RSS
  • SEC 8-K
  • Form 4
  • Transcripts
  • Analyst revisions
  1. LLM scoring

    one signal per event

  2. Calibration

    conviction → empirical hit rate

  3. Conviction stack

    regime gate · lockouts · nudges

  4. Ranked, risk-sized ideas

    entry / stop / target

  5. Tracked theses

    recorded, then reviewed on close

    ↺ closed trades feed back into the calibration.

Worked example. Say a news event scores 0.78. Instead of trusting that number, the system checks how often signals like it have actually paid off, sizes the position on that, and scales it with the market regime.

Calibration

A raw model score isn’t a probability. So each (event type, direction, score bucket) gets mapped to how often it actually worked in the past, pulled toward the base rate when the sample is thin. Position size follows that calibrated number, not the raw score, and the regime gate scales the whole book up or down with the market.

Does it hold up?

Before a signal is allowed to move sizing, it has to hold up in backtests and walk-forward checks on a broad S&P 100 sample, across pre-COVID, COVID, and post-COVID markets, not just a handful of names that happened to survive. The same checks run live, so a signal that stops working gets caught and down-weighted on its own.

The code is private (it’s a personal research system). Happy to give a deeper walkthrough on request.

Get in touch →