Text Generation
Transformers
Safetensors
llama
eagle3
speculative-decoding
draft-model
gqa
vllm
torchspec
minimax
text-generation-inference
Instructions to use Inferact/MiniMax-M3-EAGLE3-GQA with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Inferact/MiniMax-M3-EAGLE3-GQA with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Inferact/MiniMax-M3-EAGLE3-GQA")# Load model directly from transformers import AutoTokenizer, LlamaForCausalLMEagle3 tokenizer = AutoTokenizer.from_pretrained("Inferact/MiniMax-M3-EAGLE3-GQA") model = LlamaForCausalLMEagle3.from_pretrained("Inferact/MiniMax-M3-EAGLE3-GQA", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Inferact/MiniMax-M3-EAGLE3-GQA with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Inferact/MiniMax-M3-EAGLE3-GQA" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Inferact/MiniMax-M3-EAGLE3-GQA", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Inferact/MiniMax-M3-EAGLE3-GQA
- SGLang
How to use Inferact/MiniMax-M3-EAGLE3-GQA 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 "Inferact/MiniMax-M3-EAGLE3-GQA" \ --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": "Inferact/MiniMax-M3-EAGLE3-GQA", "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 "Inferact/MiniMax-M3-EAGLE3-GQA" \ --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": "Inferact/MiniMax-M3-EAGLE3-GQA", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Inferact/MiniMax-M3-EAGLE3-GQA with Docker Model Runner:
docker model run hf.co/Inferact/MiniMax-M3-EAGLE3-GQA
Trim Performance section to MT-Bench + SPEED-Bench acceptance; drop MHA comparison
Browse files
README.md
CHANGED
|
@@ -25,15 +25,9 @@ The draft is a 1-layer dense Llama (`LlamaForCausalLMEagle3`) on MiniMax-M3's `h
|
|
| 25 |
|
| 26 |
## Performance
|
| 27 |
|
| 28 |
-
Mean accepted length measured end-to-end against `MiniMaxAI/MiniMax-M3-MXFP8` served with vLLM at `tensor-parallel-size=4`, `num_speculative_tokens=3`,
|
| 29 |
-
|
| 30 |
-
|
|
| 31 |
-
|---|---
|
| 32 |
-
|
|
| 33 |
-
|
|
| 34 |
-
| Code | [HumanEval](https://huggingface.co/datasets/openai/openai_humaneval) | 164 | 3.489 | 3.499 |
|
| 35 |
-
| Math | [MATH500](https://huggingface.co/datasets/HuggingFaceH4/MATH-500) | 500 | 3.510 | 3.517 |
|
| 36 |
-
| Math | [AIME](https://huggingface.co/datasets/Maxwell-Jia/AIME_2024) | 30 | 3.282 | 3.291 |
|
| 37 |
-
| | **Mean** | | **3.294** | 3.305 |
|
| 38 |
-
|
| 39 |
-
GQA matches the MHA version's acceptance (**~99.7%** of mean accepted length) while using **16× fewer** key/value heads.
|
|
|
|
| 25 |
|
| 26 |
## Performance
|
| 27 |
|
| 28 |
+
Mean accepted length and draft accept rate measured end-to-end against `MiniMaxAI/MiniMax-M3-MXFP8` served with vLLM at `tensor-parallel-size=4`, `num_speculative_tokens=3`, greedy sampling (`temperature=0`, `top_p=1.0`), `max-concurrency=16`.
|
| 29 |
+
|
| 30 |
+
| Dataset | n | Mean accepted length | Draft accept rate |
|
| 31 |
+
|---|---:|---:|---:|
|
| 32 |
+
| MT-Bench | 64 | 2.668 | 55.62% |
|
| 33 |
+
| SPEED-Bench (qualitative) | 64 | 2.561 | 52.04% |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|