How to use from
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 "dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf" \
    --host 0.0.0.0 \
    --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
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 "dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf" \
        --host 0.0.0.0 \
        --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
Quick Links

dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf

This repository contains a Hugging Face export of Mixtral-8x7B-v0.1 quantized with AQLM using the 2-bit 2x8 scheme.

Base model

  • mistralai/Mixtral-8x7B-v0.1

Quantization

  • Method: AQLM
  • Scheme: 2x8
  • Effective label: 2-bit
  • Source checkpoint: /work/bduan1/quantized_models/Mixtral-8x7B-AQLM-2bit-2x8

Conversion

This repo was produced with convert_to_hf.py from the AQLM project, then exported with --save_safetensors and --save_tokenizer.

Usage

from transformers import AutoModelForCausalLM, AutoTokenizer

model_id = "dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
    model_id,
    torch_dtype="auto",
    device_map="auto",
    trust_remote_code=True,
)
Downloads last month
65
Safetensors
Model size
12B params
Tensor type
F16
·
I8
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf

Quantized
(41)
this model

Collection including dbw6/Mixtral-8x7B-AQLM-2Bit-2x8-hf