Text Generation
Transformers
Safetensors
qwen3
Generated from Trainer
unsloth
trl
sft
conversational
text-generation-inference
Instructions to use Ba2han/model-sft-q with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Ba2han/model-sft-q with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Ba2han/model-sft-q") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Ba2han/model-sft-q") model = AutoModelForCausalLM.from_pretrained("Ba2han/model-sft-q", 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=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Ba2han/model-sft-q with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Ba2han/model-sft-q" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Ba2han/model-sft-q", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Ba2han/model-sft-q
- SGLang
How to use Ba2han/model-sft-q 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 "Ba2han/model-sft-q" \ --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": "Ba2han/model-sft-q", "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 "Ba2han/model-sft-q" \ --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": "Ba2han/model-sft-q", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Unsloth Desktop
- Docker Model Runner
How to use Ba2han/model-sft-q with Docker Model Runner:
docker model run hf.co/Ba2han/model-sft-q
Commit History
-
Update tokenizer_config.json
Verified signaturee89b378 -
Upload tokenizer.json
Verified signature86047f1
-
Upload 2 files
Verified signature0e3f626
-
Training in progress, step 9146, checkpoint
Verified signaturea933d00 -
Training in progress, step 9146
Verified signature84604b7
-
Update generation_config.json
Verified signature31f9996 -
Update tokenizer_config.json
Verified signatured2b6434
-
Training in progress, step 3474, checkpoint
Verified signature530cbfe -
Training in progress, step 3474
Verified signatureecdd2ff -
Training in progress, step 2895, checkpoint
Verified signaturebce2692 -
Training in progress, step 2895
Verified signature5be17a0 -
Training in progress, step 2316, checkpoint
Verified signatured065df2 -
Training in progress, step 2316
Verified signatured56b482 -
Training in progress, step 1737, checkpoint
Verified signaturec5d1c6b -
Training in progress, step 1737
Verified signature107d2bc -
Training in progress, step 1158, checkpoint
Verified signaturefb0852f -
Training in progress, step 1158
Verified signatured4dcc2d -
Training in progress, step 579, checkpoint
Verified signature9b2316d -
Training in progress, step 579
Verified signature5b94745 -
initial commit
Verified signature8511624