Improve model card for Variational Reasoning for Language Models

#1
by nielsr HF Staff - opened
Files changed (1) hide show
  1. README.md +53 -39
README.md CHANGED
@@ -1,37 +1,34 @@
1
  ---
2
  library_name: transformers
3
  tags: []
 
4
  ---
5
 
6
  # Model Card for Model ID
7
 
8
- <!-- Provide a quick summary of what the model is/does. -->
9
-
10
-
11
 
12
  ## Model Details
13
 
14
  ### Model Description
15
 
16
- <!-- Provide a longer summary of what this model is. -->
17
-
18
- This is the model card of a 🤗 transformers model that has been pushed on the Hub. This model card has been automatically generated.
19
 
20
- - **Developed by:** [More Information Needed]
21
- - **Funded by [optional]:** [More Information Needed]
22
- - **Shared by [optional]:** [More Information Needed]
23
- - **Model type:** [More Information Needed]
24
- - **Language(s) (NLP):** [More Information Needed]
25
- - **License:** [More Information Needed]
26
- - **Finetuned from model [optional]:** [More Information Needed]
27
 
28
  ### Model Sources [optional]
29
 
30
  <!-- Provide the basic links for the model. -->
31
 
32
- - **Repository:** [More Information Needed]
33
- - **Paper [optional]:** [More Information Needed]
34
- - **Demo [optional]:** [More Information Needed]
35
 
36
  ## Uses
37
 
@@ -39,37 +36,32 @@ This is the model card of a 🤗 transformers model that has been pushed on the
39
 
40
  ### Direct Use
41
 
42
- <!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
43
-
44
- [More Information Needed]
45
 
46
  ### Downstream Use [optional]
47
 
48
- <!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
49
-
50
  [More Information Needed]
51
 
52
  ### Out-of-Scope Use
53
 
54
- <!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
55
-
56
- [More Information Needed]
57
 
58
  ## Bias, Risks, and Limitations
59
 
60
  <!-- This section is meant to convey both technical and sociotechnical limitations. -->
61
 
62
- [More Information Needed]
63
 
64
  ### Recommendations
65
 
66
  <!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
67
 
68
- Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
69
 
70
  ## How to Get Started with the Model
71
 
72
  Use the code below to get started with the model.
 
73
 
74
  [More Information Needed]
75
 
@@ -79,12 +71,23 @@ Use the code below to get started with the model.
79
 
80
  <!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
81
 
82
- [More Information Needed]
83
 
84
  ### Training Procedure
85
 
86
  <!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
87
 
 
 
 
 
 
 
 
 
 
 
 
88
  #### Preprocessing [optional]
89
 
90
  [More Information Needed]
@@ -92,7 +95,7 @@ Use the code below to get started with the model.
92
 
93
  #### Training Hyperparameters
94
 
95
- - **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
96
 
97
  #### Speeds, Sizes, Times [optional]
98
 
@@ -106,6 +109,8 @@ Use the code below to get started with the model.
106
 
107
  ### Testing Data, Factors & Metrics
108
 
 
 
109
  #### Testing Data
110
 
111
  <!-- This should link to a Dataset Card if possible. -->
@@ -122,11 +127,11 @@ Use the code below to get started with the model.
122
 
123
  <!-- These are the evaluation metrics being used, ideally with a description of why. -->
124
 
125
- [More Information Needed]
126
 
127
  ### Results
128
 
129
- [More Information Needed]
130
 
131
  #### Summary
132
 
@@ -144,17 +149,17 @@ Use the code below to get started with the model.
144
 
145
  Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
146
 
147
- - **Hardware Type:** [More Information Needed]
148
- - **Hours used:** [More Information Needed]
149
- - **Cloud Provider:** [More Information Needed]
150
- - **Compute Region:** [More Information Needed]
151
- - **Carbon Emitted:** [More Information Needed]
152
 
153
  ## Technical Specifications [optional]
154
 
155
  ### Model Architecture and Objective
156
 
157
- [More Information Needed]
158
 
159
  ### Compute Infrastructure
160
 
@@ -172,13 +177,22 @@ Carbon emissions can be estimated using the [Machine Learning Impact calculator]
172
 
173
  <!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
174
 
 
 
175
  **BibTeX:**
176
 
177
- [More Information Needed]
 
 
 
 
 
 
 
178
 
179
  **APA:**
180
 
181
- [More Information Needed]
182
 
183
  ## Glossary [optional]
184
 
@@ -196,4 +210,4 @@ Carbon emissions can be estimated using the [Machine Learning Impact calculator]
196
 
197
  ## Model Card Contact
198
 
199
- [More Information Needed]
 
1
  ---
2
  library_name: transformers
3
  tags: []
4
+ pipeline_tag: text-generation
5
  ---
6
 
7
  # Model Card for Model ID
8
 
9
+ This model is based on the work presented in the paper [Variational Reasoning for Language Models](https://huggingface.co/papers/2509.22637). It introduces a variational reasoning framework for language models that treats thinking traces as latent variables and optimizes them through variational inference. The method aims to improve the reasoning ability of language models.
 
 
10
 
11
  ## Model Details
12
 
13
  ### Model Description
14
 
15
+ This model card describes a 🤗 transformers model that has been pushed on the Hub. This model card has been automatically generated.
 
 
16
 
17
+ - **Developed by:** Xiangxin Zhou, Zichen Liu, Haonan Wang, Chao Du, Min Lin, Chongxuan Li, Liang Wang, Tianyu Pang (Authors of the paper)
18
+ - **Funded by [optional]:** [More Information Needed]
19
+ - **Shared by [optional]:** [More Information Needed]
20
+ - **Model type:** Causal Language Model (Qwen3ForCausalLM), as indicated by `config.json`.
21
+ - **Language(s) (NLP):** English (as implied by common reasoning tasks and the source material.)
22
+ - **License:** [More Information Needed]
23
+ - **Finetuned from model [optional]:** The paper mentions "Qwen 2.5 and Qwen 3 model families". The `config.json` indicates `model_type: qwen3`. The GitHub README table lists backbones such as `Qwen3-4B-Base`, `Qwen3-8B-Base`, `Qwen2.5-7B-Instruct`, `Qwen2.5-32B-Instruct`.
24
 
25
  ### Model Sources [optional]
26
 
27
  <!-- Provide the basic links for the model. -->
28
 
29
+ - **Repository:** [https://github.com/sail-sg/variational-reasoning](https://github.com/sail-sg/variational-reasoning)
30
+ - **Paper [optional]:** [https://huggingface.co/papers/2509.22637](https://huggingface.co/papers/2509.22637)
31
+ - **Demo [optional]:** [More Information Needed]
32
 
33
  ## Uses
34
 
 
36
 
37
  ### Direct Use
38
 
39
+ The model is intended for improving the reasoning abilities of large language models, particularly on tasks requiring explicit thinking traces, as demonstrated in the paper.
 
 
40
 
41
  ### Downstream Use [optional]
42
 
 
 
43
  [More Information Needed]
44
 
45
  ### Out-of-Scope Use
46
 
47
+ The model is primarily designed for reasoning tasks. Its performance on general conversational or creative generation tasks without further fine-tuning may vary.
 
 
48
 
49
  ## Bias, Risks, and Limitations
50
 
51
  <!-- This section is meant to convey both technical and sociotechnical limitations. -->
52
 
53
+ General limitations of large language models apply, including potential biases inherited from training data, tendencies for hallucination, and sensitivity to prompt phrasing. The paper focuses on a principled probabilistic perspective for improving reasoning. Users should be aware that while reasoning is improved, these foundational limitations might still be present.
54
 
55
  ### Recommendations
56
 
57
  <!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
58
 
59
+ Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. Thorough testing and evaluation on specific target tasks and data are recommended to ensure suitability and mitigate potential issues.
60
 
61
  ## How to Get Started with the Model
62
 
63
  Use the code below to get started with the model.
64
+ For detailed instructions on setting up the environment, training, and evaluation, please refer to the official [GitHub repository](https://github.com/sail-sg/variational-reasoning).
65
 
66
  [More Information Needed]
67
 
 
71
 
72
  <!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
73
 
74
+ The models are trained using various datasets, including `Variational-Posterior-4B-Acc-mix`, `Variational-Posterior-4B-GML-mix`, `Variational-Posterior-8B-Acc-mix`, `Variational-Posterior-8B-GML-mix`, etc., as indicated in the GitHub repository's "Models and Datasets" table.
75
 
76
  ### Training Procedure
77
 
78
  <!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
79
 
80
+ The training procedure, detailed in the GitHub README, involves several steps:
81
+ 1. Training an initial reasoning model ($\pi_{\theta_0}$).
82
+ 2. Training a variational posterior ($q_\phi$).
83
+ 3. Sampling from the variational posterior.
84
+ 4. Estimating log likelihoods using both the initial reasoning model and the variational posterior.
85
+ 5. (Optional) Sampling from the initial reasoning model and verification (for accuracy-based estimator).
86
+ 6. Building the dataset for training the final reasoning model ($\pi_\theta$) using either geometric mean of token likelihood (GML) or accuracy-based estimators.
87
+ 7. Training the final reasoning model ($\pi_\theta$).
88
+
89
+ Detailed scripts are available in the GitHub repository under `LLaMA-Factory/variational_reasoning/train/`.
90
+
91
  #### Preprocessing [optional]
92
 
93
  [More Information Needed]
 
95
 
96
  #### Training Hyperparameters
97
 
98
+ Training is performed using DeepSpeed and assumes a distributed setup (e.g., 2 nodes x 8 H100 GPUs). `gradient_accumulation_steps` are adjusted to maintain effective batch size across different setups. Specific hyperparameters are outlined in `.yaml` files in the GitHub repository.
99
 
100
  #### Speeds, Sizes, Times [optional]
101
 
 
109
 
110
  ### Testing Data, Factors & Metrics
111
 
112
+ Evaluation is performed on a wide range of reasoning tasks. The GitHub repository provides details and scripts for evaluation under `SkyThought/variational_reasoning/eval/eval.sh`.
113
+
114
  #### Testing Data
115
 
116
  <!-- This should link to a Dataset Card if possible. -->
 
127
 
128
  <!-- These are the evaluation metrics being used, ideally with a description of why. -->
129
 
130
+ Evaluation metrics typically include accuracy or other task-specific performance measures relevant to reasoning tasks.
131
 
132
  ### Results
133
 
134
+ Results are empirically validated on Qwen 2.5 and Qwen 3 model families across various reasoning tasks. For detailed quantitative results, please refer to the [paper](https://huggingface.co/papers/2509.22637) and the evaluation scripts in the [GitHub repository](https://github.com/sail-sg/variational-reasoning).
135
 
136
  #### Summary
137
 
 
149
 
150
  Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
151
 
152
+ - **Hardware Type:** [More Information Needed]
153
+ - **Hours used:** [More Information Needed]
154
+ - **Cloud Provider:** [More Information Needed]
155
+ - **Compute Region:** [More Information Needed]
156
+ - **Carbon Emitted:** [More Information Needed]
157
 
158
  ## Technical Specifications [optional]
159
 
160
  ### Model Architecture and Objective
161
 
162
+ The model employs a variational reasoning framework that treats thinking traces as latent variables. It extends the Evidence Lower Bound (ELBO) to a multi-trace objective and proposes a forward-KL formulation for stable training. This framework unifies variational inference with RL-style methods to enhance language models' reasoning ability.
163
 
164
  ### Compute Infrastructure
165
 
 
177
 
178
  <!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
179
 
180
+ If you find this work useful, please consider citing the paper:
181
+
182
  **BibTeX:**
183
 
184
+ ```bib
185
+ @article{zhou2025variationalreasoninglanguagemodels,
186
+ title={Variational Reasoning for Language Models},
187
+ author={Xiangxin Zhou and Zichen Liu and Haonan Wang and Chao Du and Min Lin and Chongxuan Li and Liang Wang and Tianyu Pang},
188
+ journal={arXiv preprint arXiv:2509.22637},
189
+ year={2025}
190
+ }
191
+ ```
192
 
193
  **APA:**
194
 
195
+ Zhou, X., Liu, Z., Wang, H., Du, C., Lin, M., Li, C., Wang, L., & Pang, T. (2025). *Variational Reasoning for Language Models*. arXiv preprint arXiv:2509.22637.
196
 
197
  ## Glossary [optional]
198
 
 
210
 
211
  ## Model Card Contact
212
 
213
+ For questions related to this model, please refer to the contact information provided in the original paper or on the [GitHub repository](https://github.com/sail-sg/variational-reasoning).