About this project

Kronos is presented as an open-source foundation model for financial candlestick (K-line) data, described as trained on data from more than 45 global exchanges. The project was accepted at AAAI 2026, and its paper is available on arXiv. Architecture and approach Kronos is a family of decoder-only foundation models pre-trained on K-line sequences. Its two-stage framework first uses a specialized tokenizer to quantize continuous multi-dimensional OHLCV data into hierarchical discrete tokens, then pre-trains a large autoregressive Transformer on those tokens so the same model can serve multiple quantitative tasks. The authors position it as designed for the high-noise characteristics of financial data, in contrast to general-purpose time-series foundation models. Model zoo Pre-trained models are distributed via Hugging Face under the NeoQuasar organization: - Kronos-mini: Kronos-Tokenizer-2k, context length 2048, 4.1M parameters. - Kronos-small: Kronos-Tokenizer-base, context length 512, 24.7M parameters. - Kronos-base: Kronos-Tokenizer-base, context length 512, 102.3M parameters. - Kronos-large: Kronos-Tokenizer-base, context length 512, 499.2M parameters, listed as not open-sourced. Usage After installing Python 3.10+ and the requirements file, users load a tokenizer and model from Hugging Face, instantiate KronosPredictor with a max_context value, and call predict with a pandas DataFrame containing open, high, low, close (volume and amount optional), plus historical and future timestamp series. Sampling is controlled by temperature, top_p, and sample_count for probabilistic forecasting. A predict_batch method supports parallel prediction across multiple series, requiring equal lookback and prediction lengths per series; it handles normalization and denormalization per series and uses GPU parallelism. Example scripts cover prediction with and without volume/amount data, and a live demo visualizes a 24-hour BTC/USDT forecast. Finetuning and backtesting A four-step finetuning pipeline is provided as an A-share market demonstration built on Qlib: configuration, data preparation, tokenizer and predictor finetuning (multi-GPU via torchrun), and backtesting with a simple top-K strategy. The README explicitly frames this as a simplified demonstration rather than a production-ready quantitative trading system, noting that real workflows would add portfolio optimization, risk-factor neutralization, transaction cost and slippage modeling, and more complex position sizing. It also notes that many comments in the finetune directory were AI-generated and may contain inaccuracies. Licensing Released under the MIT License.