JustQuiteMadMax/ZNO_Test_Conversations
Viewer • Updated • 3.06k • 8 • 1
How to use JustQuiteMadMax/Qwen3-14B-ZNO with PEFT:
from peft import PeftModel
from transformers import AutoModelForCausalLM
base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen3-14B")
model = PeftModel.from_pretrained(base_model, "JustQuiteMadMax/Qwen3-14B-ZNO")How to use JustQuiteMadMax/Qwen3-14B-ZNO with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="JustQuiteMadMax/Qwen3-14B-ZNO")
messages = [
{"role": "user", "content": "Who are you?"},
]
pipe(messages) # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("JustQuiteMadMax/Qwen3-14B-ZNO")
model = AutoModelForCausalLM.from_pretrained("JustQuiteMadMax/Qwen3-14B-ZNO")
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]:]))How to use JustQuiteMadMax/Qwen3-14B-ZNO with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "JustQuiteMadMax/Qwen3-14B-ZNO"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "JustQuiteMadMax/Qwen3-14B-ZNO",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/JustQuiteMadMax/Qwen3-14B-ZNO
How to use JustQuiteMadMax/Qwen3-14B-ZNO with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "JustQuiteMadMax/Qwen3-14B-ZNO" \
--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": "JustQuiteMadMax/Qwen3-14B-ZNO",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'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 "JustQuiteMadMax/Qwen3-14B-ZNO" \
--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": "JustQuiteMadMax/Qwen3-14B-ZNO",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'How to use JustQuiteMadMax/Qwen3-14B-ZNO with Docker Model Runner:
docker model run hf.co/JustQuiteMadMax/Qwen3-14B-ZNO
axolotl version: 0.13.0.dev0
base_model: Qwen/Qwen3-14B
# Automatically upload checkpoint and final model to HF
hub_model_id: JustQuiteMadMax/Qwen3-14B-ZNO
plugins:
- axolotl.integrations.cut_cross_entropy.CutCrossEntropyPlugin
strict: false
chat_template: qwen3
datasets:
- path: JustQuiteMadMax/ZNO_Test_Conversations
type: chat_template
split: train
field_messages: messages
message_property_mappings:
role: from
content: value
val_set_size: 0.2
output_dir: ./outputs/out
dataset_prepared_path: last_run_prepared
sequence_len: 3072
sample_packing: true
eval_sample_packing: true
pad_to_sequence_len: true
load_in_4bit: true
adapter: qlora
lora_r: 16
lora_alpha: 32
lora_target_modules:
- q_proj
- k_proj
- v_proj
- o_proj
- down_proj
- up_proj
lora_mlp_kernel: true
lora_qkv_kernel: true
lora_o_kernel: true
use_wandb: true
wandb_project: genai-hw3-zno-train
wandb_entity: m-rudko-pn-ukrainian-catholic-university
wandb_watch:
wandb_name:
wandb_log_model: checkpoint
gradient_accumulation_steps: 2
micro_batch_size: 1
num_epochs: 1
optimizer: adamw_torch_4bit
lr_scheduler: cosine
learning_rate: 0.0002
bf16: auto
tf32: true
gradient_checkpointing: offload
gradient_checkpointing_kwargs:
use_reentrant: false
resume_from_checkpoint:
logging_steps: 1
flash_attention: true
warmup_steps: 10
evals_per_epoch: 4
saves_per_epoch: 1
weight_decay: 0.0
special_tokens:
This model is a fine-tuned version of Qwen/Qwen3-14B on the JustQuiteMadMax/ZNO_Test_Conversations dataset. It achieves the following results on the evaluation set:
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss | Active (gib) | Allocated (gib) | Reserved (gib) |
|---|---|---|---|---|---|---|
| No log | 0 | 0 | 2.0783 | 10.3 | 10.3 | 15.87 |
| 0.6365 | 0.2507 | 43 | 0.5787 | 10.36 | 10.36 | 11.98 |
| 0.5913 | 0.5015 | 86 | 0.5604 | 10.36 | 10.36 | 11.98 |
| 0.5179 | 0.7522 | 129 | 0.5582 | 10.36 | 10.36 | 11.98 |