LogoCua Documentation

Computer UI

The computer module includes a Gradio UI for creating and sharing demonstration data. We make it easy for people to build community datasets for better computer use models with an upload to Huggingface feature.

# Install with UI support
pip install "cua-computer[ui]"

Note

For precise control of the computer, we recommend using VNC or Screen Sharing instead of the Computer Gradio UI.

Building and Sharing Demonstrations with Huggingface

Follow these steps to contribute your own demonstrations:

1. Set up Huggingface Access

Set your HF_TOKEN in a .env file or in your environment variables:

# In .env file
HF_TOKEN=your_huggingface_token

2. Launch the Computer UI

# launch_ui.py
from computer.ui.gradio.app import create_gradio_ui
from dotenv import load_dotenv
load_dotenv('.env')

app = create_gradio_ui()
app.launch(share=False)

For examples, see Computer UI Examples

3. Record Your Tasks

View demonstration video

Record yourself performing various computer tasks using the UI.

4. Save Your Demonstrations

View demonstration video

Save each task by picking a descriptive name and adding relevant tags (e.g., "office", "web-browsing", "coding").

5. Record Additional Demonstrations

Repeat steps 3 and 4 until you have a good amount of demonstrations covering different tasks and scenarios.

6. Upload to Huggingface

View demonstration video

Upload your dataset to Huggingface by:

  • Naming it as {your_username}/{dataset_name}
  • Choosing public or private visibility
  • Optionally selecting specific tags to upload only tasks with certain tags

Examples and Resources