Instructions to use llmfan46/Qwen3.6-35B-A3B-uncensored-heretic with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use llmfan46/Qwen3.6-35B-A3B-uncensored-heretic with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="llmfan46/Qwen3.6-35B-A3B-uncensored-heretic") 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("llmfan46/Qwen3.6-35B-A3B-uncensored-heretic") model = AutoModelForMultimodalLM.from_pretrained("llmfan46/Qwen3.6-35B-A3B-uncensored-heretic", 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 llmfan46/Qwen3.6-35B-A3B-uncensored-heretic with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "llmfan46/Qwen3.6-35B-A3B-uncensored-heretic" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "llmfan46/Qwen3.6-35B-A3B-uncensored-heretic", "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/llmfan46/Qwen3.6-35B-A3B-uncensored-heretic
- SGLang
How to use llmfan46/Qwen3.6-35B-A3B-uncensored-heretic 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 "llmfan46/Qwen3.6-35B-A3B-uncensored-heretic" \ --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": "llmfan46/Qwen3.6-35B-A3B-uncensored-heretic", "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 "llmfan46/Qwen3.6-35B-A3B-uncensored-heretic" \ --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": "llmfan46/Qwen3.6-35B-A3B-uncensored-heretic", "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 llmfan46/Qwen3.6-35B-A3B-uncensored-heretic with Docker Model Runner:
docker model run hf.co/llmfan46/Qwen3.6-35B-A3B-uncensored-heretic
Different Weight Key Nesting from The Original
The vision model weights in this repository are nested under an incorrect prefix than the original model from Qwen repository.
The original model uses model.visual.* as a prefix, but this repo uses model.language_model.visual.*.
Because the architecture Qwen3_5MoeForConditionalGeneration expects the vision tower to be a sibling of the language model rather than a child of it, loader scripts for conversion tools fail with a ValueError reporting hundreds of "extra" parameters.
The affected files are model.safetensors.index.json and model-00002-of-00002.safetensors. To fix this at the source, the keys inside the safetensors and the index map must be renamed. Below is a Python script that performs this correction:
import json
import os
from safetensors import safe_open
from safetensors.torch import save_file
model_path = "./llmfan46/Qwen3.6-35B-A3B-uncensored-heretic"
index_file = os.path.join(model_path, "model.safetensors.index.json")
# 1. Update Index Map
with open(index_file, "r") as f:
index = json.load(f)
weight_map = index["weight_map"]
new_weight_map = {}
files_to_update = set()
for key, val in weight_map.items():
if key.startswith("model.language_model.visual."):
new_key = key.replace("model.language_model.visual.", "model.visual.")
new_weight_map[new_key] = val
files_to_update.add(val)
else:
new_weight_map[key] = val
index["weight_map"] = new_weight_map
with open(index_file, "w") as f:
json.dump(index, f, indent=2)
# 2. Update Safetensors Files
for filename in files_to_update:
file_path = os.path.join(model_path, filename)
tensors = {}
with safe_open(file_path, framework="pt", device="cpu") as f:
for key in f.keys():
tensor = f.get_tensor(key)
if key.startswith("model.language_model.visual."):
new_key = key.replace("model.language_model.visual.", "model.visual.")
tensors[new_key] = tensor
else:
tensors[key] = tensor
save_file(tensors, file_path)
I was running into this when attempting to quantize it to oQ for MLX use. Thanks for the comment.
The vision model weights in this repository are nested under an incorrect prefix than the original model from Qwen repository.
It's not "incorrect", this model was exported with transformers 5.5.4 which is current (released in April 2026), the official model was exported with transformers 4.57.1 which is at this point very old (released in October 2025), there has been a lot of changes in transformers between version 4.57.1 and version 5.5.4, heck the latest transformers version is version 5.7.0 released only 15 days after version 5.5.4 and it is incompatible with models exported with version 5.5.4.