Skip to content

Conversation

@atchudhansg
Copy link

Add Custom Task System for BrowserGym

Summary

Adds a custom task framework that allows users to create domain-specific BrowserGym tasks without depending on official benchmark packages.

Changes

  • Custom task framework: Base classes, models, and registry system for creating tasks
  • Example tasks: Copy-paste (single-tab) and copy-paste-multitab implementations
  • Documentation: Comprehensive guide in README with examples and best practices
  • Example script: browsergym_custom_example.py demonstrating usage
  • Test coverage: Basic tests for custom task system

Key Features

  • No BrowserGym package dependencies required
  • Direct Playwright browser control
  • Simple registration system
  • Rapid prototyping for domain-specific tasks
  • Follows MiniWoB design philosophy (minimal HTML, functional UI)

Usage

env = BrowserGymEnv(environment={
    "BROWSERGYM_BENCHMARK": "custom",
    "BROWSERGYM_TASK_NAME": "copy-paste"
})

Files Changed

  • custom - Custom task system implementation
  • README.md - Updated with custom tasks documentation
  • browsergym_custom_example.py - Usage example
  • .gitignore - Added myenv to exclude virtual environments

- Add custom task framework with base classes and models
- Implement copy-paste tasks (single-tab and multi-tab)
- Add comprehensive documentation in README
- Include example script for custom tasks
- Update .gitignore to exclude virtual environments
@meta-cla meta-cla bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 16, 2025
@atchudhansg atchudhansg changed the title feat: Add custom task system for BrowserGym environment Add custom task system for BrowserGym environment Nov 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant