Text Generation
Transformers
Safetensors
qwen3
Generated from Trainer
conversational
text-generation-inference
Instructions to use timarni/qwen3-0.6B-reasoning-sft with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use timarni/qwen3-0.6B-reasoning-sft with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="timarni/qwen3-0.6B-reasoning-sft") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("timarni/qwen3-0.6B-reasoning-sft") model = AutoModelForCausalLM.from_pretrained("timarni/qwen3-0.6B-reasoning-sft", 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 timarni/qwen3-0.6B-reasoning-sft with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "timarni/qwen3-0.6B-reasoning-sft" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "timarni/qwen3-0.6B-reasoning-sft", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/timarni/qwen3-0.6B-reasoning-sft
- SGLang
How to use timarni/qwen3-0.6B-reasoning-sft 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 "timarni/qwen3-0.6B-reasoning-sft" \ --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": "timarni/qwen3-0.6B-reasoning-sft", "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 "timarni/qwen3-0.6B-reasoning-sft" \ --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": "timarni/qwen3-0.6B-reasoning-sft", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use timarni/qwen3-0.6B-reasoning-sft with Docker Model Runner:
docker model run hf.co/timarni/qwen3-0.6B-reasoning-sft
See axolotl config
axolotl version: 0.10.0.dev0
# Model Configuration
base_model: Qwen/Qwen3-0.6B-Base
type: AutoModelForCausalLM
tokenizer_type: AutoTokenizer
special_tokens:
flash_attention: true
flash_attn_rms_norm: true
flash_attn_fuse_qkv: false
sequence_len: 4096
chat_template: qwen3
# Dataset Configuration
shuffle_merged_datasets: true
dataset_processes: 8
sample_packing: true
pad_to_sequence_len: true
group_by_length: false
train_on_inputs: false
datasets:
- path: timarni/s1k_r1_clean
ds_type: json
type: chat_template
field_messages: conversations
message_property_mappings: {role: from, content: value}
# datasets:
# - path: "json"
# data_files: "/mloscratch/users/arni/reasoning_sft/data/s1k_r1/s1k_r1_think_token_cleaned.jsonl"
# type: chat_template
# ds_type: json
# split: train
# field_messages: conversations
# message_field_role: from
# message_field_content: value
# Training Hyperparameters
micro_batch_size: 1
gradient_accumulation_steps: 2
max_steps: 8500
num_epochs: 5
learning_rate: 1e-6 # 7e-7
optimizer: adamw_torch
optim_args:
fused: true
lr_scheduler: cosine
cosine_min_lr_ratio: 0
warmup_ratio: 0.05
weight_decay: 1.0e-4
adam_beta1: 0.9
adam_beta2: 0.95
gradient_checkpointing: true
gradient_checkpointing_kwargs:
use_reentrant: false
max_grad_norm: 1.0
# Hardware/Performance Configuration
load_in_4bit: false
load_in_8bit: false
deepspeed: /mloscratch/users/arni/meditron_protocol/training/sft/axolotl_config/deepspeed.json
xformers_attention: null
eager_attention: true
tf32: false
bf16: true
# Logging/Checkpointing
output_dir: /mloscratch/users/arni/models/qwen3-0.6B-Base-s1k_r1_reasoning_token
logging_steps: 1
saves_per_epoch: 1
resume_from_checkpoint: null
load_best_model_at_end: false
early_stopping_patience: 0
eval_set_size: 0.0
eval_table_size: null
# evals_per_epoch: 2
# eval_steps: 1000
# save_steps: 100
# WandB Configuration
wandb_project: mnlp # meditron-reasoning
wandb_entity: tim-arni # alexs-team
wandb_name: qwen3-0.6B-Base-s1k_r1_reasoning_token # medicouenne-7b-checkpoint-5742-medMCQA
mloscratch/users/arni/models/qwen3-0.6B-Base-s1k_r1_reasoning_token
This model is a fine-tuned version of Qwen/Qwen3-0.6B-Base on the /mloscratch/users/arni/reasoning_sft/data/s1k_r1/s1k_r1_think_token_cleaned.jsonl dataset.
Model description
More information needed
Intended uses & limitations
More information needed
Training and evaluation data
More information needed
Training procedure
Training hyperparameters
The following hyperparameters were used during training:
- learning_rate: 1e-06
- train_batch_size: 1
- eval_batch_size: 1
- seed: 42
- distributed_type: multi-GPU
- gradient_accumulation_steps: 2
- total_train_batch_size: 2
- optimizer: Use adamw_torch with betas=(0.9,0.95) and epsilon=1e-08 and optimizer_args=fused=True
- lr_scheduler_type: cosine
- lr_scheduler_warmup_steps: 11
- training_steps: 8500
Training results
Framework versions
- Transformers 4.51.3
- Pytorch 2.6.0+cu124
- Datasets 3.5.0
- Tokenizers 0.21.1
- Downloads last month
- 8
Model tree for timarni/qwen3-0.6B-reasoning-sft
Base model
Qwen/Qwen3-0.6B-Base