Skip to content

Commit 380d01f

Browse files
authored
Merge pull request #568 from trycua/new-improve-docs-home
Changes in Docs and CLI
2 parents 5fa4d05 + 22a9fb2 commit 380d01f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+3785
-4444
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Publish @trycua/cli to npm
2+
3+
on:
4+
push:
5+
branches: main
6+
7+
jobs:
8+
publish:
9+
permissions:
10+
id-token: write
11+
contents: read
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Setup Bun
17+
uses: oven-sh/setup-bun@v2
18+
with:
19+
bun-version: latest
20+
21+
- name: Check if version changed
22+
id: check-version
23+
uses: EndBug/version-check@v2
24+
with:
25+
file-name: libs/typescript/cua-cli/package.json
26+
diff-search: true
27+
28+
- name: Install dependencies
29+
if: steps.check-version.outputs.changed == 'true'
30+
working-directory: ./libs/typescript/cua-cli
31+
run: bun install --frozen-lockfile
32+
33+
- name: Build package
34+
if: steps.check-version.outputs.changed == 'true'
35+
working-directory: ./libs/typescript/cua-cli
36+
run: bun run build --if-present
37+
38+
- name: Publish to npm
39+
if: steps.check-version.outputs.changed == 'true'
40+
working-directory: ./libs/typescript/cua-cli
41+
run: bun publish --access public
42+
env:
43+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

.prettierignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,7 @@ venv/
2929
*.db
3030
*.sqlite
3131
pnpm-lock.yaml
32-
uv.lock
32+
uv.lock
33+
34+
# Docs with complex JSX formatting
35+
docs/content/docs/get-started/quickstart.mdx

README.md

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,7 @@
66
</picture>
77

88
[![Python](https://img.shields.io/badge/Python-333333?logo=python&logoColor=white&labelColor=333333)](#)
9-
[![Swift](https://img.shields.io/badge/Swift-F05138?logo=swift&logoColor=white)](#)
10-
[![macOS](https://img.shields.io/badge/macOS-000000?logo=apple&logoColor=F0F0F0)](#)
119
[![Discord](https://img.shields.io/badge/Discord-%235865F2.svg?&logo=discord&logoColor=white)](https://discord.com/invite/mVnXXpdE85)
12-
[![OSWorld](https://img.shields.io/badge/OSWorld-Benchmark-blue)](https://os-world.github.io/)
13-
[![HUD](https://img.shields.io/badge/HUD-Integration-green)](https://hud.so)
1410
<br>
1511
<a href="https://trendshift.io/repositories/13685" target="_blank"><img src="https://trendshift.io/api/badge/repositories/13685" alt="trycua%2Fcua | Trendshift" style="width: 250px; height: 55px;" width="250" height="55"/></a>
1612

@@ -121,7 +117,7 @@ from agent import ComputerAgent
121117
# ComputerAgent works with any computer initialized with the Computer SDK
122118

123119
agent = ComputerAgent(
124-
model="anthropic/claude-3-5-sonnet-20241022",
120+
model="anthropic/claude-sonnet-4-5-20250929",
125121
tools=[computer],
126122
max_trajectory_budget=5.0
127123
)
@@ -200,9 +196,9 @@ Cua uses the OpenAI Agent response format.
200196

201197
These are the valid model configurations for `ComputerAgent(model="...")`:
202198

203-
| Configuration | Description |
204-
| ---------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |
205-
| `{computer-use-model}` | A single model to perform all computer-use tasks |
199+
| Configuration | Description |
200+
| ---------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
201+
| `{computer-use-model}` | A single model to perform all computer-use tasks |
206202
| `{grounding-model}+{any-vlm-with-tools}` | [Composed](https://cua.ai/docs/agent-sdk/supported-agents/composed-agents) with VLM for captioning and grounding LLM for element detection |
207203
| `moondream3+{any-llm-with-tools}` | [Composed](https://cua.ai/docs/agent-sdk/supported-agents/composed-agents) with Moondream3 for captioning and UI element detection |
208204
| `human/human` | A [human-in-the-loop](https://cua.ai/docs/agent-sdk/supported-agents/human-in-the-loop) in place of a model |
@@ -372,32 +368,38 @@ Learn more in the [SOM documentation](./libs/python/som/README.md).
372368
## 2025
373369

374370
### September 2025
371+
375372
- **Hack the North Competition**: First benchmark-driven hackathon track with guaranteed YC interview prize. Winner achieved 68.3% on OSWorld-Tiny ([Blog Post](https://www.cua.ai/blog/hack-the-north))
376373
- **Global Hackathon Launch**: Ollama × Cua global online competition for creative local/hybrid agents
377374

378375
### August 2025
376+
379377
- **v0.4 Release - Composite Agents**: Mix grounding + planning models with `+` operator (e.g., `"GTA-7B+GPT-4o"`) ([Blog Post](https://www.cua.ai/blog/composite-agents))
380378
- **HUD Integration**: One-line benchmarking on OSWorld-Verified with live trace visualization ([Blog Post](https://www.cua.ai/blog/hud-agent-evals))
381379
- **Human-in-the-Loop**: Interactive agent mode with `human/human` model string
382380
- **Web-Based Computer Use**: Browser-based agent execution ([Blog Post](https://www.cua.ai/blog/bringing-computer-use-to-the-web))
383381

384382
### June 2025
383+
385384
- **Windows Sandbox Support**: Native Windows agent execution ([Blog Post](https://www.cua.ai/blog/windows-sandbox))
386385
- **Containerization Evolution**: From Lume to full Docker support ([Blog Post](https://www.cua.ai/blog/lume-to-containerization))
387386
- **Sandboxed Python Execution**: Secure code execution in agent workflows
388387

389388
### May 2025
389+
390390
- **Cua Cloud Containers**: Production-ready cloud deployment with elastic scaling ([Blog Post](https://www.cua.ai/blog/introducing-cua-cloud-containers))
391391
- **Trajectory Viewer**: Visual debugging tool for agent actions ([Blog Post](https://www.cua.ai/blog/trajectory-viewer))
392392
- **Training Data Collection**: Tools for creating computer-use training datasets ([Blog Post](https://www.cua.ai/blog/training-computer-use-models-trajectories-1))
393393
- **App-Use Framework**: Mobile and desktop app automation capabilities
394394

395395
### April 2025
396+
396397
- **Agent Framework v0.4**: Unified API for 100+ model configurations
397398
- **UI-TARS Integration**: Local inference support for ByteDance's desktop-optimized model
398399
- **Blog Series**: "Build Your Own Operator" tutorials ([Part 1](https://www.cua.ai/blog/build-your-own-operator-on-macos-1) | [Part 2](https://www.cua.ai/blog/build-your-own-operator-on-macos-2))
399400

400401
### March 2025
402+
401403
- **Initial Public Release**: Core Agent SDK and Computer SDK
402404
- **Lume VM Manager**: macOS VM management tool for local development
403405

blog/build-your-own-operator-on-macos-2.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ from agent import ComputerAgent
268268
async def run_multi_task_workflow():
269269
async with Computer() as macos_computer:
270270
agent = ComputerAgent(
271-
model="anthropic/claude-3-5-sonnet-20241022",
271+
model="anthropic/claude-sonnet-4-5-20250929",
272272
tools=[macos_computer]
273273
)
274274

docs/content/docs/agent-sdk/agent-loops.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ Use the following environment variables to configure the agent and its access to
8989

9090
```bash
9191
# Computer instance (cloud)
92-
export CUA_CONTAINER_NAME="your-container-name"
92+
export CUA_SANDBOX_NAME="your-sandbox-name"
9393
export CUA_API_KEY="your-cua-api-key"
9494

9595
# LLM API keys

docs/content/docs/agent-sdk/custom-computer-handlers.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ You can then use this as a tool for your agent:
3434
from agent import ComputerAgent
3535

3636
agent = ComputerAgent(
37-
model="anthropic/claude-3-5-sonnet-20241022",
37+
model="anthropic/claude-sonnet-4-5-20250929",
3838
tools=[custom_computer],
3939
)
4040

@@ -122,7 +122,7 @@ class MyCustomComputer(AsyncComputerHandler):
122122
custom_computer = MyCustomComputer()
123123

124124
agent = ComputerAgent(
125-
model="anthropic/claude-3-5-sonnet-20241022",
125+
model="anthropic/claude-sonnet-4-5-20250929",
126126
tools=[custom_computer],
127127
)
128128

docs/content/docs/agent-sdk/custom-tools.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def calculate(a: int, b: int) -> int:
1616

1717
# Use with agent
1818
agent = ComputerAgent(
19-
model="anthropic/claude-3-5-sonnet-20241022",
19+
model="anthropic/claude-sonnet-4-5-20250929",
2020
tools=[computer, calculate]
2121
)
2222
```
@@ -43,7 +43,7 @@ from computer import Computer
4343

4444
computer = Computer(...)
4545
agent = ComputerAgent(
46-
model="anthropic/claude-3-5-sonnet-20241022",
46+
model="anthropic/claude-sonnet-4-5-20250929",
4747
tools=[computer, read_file],
4848
)
4949
```
Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
11
{
22
"title": "Integrations",
3-
"pages": [
4-
"hud",
5-
"observability"
6-
]
7-
}
3+
"pages": ["hud", "observability"]
4+
}

docs/content/docs/agent-sdk/meta.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
"custom-computer-handlers",
1414
"prompt-caching",
1515
"usage-tracking",
16+
"telemetry",
1617
"benchmarks",
1718
"migration-guide",
1819
"integrations"
Lines changed: 41 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -1,135 +1,118 @@
11
---
22
title: Telemetry
3-
description: This document explains how telemetry works in CUA libraries and how you can control it.
4-
icon: RadioTower
3+
description: How telemetry works in Cua and how to control it
54
---
65

7-
# Telemetry in CUA
6+
# Telemetry
87

9-
CUA tracks anonymized usage and error report statistics; we ascribe to Posthog's approach as detailed [here](https://posthog.com/blog/open-source-telemetry-ethical). If you would like to opt out of sending anonymized info, you can set `telemetry_enabled` to false.
8+
Cua collects anonymized usage and error statistics. We follow [Posthog's ethical telemetry approach](https://posthog.com/blog/open-source-telemetry-ethical). To opt out, set `telemetry_enabled` to false.
109

11-
## What telemetry data we collect
10+
## What we collect
1211

13-
CUA libraries collect usage data to help improve our software. We have two categories of telemetry:
12+
### Enabled by default (opt-out)
1413

15-
### Opt-Out Telemetry (Enabled by Default)
14+
- System info: OS, OS version, Python version
15+
- Module initialization: When modules are imported and their versions
16+
- Performance: Agent run durations, step counts, token usage, API costs
17+
- Session tracking: Anonymous session IDs and run IDs
1618

17-
Basic performance metrics and system information that help us understand usage patterns:
18-
19-
- **System Information**: Operating system, OS version, Python version
20-
- **Module Initialization**: When modules are imported and their versions
21-
- **Performance Metrics**: Agent run durations, step counts, token usage, and API costs
22-
- **Session Tracking**: Anonymous session IDs and run IDs for performance analysis
23-
24-
### Opt-In Telemetry (Disabled by Default)
25-
26-
**Conversation Trajectory Logging**: Full conversation history including:
19+
### Disabled by default (opt-in)
2720

21+
**Trajectory logging** captures full conversation history:
2822
- User messages and agent responses
29-
- Computer actions and their outputs
30-
- Reasoning traces from the agent
23+
- Computer actions and outputs
24+
- Agent reasoning traces
3125

32-
**Important**: Trajectory logging is **opt-in only** and must be explicitly enabled.
26+
Must be explicitly enabled.
3327

34-
### We do NOT collect:
28+
### We don't collect
3529

3630
- Personal information or user identifiers
3731
- API keys or credentials
3832
- File contents or application data
39-
- Information about files being accessed
40-
- Actual screenshots or screen contents (unless trajectory logging is enabled)
41-
- Specific text being typed, including user inputs, model outputs, computer outputs, or tool call outputs (unless trajectory logging is enabled)
42-
43-
## Controlling Telemetry
33+
- Files being accessed
34+
- Screenshots or screen contents (unless trajectory logging is enabled)
35+
- Text being typed, user inputs, model outputs, computer outputs, or tool call outputs (unless trajectory logging is enabled)
4436

45-
We are committed to transparency and user control over telemetry. There are two ways to control telemetry:
37+
## How to disable
4638

47-
### 1. Environment Variable (Global Control)
39+
### Environment variable (global)
4840

49-
Telemetry is enabled by default. To disable telemetry, set the `CUA_TELEMETRY_ENABLED` environment variable to a falsy value (`0`, `false`, `no`, or `off`):
41+
Set `CUA_TELEMETRY_ENABLED` to a falsy value (`0`, `false`, `no`, or `off`):
5042

5143
```bash
52-
# Disable telemetry before running your script
5344
export CUA_TELEMETRY_ENABLED=false
54-
55-
# Or as part of the command
56-
CUA_TELEMETRY_ENABLED=1 python your_script.py
57-
5845
```
5946

60-
Or from Python:
47+
Or in Python:
6148

6249
```python
6350
import os
6451
os.environ["CUA_TELEMETRY_ENABLED"] = "false"
6552
```
6653

67-
### 2. Instance-Level Control
54+
### Per instance
6855

69-
#### Computer SDK
56+
**Computer SDK:**
7057

7158
```python
7259
from computer import Computer
7360

74-
# Enable telemetry (default)
75-
computer = Computer(telemetry_enabled=True)
76-
77-
# Disable telemetry
7861
computer = Computer(telemetry_enabled=False)
7962
```
8063

81-
#### Agent SDK
64+
**Agent SDK:**
8265

8366
```python
8467
from agent import ComputerAgent
8568
import os
8669

8770
# Basic telemetry - performance metrics only (opt-out, enabled by default)
8871
agent = ComputerAgent(
89-
model="claude-3-5-sonnet-20241022",
72+
model="claude-sonnet-4-5-20250929",
9073
telemetry_enabled=True # Default is True
9174
)
9275

9376
# Enable telemetry with full conversation trajectory logging (opt-in)
9477
agent = ComputerAgent(
95-
model="claude-3-5-sonnet-20241022",
78+
model="claude-sonnet-4-5-20250929",
9679
telemetry_enabled={
9780
"log_trajectory": True # Logs full conversation items
9881
}
9982
)
10083

101-
# Disable telemetry completely
84+
# Disable completely
10285
agent = ComputerAgent(
103-
model="claude-3-5-sonnet-20241022",
86+
model="claude-sonnet-4-5-20250929",
10487
telemetry_enabled=False
10588
)
10689

107-
# Disable telemetry completely using environment variables
108-
os.environ["CUA_TELEMETRY_ENABLED"] = "false"
90+
# Enable trajectory logging (opt-in)
10991
agent = ComputerAgent(
110-
model="claude-3-5-sonnet-20241022"
92+
model="claude-sonnet-4-5-20250929",
93+
telemetry_enabled={"log_trajectory": True}
11194
)
11295
```
11396

114-
You can check if telemetry is enabled for an instance:
97+
Check status:
11598

11699
```python
117-
print(computer.telemetry_enabled) # Will print True or False
118-
print(agent.telemetry_enabled) # Will print True, False, or dict
100+
print(computer.telemetry_enabled) # True or False
101+
print(agent.telemetry_enabled) # True, False, or dict
119102
```
120103

121-
Note that telemetry settings must be configured during initialization and cannot be changed after the object is created.
104+
Telemetry settings are configured at initialization and can't be changed afterward.
122105

123-
## Detailed Telemetry Events
106+
## Events collected
124107

125-
### Computer SDK Events
108+
### Computer SDK
126109

127110
| Event Name | Data Collected | Trigger Notes |
128111
| ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
129112
| **computer_initialized** |`os`: Operating system (e.g., 'windows', 'darwin', 'linux')<br />• `os_version`: OS version<br />• `python_version`: Python version | Triggered when a Computer instance is created |
130113
| **module_init** |`module`: "computer"<br />• `version`: Package version<br />• `python_version`: Full Python version string | Triggered once when the computer package is imported for the first time |
131114

132-
### Agent SDK Events
115+
### Agent SDK
133116

134117
| Event Name | Data Collected | Trigger Notes |
135118
| ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------- |
@@ -140,6 +123,6 @@ Note that telemetry settings must be configured during initialization and cannot
140123
| **agent_step** |`session_id`: Agent session UUID<br />• `run_id`: Run UUID<br />• `step`: Step number (incremental)<br />• `timestamp`: Unix timestamp<br />• `duration_seconds`: Duration of previous step | Triggered on each agent response/step during a run |
141124
| **agent_usage** |`session_id`: Agent session UUID<br />• `run_id`: Run UUID<br />• `step`: Current step number<br />• `prompt_tokens`: Tokens in prompt<br />• `completion_tokens`: Tokens in response<br />• `total_tokens`: Total tokens used<br />• `response_cost`: Cost of this API call | Triggered whenever usage information is received from LLM API |
142125

143-
## Transparency
126+
## Questions
144127

145-
We believe in being transparent about the data we collect. If you have any questions about our telemetry practices, please open an issue on our GitHub repository.
128+
Questions about telemetry? Open an issue on our [GitHub repository](https://github.com/trycua/cua).

0 commit comments

Comments
 (0)