--- license: apache-2.0 --- # JT-Math-8B-Instruct

We are excited to introduce JT-Math-8B-Instruct, a powerful 8-billion parameter model specialized for mathematical reasoning. It achieves state-of-the-art performance on major math benchmarks among models of its size. JT-Math-8B-Instruct is fine-tuned from Jiutian-Math-8B-Base and has been optimized through a comprehensive process involving Supervised Fine-Tuning (SFT) and Reinforcement Learning (RL) to enhance its mathematical problem-solving abilities and instruction-following capabilities. For full transparency and reproducibility, please refer to our technical report which details our training recipe and pipeline. ## Model Details 🚀 The **JT-Math-8B-Instruct** is an 8-billion parameter language model built on the **Jiutian LLM architecture** with a **context length of 32,768 tokens**. Its development involved two key stages: initial pre-training of the **JT-Math-8B-Base** model on a diverse corpus of text and mathematical data, followed by a two-stage instruction tuning process. This tuning began with **Supervised Fine-Tuning (SFT)**, where the model was trained on a high-quality, multilingual dataset of mathematical problems and solutions in both English and Chinese to grasp problem-solving patterns. Subsequently, **Reinforcement Learning (RL)** was applied within an 8K context window to enhance reasoning accuracy, minimize logical fallacies, and align the model more closely with human preferences for clear and correct mathematical solutions. ## Model Downloads We release the following model to support a wide range of applications: | Model Name | Context Length | Hugging Face Link | ModelScope Link | Notes | | ------------------- | -------------- | -------------------------------------------------------- | ------------------------------------------------------------ | --------------------------------------------------- | | JT-Math-8B-Instruct | 32K | [Link](https://huggingface.co/JT-LM/JT-Math-8B-Instruct) | [Link](https://www.modelscope.cn/models/JiuTian-AI/JT-Math-8B-Instruct) | Instruction-tuned for general math problem-solving. | ------ ## Evaluation Results JT-Math-8B-Instruct demonstrates state-of-the-art performance on key mathematical benchmarks, outperforming other open-source models in the ~8B parameter class. Below is a summary of our evaluation results: ![alt text]() ## How to Get Started This example shows how to use the `JT-Math-8B-Instruct model to solve math problems. ```python from transformers import AutoModelForCausalLM, AutoTokenizer model_name = "JT-LM/JT-Math-8B-Instruct" tokenizer = AutoTokenizer.from_pretrained(model_name, trust_remote_code=True) model = AutoModelForCausalLM.from_pretrained( model_name, torch_dtype="auto", device_map="auto", trust_remote_code=True, ) prompt = "Janet’s ducks lay 16 eggs per day. She eats three for breakfast every morning and bakes muffins for her friends every day with four. She sells the remainder at the farmers' market daily for $2 per fresh duck egg. How much in dollars does she make every day at the farmers' market?" messages = [ {"role": "user", "content": prompt} ] text = tokenizer.apply_chat_template( messages, tokenize=False, add_generation_prompt=True, ) model_inputs = tokenizer([text], return_tensors="pt").to(model.device) gen_kwargs = { "do_sample": False, "max_new_tokens": 8192, } generated_ids = model.generate( **model_inputs, **gen_kwargs ) output_ids = generated_ids[0][len(model_inputs.input_ids[0]):].tolist() response = tokenizer.decode(output_ids, skip_special_tokens=True) print("response:", response) ``` ## Citation If you find our work useful, please consider citing our paper: ```latex @article{jiutian-math2025, title={JIUTIAN MATH: A MULTI-STAGE FRAMEWORK FOR ADVANCED MATHEMATICAL REASONING IN LARGE LANGUAGE MODELS}, author={Yifan Hao, Fangning Chao, Yaqian Hao, Zhaojun Cui, Huan Bai, Haiyu Zhang, Yankai Liu, Chao Deng, Junlan Feng}, journal={arXiv:2507.19748}, year={2025} } ```