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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Explore–Execute Chain (E2C)
|
| 2 |
+
|
| 3 |
+
This repository provides the implementation of our paper:
|
| 4 |
+
**Explore–Execute Chain: Towards an Efficient Structured Reasoning Paradigm**
|
| 5 |
+
*Kaisen Yang, Lixuan He, Rushi Shah, Kaicheng Yang, Qinwei Ma, Dianbo Liu, Alex Lamb*
|
| 6 |
+
|
| 7 |
+
> *Under review at ICLR 2026*
|
| 8 |
+
|
| 9 |
+
---
|
| 10 |
+
|
| 11 |
+
## 📖 Overview
|
| 12 |
+
|
| 13 |
+
Large Language Models (LLMs) often intertwine high-level planning with low-level execution, limiting both efficiency and interpretability.
|
| 14 |
+
The **Explore–Execute Chain (E2C)** framework addresses this challenge by **decoupling reasoning into two distinct stages**:
|
| 15 |
+
|
| 16 |
+
1. **Exploration** — Generate lightweight reasoning sketches (plans).
|
| 17 |
+
2. **Execution** — Select one or a few promising plans and execute them faithfully.
|
| 18 |
+
|
| 19 |
+
This separation offers multiple benefits:
|
| 20 |
+
|
| 21 |
+
* **Efficiency** — Short explorations reduce computation while preserving reasoning coverage.
|
| 22 |
+
* **Interpretability** — Exploration traces are explicit and auditable.
|
| 23 |
+
* **Adaptability** — Exploration can be domain-adapted with minimal supervision.
|
| 24 |
+
|
| 25 |
+
---
|
| 26 |
+
|
| 27 |
+
## 📝 Current Progress
|
| 28 |
+
|
| 29 |
+
**Released**
|
| 30 |
+
|
| 31 |
+
* ✅ Public release of **datasets** and **pretrained models**
|
| 32 |
+
|
| 33 |
+
**Ongoing**
|
| 34 |
+
|
| 35 |
+
* 🔄 Exploring more diverse **exploration strategies** and more reliable **execution mechanisms**
|
| 36 |
+
* 🔄 Cleaning and organizing **experimental code** for broader reproducibility
|
| 37 |
+
|
| 38 |
+
Stay tuned for further updates as we expand features and experiments.
|
| 39 |
+
|
| 40 |
+
---
|
| 41 |
+
|
| 42 |
+
## 🚀 Key Features
|
| 43 |
+
|
| 44 |
+
* **Two-stage training pipeline**:
|
| 45 |
+
|
| 46 |
+
* **E2C-SFT** — Supervised fine-tuning on synthetic exploration–execution pairs.
|
| 47 |
+
* **E2C-RL** — Reinforcement learning with token-level weighting tailored to exploration.
|
| 48 |
+
|
| 49 |
+
* **Efficient domain adaptation (EF-SFT)** — Adapt models with exploration-only data at minimal cost.
|
| 50 |
+
|
| 51 |
+
* **Test-time scaling** — Sample multiple explorations and aggregate them via clustering or LLM-based fusion.
|
| 52 |
+
|
| 53 |
+
* **Extensive benchmarks**:
|
| 54 |
+
|
| 55 |
+
* **Mathematical reasoning**: AIME’24/25, MATH500, Olympiad, Minerva.
|
| 56 |
+
* **Medical reasoning**: MedQA, MedMCQA, MMLU medical subsets.
|
| 57 |
+
|
| 58 |
+
---
|
| 59 |
+
|
| 60 |
+
## 📂 Repository Structure
|
| 61 |
+
|
| 62 |
+
```
|
| 63 |
+
.
|
| 64 |
+
├── data/ # Dataset preparation scripts and instructions
|
| 65 |
+
├── e2c/ # Core E2C framework
|
| 66 |
+
│ ├── sft/ # Supervised fine-tuning (E2C-SFT, EF-SFT)
|
| 67 |
+
│ ├── rl/ # Reinforcement learning (E2C-RL, GRPO baseline)
|
| 68 |
+
│ └── inference/ # Test-time scaling and evaluation
|
| 69 |
+
├── prompts/ # Prompt templates
|
| 70 |
+
├── scripts/ # Training / evaluation entrypoints
|
| 71 |
+
└── README.md
|
| 72 |
+
```
|
| 73 |
+
|
| 74 |
+
---
|
| 75 |
+
|
| 76 |
+
## ⚙️ Setup
|
| 77 |
+
|
| 78 |
+
### Requirements
|
| 79 |
+
|
| 80 |
+
See `e2c/verl/README.md` for details.
|
| 81 |
+
|
| 82 |
+
* Python 3.9+
|
| 83 |
+
* PyTorch ≥ 2.0
|
| 84 |
+
* HuggingFace Transformers
|
| 85 |
+
* sentence-transformers
|
| 86 |
+
* Additional packages in `requirements.txt`
|
| 87 |
+
|
| 88 |
+
Install dependencies via:
|
| 89 |
+
|
| 90 |
+
```bash
|
| 91 |
+
pip install -r requirements.txt
|
| 92 |
+
```
|
| 93 |
+
|
| 94 |
+
---
|
| 95 |
+
|
| 96 |
+
## 📥 Model Download
|
| 97 |
+
|
| 98 |
+
Pretrained and fine-tuned E2C models are available on Hugging Face.
|
| 99 |
+
|
| 100 |
+
```python
|
| 101 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 102 |
+
|
| 103 |
+
model_name = "your-org/e2c-model"
|
| 104 |
+
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
| 105 |
+
model = AutoModelForCausalLM.from_pretrained(model_name)
|
| 106 |
+
```
|
| 107 |
+
|
| 108 |
+
Or via CLI:
|
| 109 |
+
|
| 110 |
+
```bash
|
| 111 |
+
huggingface-cli download your-org/e2c-model
|
| 112 |
+
```
|
| 113 |
+
|
| 114 |
+
Replace `your-org/e2c-model` with the actual repository name.
|
| 115 |
+
|
| 116 |
+
---
|
| 117 |
+
|
| 118 |
+
## 🏋️ Training
|
| 119 |
+
|
| 120 |
+
### Stage 1: Supervised Fine-Tuning (E2C-SFT)
|
| 121 |
+
|
| 122 |
+
```bash
|
| 123 |
+
bash e2c/sft/train_sft.sh
|
| 124 |
+
```
|
| 125 |
+
|
| 126 |
+
### Stage 2: Reinforcement Learning (E2C-RL)
|
| 127 |
+
|
| 128 |
+
```bash
|
| 129 |
+
bash e2c/rl/train_rl.sh
|
| 130 |
+
```
|
| 131 |
+
|
| 132 |
+
### Efficient Adaptation (EF-SFT)
|
| 133 |
+
|
| 134 |
+
```bash
|
| 135 |
+
bash e2c/sft/train_ef_sft.sh
|
| 136 |
+
```
|
| 137 |
+
|
| 138 |
+
---
|
| 139 |
+
|
| 140 |
+
## 🔍 Evaluation
|
| 141 |
+
|
| 142 |
+
Run evaluation and test-time scaling:
|
| 143 |
+
|
| 144 |
+
```bash
|
| 145 |
+
bash e2c/inference/evaluate.sh
|
| 146 |
+
```
|
| 147 |
+
|
| 148 |
+
Supported strategies include:
|
| 149 |
+
|
| 150 |
+
* **E2C-Select (Self LM-Judge)**
|
| 151 |
+
* **E2C-Select (Semantic Cluster)**
|
| 152 |
+
* **E2C-SC (Self-Consistency)**
|
| 153 |
+
* **E2C-RP (Random Plan)**
|
| 154 |
+
|
| 155 |
+
---
|
| 156 |
+
|
| 157 |
+
## 📊 Results
|
| 158 |
+
|
| 159 |
+
E2C consistently improves over GRPO baselines with reduced cost.
|
| 160 |
+
|
| 161 |
+
* On **AIME’24**, Qwen3-4B + E2C-(SFT+RL) yields **+8.7% accuracy gain** over GRPO.
|
| 162 |
+
* On **medical reasoning**, EF-SFT adapts with only **3.5% of training tokens**, surpassing standard SFT.
|
| 163 |
+
|
| 164 |
+
See the paper for detailed results and ablations.
|
| 165 |
+
|
| 166 |
+
---
|
| 167 |
+
|
| 168 |
+
## 🙏 Credits
|
| 169 |
+
|
| 170 |
+
This work builds upon the **VERL** framework, which has been instrumental for training and experimentation.
|
| 171 |
+
We thank the authors for releasing such a powerful and flexible platform.
|
| 172 |
+
|
| 173 |
+
---
|
| 174 |
+
|
| 175 |
+
## 📌 Notes
|
| 176 |
+
|
| 177 |
+
* This repository is **work in progress**; some datasets and scripts are placeholders.
|
| 178 |
+
* Full reproduction may require additional setup.
|
| 179 |
+
* Hyperparameters and prompt templates are provided in the paper appendices.
|
| 180 |
+
* We are still improving the training process and codebase for better usability.
|
| 181 |
+
|
| 182 |
+
---
|
| 183 |
+
|
| 184 |
+
## 📜 Citation
|
| 185 |
+
|
| 186 |
+
If you use this work, please cite:
|
| 187 |
+
|
| 188 |
+
**BibTeX**
|
| 189 |
+
|
| 190 |
+
```bibtex
|
| 191 |
+
@inproceedings{yang2026explore,
|
| 192 |
+
title={Explore--Execute Chain: Towards an Efficient Structured Reasoning Paradigm},
|
| 193 |
+
author={Yang, Kaisen and He, Lixuan and Shah, Rushi and Yang, Kaicheng and Ma, Qinwei and Liu, Dianbo and Lamb, Alex},
|
| 194 |
+
booktitle={International Conference on Learning Representations (ICLR)},
|
| 195 |
+
year={2026},
|
| 196 |
+
note={under review}
|
| 197 |
+
}
|
| 198 |
+
```
|
| 199 |
+
|
| 200 |
+
**APA**
|
| 201 |
+
|
| 202 |
+
> Yang, K., He, L., Shah, R., Yang, K., Ma, Q., Liu, D., & Lamb, A. (2026). *Explore–Execute Chain: Towards an Efficient Structured Reasoning Paradigm*. International Conference on Learning Representations (ICLR). (Under review)
|
| 203 |
+
|
| 204 |
+
**MLA**
|
| 205 |
+
|
| 206 |
+
> Yang, Kaisen, et al. "Explore–Execute Chain: Towards an Efficient Structured Reasoning Paradigm." *International Conference on Learning Representations (ICLR)*, 2026. Under review.
|
| 207 |
+
|
| 208 |
+
---
|
| 209 |
+
|
| 210 |
+
## 🧾 License
|
| 211 |
+
|
| 212 |
+
This project is licensed under the **MIT License**.
|
| 213 |
+
See the [LICENSE](LICENSE) file for details.
|