How to use from
vLLM
Install from pip and serve model
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "schwp/TinyMathLlama-1.1B"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "schwp/TinyMathLlama-1.1B",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
Use Docker
docker model run hf.co/schwp/TinyMathLlama-1.1B
Quick Links

TinyMathLlama-1.1B

TinyLlama-1.1B fine-tuned on MetaMathQA using a from-scratch LoRA implementation.

  • LoRA config: r=8, $\alpha$=16, target modules: q_proj + v_proj
  • Training data: 10k samples from MetaMathQA
  • GSM8K accuracy: 3.0% (base: 1.5%, 2x improvement)
  • Trainable params: 1,126,400 / 1,101,174,784 (0.1%)

Usage

from transformers import AutoModelForCausalLM, AutoTokenizer model = AutoModelForCausalLM.from_pretrained("schwp/schwp/TinyMathLlama-1.1B")

Training & Evaluation

The training and evaluation scripts are available on this github repository. The whole LoRA implementation used for the fine-tuning is also on the repository.

Downloads last month
8
Safetensors
Model size
1B params
Tensor type
F16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for schwp/TinyMathLlama-1.1B

Adapter
(105)
this model
Adapters
1 model

Datasets used to train schwp/TinyMathLlama-1.1B