WebSynthesis

April 10, 2026 ยท View on GitHub

overview

World Model-Guided MCTS for Efficient WebUI-Trajectory Synthesis

WebSynthesis is a framework integrating world model learning and Monte Carlo Tree Search (MCTS), designed to significantly reduce the cost of online synthesis of high-quality Web UI trajectories. Through a two-stage curriculum, including UI fundamental understanding and UI behavior cloning, the policy agent acquires web navigation capabilities.

framwork

News

  • [08/07/2025] ๐ŸŽ‰ Our Paper has been accepted as main conference in ACL 2026.
  • [08/07/2025] ๐Ÿ“ข Our Paper is now available in Arxiv.
  • [07/07/2025] ๐Ÿ“ข We upload some of the training data and LoRA weights.
  • [06/07/2025] ๐Ÿ“ข We release the code of WebSynthesis.

Two-stage Curriculum Learning

class

Project Structure

The WebSynthesis project is organized as follows:

WebSynthesis/
โ”œโ”€โ”€ config_files/              # Configuration files for different tasks (0.json, 1.json, ...)
โ”œโ”€โ”€ data/                      # Generated data from MCTS runs (created during execution)
โ”œโ”€โ”€ figure/                    # Images and figures used in the README and documentation
โ”œโ”€โ”€ models/                    # Model-related code
โ”‚   โ”œโ”€โ”€ get_response.py        # Functions for getting responses from models
โ”‚   โ””โ”€โ”€ models.py              # Model definitions and implementations
โ”œโ”€โ”€ utils/                     # Utility functions and helper modules
โ”‚   โ”œโ”€โ”€ new_obs_opt.py         # New observation optimization utilities
โ”‚   โ”œโ”€โ”€ obs_opt.py             # Observation optimization utilities
โ”‚   โ”œโ”€โ”€ prune_mcts.py          # MCTS pruning utilities
โ”‚   โ”œโ”€โ”€ query_llm.py           # LLM query utilities
โ”‚   โ”œโ”€โ”€ search_utils.py        # Search utilities
โ”‚   โ”œโ”€โ”€ text_utils.py          # Text processing utilities
โ”‚   โ”œโ”€โ”€ traj_utils.py          # Trajectory utilities
โ”‚   โ””โ”€โ”€ treeNode.py            # TreeNode implementation for MCTS
โ”œโ”€โ”€ webMCTS/                   # WebMCTS core implementation
โ”‚   โ”œโ”€โ”€ base.py                # Base classes for MCTS
โ”‚   โ”œโ”€โ”€ mcts.py                # MCTS algorithm implementation
โ”‚   โ”œโ”€โ”€ prompt.py              # Prompt templates for MCTS
โ”‚   โ””โ”€โ”€ task.py                # Task definitions for MCTS
โ”œโ”€โ”€ webmcts-ttraj/             # Traceable trajectories (created during execution)
โ”œโ”€โ”€ webmcts-vtraj/             # Valuable trajectories (created during execution)
โ”œโ”€โ”€ data/                      # Data generated by MCTS runs (created during execution)
โ”œโ”€โ”€ fuzzy_match.json           # Fuzzy matching cache
โ”œโ”€โ”€ merge.py                   # Script to merge and process MCTS data
โ”œโ”€โ”€ README.md                  # Project documentation
โ”œโ”€โ”€ run.py                     # Main script to run MCTS tasks
โ””โ”€โ”€ run.sh                     # Shell script to run MCTS on all config files

Key directories and files:

  • config_files/: Contains JSON configuration files for different MCTS tasks (numbered 0.json, 1.json, etc.)
  • webMCTS/: Core implementation of the WebMCTS algorithm
  • utils/: Helper modules for various functions like observation optimization, LLM querying, and trajectory processing
  • models/: Model-related code for the world model, reward model, and policy agents
  • run.py: Main entry point for running MCTS tasks
  • run.sh: Shell script to automatically run MCTS on all configuration files
  • merge.py: Script to process and merge the generated MCTS data into valuable and traceable trajectories

Data Collection (MCTS)

  1. Clone the GitHub Repository:

    git clone https://github.com/LucusFigoGao/WebSynthesis.git
    
  2. Collection:

    cd WebMCTS
    bash run.sh          # run MCTS
    pyhton merge.py      # merge the data
    

Data Resources

UI Fundamental Understanding

Model NameBase ModelTraining DataLoRA
TextUI-Cap-7BQwen2.5-Instruct-7BTextUI-dense-caption-training-data๐Ÿค— link
TextUI-Func-7BQwen2.5-Instruct-7BTextUI-functionality-training-data๐Ÿค— link
TextUI-Trans-7BQwen2.5-Instruct-7BTextUI-state-transition-training-data๐Ÿค— link

UI Behavior Cloning

Model NameBase ModelTraining DataLoRA
WebSynthesis-7BQwen2.5-Instruct-7BWebSynthesis-training-data๐Ÿค— coming soon
OS-Genesis-TextUI-7BQwen2.5-Instruct-7BOS-Genesis-training-data๐Ÿค— coming soon

Collection of World Model State Transition

Model NameBase ModelTraining DataLoRA
World Model 7BQwen2.5-Instruct-7Bworld-model-training-data๐Ÿค— coming soon

๐Ÿ™ Many thanks to the following open-source projects for their raw data contributions:

Main Experiment

main-exp

Ablation Studies

aba-exp

Scaling Analysis

scaling-exp

Case Study on WebMCTS

case

Case Study on World Model

case

Citation ๐Ÿ“–

๐Ÿซถ If you are interested in our work or find this repository / our data helpful, please consider using the following citation format when referencing our paper:

@misc{gao2025websynthesisworldmodelguidedmctsefficient,
   title={WebSynthesis: World-Model-Guided MCTS for Efficient WebUI-Trajectory Synthesis}, 
   author={Yifei Gao and Junhong Ye and Jiaqi Wang and Jitao Sang},
   year={2025},
   eprint={2507.04370},
   archivePrefix={arXiv},
   primaryClass={cs.AI},
   url={https://arxiv.org/abs/2507.04370}, 
}