Inspiration
A drug shortage creates an urgent question: who can still supply what patients need?
We saw a potential investment relationship behind that question. When one manufacturer faces a disruption, competing suppliers may capture displaced demand. BackFill began as an effort to connect that commercial opportunity to publicly available FDA evidence and test whether it appears in stock returns.
What it does
BackFill identifies potential beneficiaries of FDA-reported drug shortages and evaluates a systematic trading rule around them.
The disrupted manufacturer identifies the shock. The proposed investment basket contains listed competitors with qualifying supplier availability.
The process follows a clear chain:
FDA shortage → affected formulation → available competitor → listed parent → market-hedged trading signal
Our current research candidate waits 20 trading sessions after the first eligible close, then holds for five sessions. A SPY hedge helps separate supplier performance from broad market movement.
How we built it
We built a Python pipeline to reconstruct archived FDA shortage lists and supplier detail pages, preserve capture timestamps, and map manufacturers to their publicly listed parents.
The supplier screen requires every recorded presentation for a selected parent on the chosen page to be available and unallocated. We combine that evidence with daily price data, estimate market exposure using 250 prior stock/SPY returns, and simulate positions with transaction costs and hedge carry.
The pipeline produces trade ledgers, portfolio equity curves, cost-sensitivity comparisons and structured outputs for the dashboard. Each result can be traced back to its underlying evidence.
Challenges we ran into
Recovering historical evidence. FDA retains resolved shortages on its public webpage for six months and discontinued products for one year. We reconstructed older records through archived captures instead of relying on today’s database. FDA database FAQ
Aligning information with trades. Supplier evidence sometimes appeared after the initial shortage notice. We made the later evidence timestamp determine when the signal became usable.
Identifying the correct company. Supplier names, subsidiaries and listed parents did not always match directly. We used dated ownership mappings and excluded ambiguous cases.
Refining the hypothesis. Our initial specification expected an immediate, sustained response. Backtesting prompted us to tighten supplier qualification and investigate a delayed, shorter holding window.
Accomplishments that we're proud of
- Reconstructing historical supplier evidence that cannot be recovered from the live FDA interface alone.
- Connecting formulation-level availability to investable listed companies.
- Keeping disrupted manufacturers separate from each event’s beneficiary basket.
- Building reproducible accounting that distinguishes stock returns, benchmark outperformance and net hedged returns.
- Preserving evidence, exclusions and trade calculations so the research can be inspected.
- Freezing the research on Solana and publishing every variant in Snowflake, so judges can verify what we tested and when, not just our best result.
What we learned
A credible trading signal starts with a precise economic relationship and reliable information timing.
We learned that “another supplier exists” is weaker evidence than documented availability, and that a positive stock return differs from market-relative or net hedged performance. Backtesting also helped us turn a broad idea into a more specific, testable hypothesis.
The most valuable part of BackFill is the evidence trail connecting a real supply disruption to a potential commercial beneficiary.
What's next for BackFill
We plan to capture supplier states daily, verify availability again at entry, and improve matching across formulations, ownership changes and listed securities.
We will test international supplier parents using appropriate local benchmarks, currency accounting and execution assumptions. We also plan to replace fixed cost estimates with dated spread and market-impact data.
Finally, the trading rules are already frozen and anchored on Solana (2026-10-04). Newly observed FDA events will be evaluated against that frozen rule, so prospective evidence, not further tuning, decides whether the relationship is a repeatable trading opportunity.
Built with our sponsors
- Webull: Webull's OpenAPI supplies the daily US prices behind the backtest, cross-checked and stored in a hash-verified cache. The live dashboard uses the same client to chart the four injectable specialists.
- Solana: Before forward testing, we froze our rules, data and results and wrote their SHA-256 fingerprint to Solana as a memo. Anyone can re-check it from the repo or with the Verify now button; any later edit fails verification.
- Snowflake: Snowflake holds the full research audit: all 11 strategies we tested (including the 9 that lost money), every trade cashflow, the price manifest and the Solana proof. A zero-copy clone preserves exactly what we published.
- Tiger Data: TimescaleDB hypertables store 18,218 archived FDA page snapshots (1,042 drugs, 2014–2026), FDA supply notices and market quotes, each with its source time. This powers our FDA Time Machine: what FDA said on any date.
- Google Gemini: Gemini writes a two-sentence, plain-English summary of each trade from 7 structured facts. An automatic checker rejects added facts or advice, and the summaries are cached, so the site never depends on a live model call.
- Vultr: The dashboard runs on a Vultr server as a systemd service behind Caddy with automatic HTTPS, deployed with one script: https://155-138-224-207.sslip.io
Built With
- caddy
- gemini
- internet-archive
- javascript
- pandas
- postgresql
- python
- snowflake
- solana
- tiger-data
- timescaledb
- vultr
- webull

Log in or sign up for Devpost to join the conversation.