Kronos: K-line Foundation Model Trained on Data from 45 Exchanges
shiyu-coder/Kronos
About the project
An open-source foundation model that interprets financial market candlestick (K-line) sequences as language. It was trained using data from over 45 exchanges worldwide and is designed to handle the high-noise characteristics inherent in financial data. It is based on research accepted at AAAI 2026.
It consists of a dedicated tokenizer that converts continuous OHLCV data into hierarchical discrete tokens, and a pretrained autoregressive Transformer based on this. Models of various sizes, from Kronos-mini to large, are available and can be downloaded immediately from the Hugging Face Hub.
The KronosPredictor class automates the process from raw data preprocessing to prediction and denormalization. It supports not only single time series prediction but also simultaneous multi-asset prediction using GPU parallel processing. Probabilistic prediction paths can be generated by adjusting sampling parameters.
It provides a fine-tuning pipeline for custom datasets and backtesting scripts utilizing Qlib. It demonstrates the fine-tuning process using Chinese A-share market data as an example, and can be used to adapt the model to specific assets or exchanges.
shiyu-coder/Kronos
Kronos: A Foundation Model for the Language of Financial Markets
Python