Text Generation
Transformers
Safetensors
English
Turkish
llama
text-generation-inference
unsloth
trl
grpo
test-time-reinforcement-learning
conversational
Instructions to use Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO") model = AutoModelForCausalLM.from_pretrained("Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO
- SGLang
How to use Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Unsloth Studio new
How to use Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO to start chatting
Load model with FastModel
pip install unsloth from unsloth import FastModel model, tokenizer = FastModel.from_pretrained( model_name="Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO", max_seq_length=2048, ) - Docker Model Runner
How to use Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO with Docker Model Runner:
docker model run hf.co/Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO
Improve model card: add pipeline tag, library name, language, license, paper, and code links
#1
by nielsr HF Staff - opened
README.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
| 1 |
---
|
| 2 |
base_model: ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
tags:
|
| 4 |
- text-generation-inference
|
| 5 |
- transformers
|
|
@@ -8,9 +14,6 @@ tags:
|
|
| 8 |
- trl
|
| 9 |
- grpo
|
| 10 |
- test-time-reinforcement-learning
|
| 11 |
-
license: llama3
|
| 12 |
-
language:
|
| 13 |
-
- en
|
| 14 |
---
|
| 15 |
|
| 16 |
<img src="https://huggingface.co/Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO/resolve/main/llama_clones.png"
|
|
@@ -20,6 +23,9 @@ alt="A scene from a famous movie" width="800"/>
|
|
| 20 |
|
| 21 |
Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO is a [Test Time Reinforcement Learning (TTRL)](https://arxiv.org/abs/2504.16084) trained version of ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1. It is trained on Turkish math word problems using GRPO method and a majority vote reward function.
|
| 22 |
|
|
|
|
|
|
|
|
|
|
| 23 |
## Training Info
|
| 24 |
|
| 25 |
- **Base Model**: [Turkish-Llama-8b-DPO-v0.1](https://huggingface.co/ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1)
|
|
@@ -88,11 +94,11 @@ print(result)
|
|
| 88 |
```
|
| 89 |
|
| 90 |
# Citation
|
| 91 |
-
```
|
| 92 |
-
@article{
|
| 93 |
-
title={
|
| 94 |
-
author={
|
| 95 |
-
|
| 96 |
-
|
| 97 |
}
|
| 98 |
```
|
|
|
|
| 1 |
---
|
| 2 |
base_model: ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
- tr
|
| 6 |
+
license: apache-2.0
|
| 7 |
+
pipeline_tag: text-generation
|
| 8 |
+
library_name: transformers
|
| 9 |
tags:
|
| 10 |
- text-generation-inference
|
| 11 |
- transformers
|
|
|
|
| 14 |
- trl
|
| 15 |
- grpo
|
| 16 |
- test-time-reinforcement-learning
|
|
|
|
|
|
|
|
|
|
| 17 |
---
|
| 18 |
|
| 19 |
<img src="https://huggingface.co/Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO/resolve/main/llama_clones.png"
|
|
|
|
| 23 |
|
| 24 |
Metin/LLaMA-3-8B-Math-Majority-Vote-GRPO is a [Test Time Reinforcement Learning (TTRL)](https://arxiv.org/abs/2504.16084) trained version of ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1. It is trained on Turkish math word problems using GRPO method and a majority vote reward function.
|
| 25 |
|
| 26 |
+
**Paper:** [TTRL: Test-Time Reinforcement Learning](https://huggingface.co/papers/2504.16084)
|
| 27 |
+
**Code:** [https://github.com/PRIME-RL/TTRL](https://github.com/PRIME-RL/TTRL)
|
| 28 |
+
|
| 29 |
## Training Info
|
| 30 |
|
| 31 |
- **Base Model**: [Turkish-Llama-8b-DPO-v0.1](https://huggingface.co/ytu-ce-cosmos/Turkish-Llama-8b-DPO-v0.1)
|
|
|
|
| 94 |
```
|
| 95 |
|
| 96 |
# Citation
|
| 97 |
+
```bibtex
|
| 98 |
+
@article{zuo2025ttrl,
|
| 99 |
+
title={Ttrl: Test-time reinforcement learning},
|
| 100 |
+
author={Zuo, Yuxin and Zhang, Kaiyan and Qu, Shang and Sheng, Li and Zhu, Xuekai and Qi, Biqing and Sun, Youbang and Cui, Ganqu and Ding, Ning and Zhou, Bowen},
|
| 101 |
+
journal={arXiv preprint arXiv:2504.16084},
|
| 102 |
+
year={2025}
|
| 103 |
}
|
| 104 |
```
|