Instructions to use Tjgguy12/stock-1d-quant-predictor with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Scikit-learn
How to use Tjgguy12/stock-1d-quant-predictor with Scikit-learn:
from huggingface_hub import hf_hub_download import joblib model = joblib.load( hf_hub_download("Tjgguy12/stock-1d-quant-predictor", "sklearn_model.joblib") ) # only load pickle files from sources you trust # read more about it here https://skops.readthedocs.io/en/stable/persistence.html - Notebooks
- Google Colab
- Kaggle
Stock 1D Quant Predictor โ 1-Day UP/DOWN + Expected Percent
Kaggle finetuned Voting XGB+LGBM on 503 S&P tickers (25y, 2.9M rows, purged walk-forward).
- IC 0.019, Prec@20 52%, AUC 0.52
- Backtest Sharpe 1.21 (2019H1), -0.96 (2022 bear), 1.30 (2024) โ regime sensitive
- Files:
scaler_1d.pkl+clf_1d_voting.pkl(2.4MB) +reg_1d_ridge.pkl+features_1d.json
Usage (Python)
import joblib, json
scaler=joblib.load("scaler_1d.pkl")
clf=joblib.load("clf_1d_voting.pkl")
reg=joblib.load("reg_1d_ridge.pkl")
features=json.load(open("features_1d.json"))["features"]
# compute features from yfinance 1y daily (see app.py)
x=scaler.transform([[ticker_features[f] for f in features]])
p=float(clf.predict_proba(x)[0,1])
ep=float(reg.predict(x)[0])
direction="UP" if p>0.57 else "DOWN" if p<0.43 else "FLAT"
Chatbot
app.py is Gradio chatbot (live yfinance). Deploy to HF Space requires PRO, so this repo hosts model artifacts; Vercel frontend calls HF model or runs inference directly.
Kaggle: https://www.kaggle.com/code/maxvwede/stock-1d-quant-predictor-1-day-up-down Vercel: https://github.com/Tjgguy12/stock-1d-quant-chat (coming) Disclaimer: Probabilistic, not financial advice.
- Downloads last month
- -
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐ Ask for provider support