Instructions to use AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi") model = AutoModelForMultimodalLM.from_pretrained("AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.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(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi
- SGLang
How to use AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi 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 "AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi" \ --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": "AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'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 "AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi" \ --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": "AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi with Docker Model Runner:
docker model run hf.co/AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi
Qwen3.5-4B Soyuz — Abliterated (v3)
Weight-orthogonalised version of AlexWortega/qwen35-4b-soyuz-merged. Removes the residual-stream "fail-mode" component identified from the model's own pass-vs-fail trajectory contrasts.
| Method | multi-layer per-layer ortho (L8-24), strength=0.5 |
|---|---|
| tbench-2 (17-task) | 2/17 |
| HermesAgent-20 | 6 / 20 |
| HA20 passes | HA-01, HA-02, HA-03, HA-06, HA-09, HA-11 |
Usage with sglang
python -m sglang.launch_server \
--model-path AlexWortega/qwen35-4b-soyuz-abliterated-v3-multi \
--dtype bfloat16 --trust-remote-code \
--tool-call-parser hermes \
--chat-template hermes_qwen.jinja
(hermes parser is needed for the <tool_call>{...}</tool_call> → OpenAI tool_calls conversion — without it agent benches see zero tool calls.)
Abliteration recipe
- Build pass-vs-fail contrast: 60 PASS trajectories (
reward=1.0) + 60 cleaned FAIL trajectories from soyuz's own evals (claw-eval, tbench-2, MMLU-Pi-agent). Fail trajectories filtered by Gemini-3-flash to keep onlyCLEAN_FAILlabels (235 of 246 negatives). - Capture last-token residual activations per layer over the rendered contrast (text-only
Qwen3_5ForCausalLM). - Compute per-layer direction =
mean(refuse) - mean(comply), normalise; pick best layer via AUC. - Orthogonalise model weights (embed rows + every layer's
o_proj.weightanddown_proj.weightcolumns) against the direction, optionally blended with strength α:W ← W − α · (W − W_orth). - Wrap text-only weights into the multimodal
Qwen3_5ForConditionalGenerationarch so sglang can serve them (vision tower preserved from base; only language_model.* weights are abliterated).
Repos
| Variant | tbench-17 | HA20 | Card |
|---|---|---|---|
baseline qwen35-4b-soyuz (LoRA) |
5/17 | 4/20 | link |
qwen35-4b-soyuz-abliterated-v2 (single-L, s=0.5) |
3/17 | 8/20 | link |
qwen35-4b-soyuz-abliterated-v3-multi (per-layer, s=0.5) |
2/17 | 6/20 | link |
v2 = highest HA20 (2× baseline). v3 picks up disjoint HA20 tasks (HA-01/02 memory-specific) that v2 misses.
W&B + raw eval logs: https://wandb.ai/alexwortega/vae-llm-agents (training base).
- Downloads last month
- 12