Text Generation
Transformers
Safetensors
qwen2
Generated from Trainer
open-r1
trl
sft
conversational
text-generation-inference
Instructions to use Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill") model = AutoModelForCausalLM.from_pretrained("Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill", device_map="auto") 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 Settings
- vLLM
How to use Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill
- SGLang
How to use Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill 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 "Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill" \ --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": "Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill", "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 "Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill" \ --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": "Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill with Docker Model Runner:
docker model run hf.co/Sunnylululu/Qwen2.5-1.5B-Open-R1-Distill
Model save
Browse files- README.md +2 -4
- all_results.json +4 -4
- config.json +1 -1
- train_results.json +4 -4
- trainer_state.json +4 -4
- training_args.bin +1 -1
README.md
CHANGED
|
@@ -1,10 +1,8 @@
|
|
| 1 |
---
|
| 2 |
-
datasets: open-r1/OpenR1-Math-220k
|
| 3 |
library_name: transformers
|
| 4 |
model_name: Qwen2.5-1.5B-Open-R1-Distill
|
| 5 |
tags:
|
| 6 |
- generated_from_trainer
|
| 7 |
-
- open-r1
|
| 8 |
- trl
|
| 9 |
- sft
|
| 10 |
licence: license
|
|
@@ -12,7 +10,7 @@ licence: license
|
|
| 12 |
|
| 13 |
# Model Card for Qwen2.5-1.5B-Open-R1-Distill
|
| 14 |
|
| 15 |
-
This model is a fine-tuned version of [None](https://huggingface.co/None)
|
| 16 |
It has been trained using [TRL](https://github.com/huggingface/trl).
|
| 17 |
|
| 18 |
## Quick start
|
|
@@ -28,7 +26,7 @@ print(output["generated_text"])
|
|
| 28 |
|
| 29 |
## Training procedure
|
| 30 |
|
| 31 |
-
[<img src="https://raw.githubusercontent.com/wandb/assets/main/wandb-github-badge-28.svg" alt="Visualize in Weights & Biases" width="150" height="24"/>](https://wandb.ai/648848014/huggingface/runs/
|
| 32 |
|
| 33 |
|
| 34 |
This model was trained with SFT.
|
|
|
|
| 1 |
---
|
|
|
|
| 2 |
library_name: transformers
|
| 3 |
model_name: Qwen2.5-1.5B-Open-R1-Distill
|
| 4 |
tags:
|
| 5 |
- generated_from_trainer
|
|
|
|
| 6 |
- trl
|
| 7 |
- sft
|
| 8 |
licence: license
|
|
|
|
| 10 |
|
| 11 |
# Model Card for Qwen2.5-1.5B-Open-R1-Distill
|
| 12 |
|
| 13 |
+
This model is a fine-tuned version of [None](https://huggingface.co/None).
|
| 14 |
It has been trained using [TRL](https://github.com/huggingface/trl).
|
| 15 |
|
| 16 |
## Quick start
|
|
|
|
| 26 |
|
| 27 |
## Training procedure
|
| 28 |
|
| 29 |
+
[<img src="https://raw.githubusercontent.com/wandb/assets/main/wandb-github-badge-28.svg" alt="Visualize in Weights & Biases" width="150" height="24"/>](https://wandb.ai/648848014/huggingface/runs/3n5lktnf)
|
| 30 |
|
| 31 |
|
| 32 |
This model was trained with SFT.
|
all_results.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
| 1 |
{
|
| 2 |
"total_flos": 2.5375909456379904e+17,
|
| 3 |
-
"train_loss": 0.
|
| 4 |
-
"train_runtime":
|
| 5 |
"train_samples": 3472,
|
| 6 |
-
"train_samples_per_second":
|
| 7 |
-
"train_steps_per_second":
|
| 8 |
}
|
|
|
|
| 1 |
{
|
| 2 |
"total_flos": 2.5375909456379904e+17,
|
| 3 |
+
"train_loss": 0.0,
|
| 4 |
+
"train_runtime": 2.0428,
|
| 5 |
"train_samples": 3472,
|
| 6 |
+
"train_samples_per_second": 964.355,
|
| 7 |
+
"train_steps_per_second": 63.638
|
| 8 |
}
|
config.json
CHANGED
|
@@ -23,7 +23,7 @@
|
|
| 23 |
"tie_word_embeddings": true,
|
| 24 |
"torch_dtype": "bfloat16",
|
| 25 |
"transformers_version": "4.50.0.dev0",
|
| 26 |
-
"use_cache":
|
| 27 |
"use_sliding_window": false,
|
| 28 |
"vocab_size": 151936
|
| 29 |
}
|
|
|
|
| 23 |
"tie_word_embeddings": true,
|
| 24 |
"torch_dtype": "bfloat16",
|
| 25 |
"transformers_version": "4.50.0.dev0",
|
| 26 |
+
"use_cache": false,
|
| 27 |
"use_sliding_window": false,
|
| 28 |
"vocab_size": 151936
|
| 29 |
}
|
train_results.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
| 1 |
{
|
| 2 |
"total_flos": 2.5375909456379904e+17,
|
| 3 |
-
"train_loss": 0.
|
| 4 |
-
"train_runtime":
|
| 5 |
"train_samples": 3472,
|
| 6 |
-
"train_samples_per_second":
|
| 7 |
-
"train_steps_per_second":
|
| 8 |
}
|
|
|
|
| 1 |
{
|
| 2 |
"total_flos": 2.5375909456379904e+17,
|
| 3 |
+
"train_loss": 0.0,
|
| 4 |
+
"train_runtime": 2.0428,
|
| 5 |
"train_samples": 3472,
|
| 6 |
+
"train_samples_per_second": 964.355,
|
| 7 |
+
"train_steps_per_second": 63.638
|
| 8 |
}
|
trainer_state.json
CHANGED
|
@@ -194,10 +194,10 @@
|
|
| 194 |
"epoch": 10.0,
|
| 195 |
"step": 130,
|
| 196 |
"total_flos": 2.5375909456379904e+17,
|
| 197 |
-
"train_loss": 0.
|
| 198 |
-
"train_runtime":
|
| 199 |
-
"train_samples_per_second":
|
| 200 |
-
"train_steps_per_second":
|
| 201 |
}
|
| 202 |
],
|
| 203 |
"logging_steps": 5,
|
|
|
|
| 194 |
"epoch": 10.0,
|
| 195 |
"step": 130,
|
| 196 |
"total_flos": 2.5375909456379904e+17,
|
| 197 |
+
"train_loss": 0.0,
|
| 198 |
+
"train_runtime": 2.0428,
|
| 199 |
+
"train_samples_per_second": 964.355,
|
| 200 |
+
"train_steps_per_second": 63.638
|
| 201 |
}
|
| 202 |
],
|
| 203 |
"logging_steps": 5,
|
training_args.bin
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 6264
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8059c50bedd31a2ed36ddf1aa09cc4ef20113c535f90c427a63405d23bc104e2
|
| 3 |
size 6264
|