Views
No views yet
GFusion-10B-A1.8B-base is an experimental pretrained diffusion language model trained by adapting GigaChat3-10B-A1.8B-base to block diffusion generation.GigaChat3-10B-A1.8B-base.| Decoding algorithm | Hyperparameter | Math TPF | Coding TPF | Avg. TPF |
|---|---|---|---|---|
| Threshold-based | τ = 0.85 | ×2.2028 | ×2.0780 | ×2.1404 |
| Threshold-based | τ = 0.90 | ×2.0033 | ×1.8662 | ×1.9348 |
| Threshold-based | τ = 0.95 | ×1.7385 | ×1.6235 | ×1.6810 |
| Entropy-bounded | γ = 0.70 | ×2.5786 | ×2.3755 | ×2.4771 |
| Entropy-bounded | γ = 0.35 | ×2.1640 | ×1.9817 | ×2.0729 |
| Entropy-bounded | γ = 0.15 | ×1.7993 | ×1.6798 | ×1.7396 |
| Benchmark | GFusion-base 10B-A1.8B | GigaChat3-base 10B-A1.8B | LLaDA-MoE-base 7B-A1.4B |
|---|---|---|---|
| MMLU | 71.73 | 71.20 | 64.59 |
| MMLU-Pro | 56.68 | 59.60 | 35.50 |
| TruthfulQA | 45.65 | 45.90 | -- |
| GSM8K | 82.18 | 79.50 | 66.41 |
| MGSM | 82.00 | 82.40 | -- |
| MATH | 24.04 | 23.10 | -- |
| MBPP | 56.40 | 55.80 | 52.40 |
| HumanEval | 50.00 | 49.40 | 45.73 |
1from transformers import AutoTokenizer, AutoModelForCausalLM
2
3device = "auto"
4model_path = "ai-sage/GFusion-10B-A1.8B-base"
5
6model = AutoModelForCausalLM.from_pretrained(
7 model_path, device_map=device, trust_remote_code=True
8)
9tokenizer = AutoTokenizer.from_pretrained(
10 model_path, device_map=device, trust_remote_code=True
11)
12
13prompt = "Here are the KKT optimality conditions:"
14inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
15
16outputs = model.generate(
17 **inputs,
18 max_new_tokens=512,
19 block_size=32,
20 gamma=0.70
21)
22
23print(tokenizer.decode(outputs[0]))1git clone https://github.com/sgl-project/sglang.git
2cd sglang
3
4git fetch origin refs/pull/29776/head:gfusion
5git switch gfusion1curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && source "$HOME/.cargo/env"
2pip install --upgrade pip
3
4######### CUDA 13 #########
5pip install -e "python[all]"
6
7######### CUDA 12 #########
8# 12.6 -> CU=126, KW=cu124
9# 12.8 -> CU=128, KW=cu129
10# 12.9 -> CU=129, KW=cu129
11
12CU=128 ; KW=cu129
13pip install --no-deps --force-reinstall \
14 "https://github.com/sgl-project/whl/releases/download/v0.4.4/sglang_kernel-0.4.4+${KW}-cp310-abi3-manylinux2014_$(uname -m).whl"
15
16# sglang + deps
17pip install --extra-index-url "https://download.pytorch.org/whl/cu${CU}" -e "python[all]"
18
19# re-pin the wheels to the cu12 build
20pip list --format=freeze | awk -F'==' '/-cu13(==|$)/ {print $1}' | xargs -r pip uninstall -y
21pip install --index-url "https://download.pytorch.org/whl/cu${CU}" --force-reinstall \
22 torch==2.11.0 torchvision==0.26.0 torchaudio==2.11.0
23pip install --no-deps --force-reinstall \
24 "https://github.com/sgl-project/whl/releases/download/v0.1.3/sgl_deep_gemm-0.1.3+cu129-py3-none-manylinux2014_$(uname -m).whl"1# eb_sampling.yaml
2gamma: 0.151python -m sglang.launch_server \
2 --model-path ai-sage/GFusion-10B-A1.8B-base \
3 --dllm-algorithm EBSampling \
4 --dllm-algorithm-config eb_sampling.yaml \
5 --attention-backend <fa3 or triton> \
6 --host 0.0.0.0 \
7 --port 30000 \
8 --dtype float16 \
9 --mem-fraction-static 0.88 \
10 --cuda-graph-bs-decode 11curl http://localhost:30000/v1/completions \
2 -H "Content-Type: application/json" \
3 -d '{
4 "model": "ai-sage/GFusion-10B-A1.8B-base",
5 "prompt": "Here are the KKT optimality conditions:",
6 "max_tokens": 128,
7 "temperature": 0
8 }'