sangeetmore/tailrisk ? reverse-engineered prompt
Reverse engineered prompt
Build me a Python app that estimates tail risk in stock returns and shows why Gaussian assumptions fail.
I want a small study pipeline that can fetch price data, convert it to returns, estimate tail heaviness with the Hill method, compare a few different ways of choosing the tail cutoff, and then backtest several VaR models so I can see breach counts and clustering. Please include a command line run that can generate an HTML report and CSV tables, plus a local web app where I can pick assets, date ranges, confidence levels, and tail settings, then start a run and watch progress live. The web app should show charts, sortable result tables, downloadable CSVs, and a simple glossary explaining the terms in plain English.
Make it feel polished and usable on desktop and phone. If you need to look up current docs online, go ahead. I’d also like tests, sensible defaults, and a clean structure so the analysis pieces are reusable.