File size: 1,911 Bytes
31dc8dc
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# Diffulex Benchmark Configuration Example
# This configuration uses nested structure with engine and eval sections

# Engine configuration - Parameters for Diffulex engine initialization
engine:
  # Model and weights
  model_path: "Dream-org/Dream-v0-Base-7B"
  tokenizer_path: null  # Optional, defaults to model_path
  model_name: "dream"  # Options include dream, sdar, sdar_moe, fast_dllm_v2, llada, llada2, ...
  decoding_strategy: "d2f"  # Options: d2f, multi_bd, dmax
  sampling_mode: "naive"  # Options: naive, edit
  mask_token_id: 151666

  # LoRA configuration
  use_lora: false
  lora_path: ""
  pre_merge_lora: true  # Merge LoRA at load to avoid per-forward compute

  # Parallelism configuration
  tensor_parallel_size: 1
  data_parallel_size: 1
  expert_parallel_size: 1

  # Memory and capacity configuration
  gpu_memory_utilization: 0.7
  max_model_len: 4096
  max_num_batched_tokens: 4096
  max_num_reqs: 128

  # Engine behavior configuration
  enforce_eager: true
  enable_prefix_caching: true
  kv_cache_layout: "unified"  # Options: unified, distinct
  page_size: 32
  token_merge_mode: "dmax_topk"
  token_merge_top_k: 1
  token_merge_renormalize: true
  token_merge_weight: 1.0

  # D2F-specific configuration
  decoding_thresholds:
    add_block_threshold: 0.1
    semi_complete_threshold: 0.9
    accept_threshold: 0.9

  block_size: 32  # Aligned with diffulex Config.block_size
  buffer_size: 4

# Evaluation configuration - Parameters for benchmark evaluation
eval:
  # Task/Dataset configuration (bundled Lightning JSON under diffulex_bench/data/lightning)
  dataset_name: "gsm8k_diffulex"
  dataset_split: "test"
  dataset_limit: 10  # Optional, limit number of samples (set to 10 for testing)

  # Sampling configuration
  temperature: 0.0
  max_tokens: 512
  ignore_eos: false

  # Output configuration
  output_dir: "benchmark_results"
  save_results: true
  use_tqdm: true