Instructions to use duyentl04/abc with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use duyentl04/abc with PEFT:
Task type is invalid.
- Transformers
How to use duyentl04/abc with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="duyentl04/abc")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("duyentl04/abc", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use duyentl04/abc with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "duyentl04/abc" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "duyentl04/abc", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/duyentl04/abc
- SGLang
How to use duyentl04/abc 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/abc" \ --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/abc", "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/abc" \ --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/abc", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use duyentl04/abc with Docker Model Runner:
docker model run hf.co/duyentl04/abc
CoT-MTKD Stage 1 experts (Qwen2.5-7B-Instruct, 3 LoRA adapters)
Three LoRA adapters trained jointly in Stage 1 of the
CoT_MTKD pipeline. Each adapter is
one "expert" on top of Qwen/Qwen2.5-7B-Instruct; the experts are trained with
an SFT loss plus a DPP repulsion term that pushes them apart. They are meant to
be used as teachers for the Stage 2 distillation step of that pipeline.
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:
Qwen/Qwen2.5-7B-Instruct - LoRA: rank 16, alpha 16, dropout 0.05
- Data: s1K (prepared as
s1k_1_1) - 3 epochs, 94 optimizer steps, global batch size 32, learning rate 5e-5, AdamW, cosine schedule
See config.yaml for the full configuration.
Usage
from peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer
base = "Qwen/Qwen2.5-7B-Instruct"
tokenizer = AutoTokenizer.from_pretrained(base)
model = AutoModelForCausalLM.from_pretrained(base, torch_dtype="auto", device_map="auto")
model = PeftModel.from_pretrained(model, "duyentl04/abc", subfolder="expert_0")
Replace expert_0 with expert_1 or expert_2 for the other experts.
- Downloads last month
- -