Instructions to use Hastagaras/Qibil-4B-v0.1-RP with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Hastagaras/Qibil-4B-v0.1-RP with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Hastagaras/Qibil-4B-v0.1-RP") 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("Hastagaras/Qibil-4B-v0.1-RP") model = AutoModelForCausalLM.from_pretrained("Hastagaras/Qibil-4B-v0.1-RP", 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]:])) - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Hastagaras/Qibil-4B-v0.1-RP with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Hastagaras/Qibil-4B-v0.1-RP" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Hastagaras/Qibil-4B-v0.1-RP", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Hastagaras/Qibil-4B-v0.1-RP
- SGLang
How to use Hastagaras/Qibil-4B-v0.1-RP 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 "Hastagaras/Qibil-4B-v0.1-RP" \ --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": "Hastagaras/Qibil-4B-v0.1-RP", "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 "Hastagaras/Qibil-4B-v0.1-RP" \ --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": "Hastagaras/Qibil-4B-v0.1-RP", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Hastagaras/Qibil-4B-v0.1-RP with Docker Model Runner:
docker model run hf.co/Hastagaras/Qibil-4B-v0.1-RP
This is an experimental RP finetune on top of Qwen3 4B Base. No reasoning data, just focusing on general instructions and RP.
Honestly, I'm not really used to finetuning Qwen models, so if you somehow stumble upon this and decide to try it, I'd really appreciate any feedback you might have, especially if you find issues.
Model Testing
This model has been trained with various structured outputs for both RP and general use. It should, therefore, be able to follow structured output formats based on the system prompt or the first message in an RP scenario. (well... most of the time, if it doesn't, please leave feedback)
Use ChatML template.
[EXAMPLE SYSTEM PROMPT]:
[EXAMPLE OUTPUT (Q6_K GGUF, TEMP=0.85, MIN_P=0.05)]:
Datatsets:
cognitivecomputations/dolphin-r1(non-reasoning) <- Used this in both stagesGryphe/Sonnet3.5-Charcard-Roleplay(filtered) <- First stage- Stories from Reddit (heavily filtered) <- First stage
- Some structured output data, kinda like IFeval <- First stage
LMSYSandHelpsteer(only the multiturn chats) <- Second stage- Gemma and Gemini RP data <- Second stage
(gray is first stage, and blue is the second stage)
- Downloads last month
- 29
[EXAMPLE OUTPUT (Q6_K GGUF, TEMP=0.85, MIN_P=0.05)]: 