NNetscape Navigator: Complex Demonstrations for Web Agents Without a Demonstrator

Shikhar Murty, Dzmitry Bahdanau, Christopher D. Manning · DOI

TL;DR

This paper introduces NNetNav, a novel method for generating synthetic demonstrations to train web browser agents. By leveraging large language models (LLMs) to interact with websites and then retroactively labeling these interactions, NNetNav bypasses the need for expensive human supervision and enables the creation of complex, hierarchical instructions for agents. This approach significantly improves the performance of LLM-based browser agents on benchmarks like WebArena and WebVoyager, achieving state-of-the-art results among unsupervised methods.

What Problem Does This Paper Address?

Building AI agents that can understand and execute human language instructions to interact with web browsers is a long-standing goal in AI. While large language models (LLMs) show promise, they struggle with the vast and ever-changing landscape of web interfaces. Traditional methods for training these agents rely heavily on human-generated demonstrations, which are costly and time-consuming to collect, especially for the sheer diversity of web content. Existing unsupervised or semi-supervised methods for generating training data have limitations in effectively exploring complex interaction spaces and generating truly hierarchical instructions that reflect real-world user tasks.

Methods

NNetNav employs a three-pronged approach using LLMs:

  1. Exploration Policy: A base LLM, prompted with a user persona and the current website's observation, generates action sequences to interact with the website. This exploration is designed to be diverse and discover potentially complex tasks.
  2. Trajectory Labeler: Another LLM retroactively labels the generated action sequences (trajectories) with natural language instructions. This is done by analyzing the state changes resulting from the actions.
  3. Outcome Reward Model (ORM): A third LLM evaluates whether the generated instruction and the corresponding state changes align. If the alignment is poor (low reward), the exploration episode is pruned, preventing the generation of low-quality demonstrations.

A key innovation is the use of language instructions as a pruning heuristic. If a trajectory prefix cannot be assigned a meaningful sub-task by the trajectory labeler, further exploration is stopped. This hierarchical pruning helps manage the exponential search space of web interactions. The method also includes a post-processing step where an agent policy re-generates actions to ensure they directly correspond to the inferred instruction.

Datasets

The paper introduces a new dataset of over 10,000 demonstrations collected using NNetNav. This dataset comprises interactions with:

  • 15 live, "in-the-wild" websites (e.g., Allrecipes, Amazon, Apple, ArXiv, BBC News, Booking, etc.).
  • 5 self-hosted websites from the WebArena benchmark.

The authors also mention using the MiniWoB++ dataset for controlled experiments.

Key Insights and Ideas

  • Interaction-First Generation: Instead of generating instructions first and then finding trajectories, NNetNav generates interactions first and then labels them. This "hindsight" approach is more robust for discovering complex, feasible tasks.
  • Hierarchical Pruning for Efficiency: Using language instructions as a pruning mechanism is crucial for navigating the vast web interaction space efficiently. This prevents the agent from getting lost in unproductive exploration.
  • Synthetic Data for State-of-the-Art: NNetNav demonstrates that high-quality synthetic data, generated without human supervision, can rival or surpass performance achieved with human-labeled data or zero-shot powerful models like GPT-4.
  • Cross-Website Transfer: Fine-tuning on NNetNav data shows promising transfer learning capabilities, though some domains might require more specialized data.

Key Results

  • WebArena: Fine-tuned Llama-3.1-8b agents achieved a 16.3% success rate, outperforming zero-shot GPT-4 by 2 points and setting a new state-of-the-art for unsupervised methods.
  • WebVoyager: The best model reached a 35.2% success rate, surpassing zero-shot GPT-4 by 1.7 points and establishing a new state-of-the-art among open-source methods.
  • Self-Training: Fine-tuning a smaller LM (Llama-3.1-8b) using NNetNav demonstrations generated by the same model yielded a 4-point absolute improvement on WebArena.
  • Complexity: The collected demonstrations were diverse, with a substantial number of complex, multi-step tasks.

Limitations and Future Work

  • Navigation Efficiency: While agents are good at element interaction and searching, they still struggle with navigation efficiency and can sometimes execute redundant steps.
  • Information Extraction: Extracting information from structured data like tables remains a challenge.
  • Bias Reinforcement: Training on live web content can reinforce existing biases present online. The authors urge practitioners to conduct thorough bias audits.
  • Future Work: The authors suggest focusing on heuristics to minimize unnecessary actions and improving the model's ability to parse and retrieve structured web content. They also highlight the potential for NNetNav to enable open-ended discovery of workflows on unknown web interfaces without human supervision.

Summary updated

BibTeX
@inproceedings{murty2024nnetscape,
  author = {Shikhar Murty and Dzmitry Bahdanau and Christopher D. Manning},
  title = {{NNetscape Navigator: Complex Demonstrations for Web Agents Without a Demonstrator}},
  booktitle = {SSI-FM @ ICLR},
  year = {2024},
  doi = {10.48550/arxiv.2410.02907},
}
Figure