Text Generation
Transformers
Safetensors
English
qwen3_recovered
qwen3
qwen
model-compression
pruning
depth-pruning
knowledge-distillation
efficient-inference
compressed
chat
conversational
e-ai
custom_code
Instructions to use atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1", trust_remote_code=True) messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1
- SGLang
How to use atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1 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 "atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1" \ --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": "atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1", "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 "atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1" \ --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": "atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1 with Docker Model Runner:
docker model run hf.co/atlasium-efficient/Qwen3-11B-30pct-Compressed-14B-EN-V1
File size: 1,785 Bytes
d390fc1 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | """Custom loader for the compressed Qwen3 checkpoint.
A standard Qwen3 with a reduced number of layers, plus two per-layer buffers
(`recover_scale`, `recover_bias`) applied at the start of each decoder layer's
forward. Layers carry scale=1, bias=0 where no correction is present.
Load with: AutoModelForCausalLM.from_pretrained(path, trust_remote_code=True)
"""
import torch
import torch.nn as nn
from transformers.models.qwen3.configuration_qwen3 import Qwen3Config
from transformers.models.qwen3.modeling_qwen3 import (
Qwen3ForCausalLM, Qwen3Model, Qwen3DecoderLayer)
class Qwen3RecoveredConfig(Qwen3Config):
model_type = "qwen3_recovered"
class RecoveredDecoderLayer(Qwen3DecoderLayer):
def __init__(self, config, layer_idx):
super().__init__(config, layer_idx)
h = config.hidden_size
self.register_buffer("recover_scale", torch.ones(h), persistent=True)
self.register_buffer("recover_bias", torch.zeros(h), persistent=True)
def forward(self, hidden_states, *args, **kwargs):
s = self.recover_scale.to(hidden_states.dtype)
b = self.recover_bias.to(hidden_states.dtype)
hidden_states = hidden_states * s + b
return super().forward(hidden_states, *args, **kwargs)
class Qwen3RecoveredModel(Qwen3Model):
config_class = Qwen3RecoveredConfig
def __init__(self, config):
super().__init__(config)
self.layers = nn.ModuleList(
[RecoveredDecoderLayer(config, i) for i in range(config.num_hidden_layers)])
self.post_init()
class Qwen3RecoveredForCausalLM(Qwen3ForCausalLM):
config_class = Qwen3RecoveredConfig
def __init__(self, config):
super().__init__(config)
self.model = Qwen3RecoveredModel(config)
self.post_init()
|