Instructions to use duyentl04/1.5B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use duyentl04/1.5B with PEFT:
Task type is invalid.
- Transformers
How to use duyentl04/1.5B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="duyentl04/1.5B")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("duyentl04/1.5B", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use duyentl04/1.5B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "duyentl04/1.5B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "duyentl04/1.5B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/duyentl04/1.5B
- SGLang
How to use duyentl04/1.5B 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 "duyentl04/1.5B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "duyentl04/1.5B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "duyentl04/1.5B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "duyentl04/1.5B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use duyentl04/1.5B with Docker Model Runner:
docker model run hf.co/duyentl04/1.5B
CoT-MTKD Stage 1 experts (DeepSeek-R1-Distill-Qwen-1.5B, 3 LoRA adapters)
Three LoRA adapters trained jointly in Stage 1 of the
CoT_MTKD pipeline (phase1-gac branch,
objective sft_dpp_rbf_local_gac). Each adapter is one "expert" on top of
deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B; the experts are trained with SFT plus a
step-level DPP term, local GAC gradient sharing between experts and RBF repulsion.
They are meant to be used as teachers for the Stage 2 distillation step.
Files
| Path | Content |
|---|---|
expert_0/, expert_1/, expert_2/ |
PEFT LoRA adapters (adapter_config.json, adapter_model.safetensors) |
config.yaml |
Stage 1 training config |
manifest.json |
Run manifest written by the pipeline |
metrics.jsonl |
Per-step training metrics |
The pipeline's own final/adapter_states.pt bundle and the resumable
checkpoint.pt referenced in manifest.json are not uploaded. Absolute local
paths in config.yaml and manifest.json were rewritten as relative paths, so
the config_file_sha256 in the manifest no longer matches config.yaml.
Training setup
- Base model:
deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B - LoRA: rank 16, alpha 16, dropout 0.05, all attention and MLP projections
- Data: s1K-1.1
deepseek_thinking_trajectory, 996 samples - Prompt: the tokenizer's chat template with the user turn
"Please reason step by step, and put your final answer within \boxed{}.\n\n{question}"(the template ends in<think>\n), followed by the CoT and the tokenizer's EOS token - 3 epochs, 187 optimizer steps, global batch size 16, learning rate 5e-5, AdamW, cosine schedule; first 10% of updates SFT only, then SFT + 0.1 DPP with GAC (beta 0.5) and RBF repulsion (weight 0.5)
See config.yaml for the full configuration.
Usage
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
base = "deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B"
tokenizer = AutoTokenizer.from_pretrained(base)
model = AutoModelForCausalLM.from_pretrained(base, torch_dtype="bfloat16")
model = PeftModel.from_pretrained(model, "duyentl04/1.5B", subfolder="expert_0")
- Downloads last month
- -
Model tree for duyentl04/1.5B
Base model
deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B