computer-agents 0.6.4 → 0.6.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3,7 +3,31 @@
3
3
  [![npm version](https://img.shields.io/npm/v/computer-agents.svg)](https://www.npmjs.com/package/computer-agents)
4
4
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5
5
 
6
- Build agents that write code, run tests, and modify files. Supports both local and cloud execution with automatic session management.
6
+ Build agents that write code, run tests, and modify files. Orchestrate unlimited agents in parallel with seamless local and cloud execution.
7
+
8
+ ## Why Computer Agents?
9
+
10
+ Traditional agent frameworks limit you to single-agent workflows or rigid orchestration patterns. Computer Agents is designed for programmatic multi-agent orchestration at scale.
11
+
12
+ **Unlimited Parallel Orchestration**
13
+ Compose and run unlimited agents concurrently. Build custom multi-agent workflows programmatically—you control execution flow and agent communication. No framework constraints, just code.
14
+
15
+ **Seamless Local ↔ Cloud Execution**
16
+ Develop locally, scale to cloud by changing workspace configuration. Runtime abstraction handles the complexity while your code remains identical. Switch execution environments without rewriting workflows.
17
+
18
+ **Two Powerful Agent Types**
19
+ - **LLM agents** (OpenAI API) for planning, reasoning, and code review
20
+ - **Computer agents** (Codex SDK) for code generation and file operations
21
+
22
+ Mix agent types to build sophisticated workflows. Computer agents bypass LLM for tool selection, providing faster execution and lower costs.
23
+
24
+ **Production-Ready Infrastructure**
25
+ - Automatic session continuity across runs
26
+ - Efficient workspace synchronization
27
+ - Built on OpenAI Codex SDK
28
+ - Type-safe TypeScript with comprehensive documentation
29
+
30
+ **Use cases:** Parallel test generation, distributed code review, large-scale refactoring, automated debugging workflows, multi-repository updates.
7
31
 
8
32
  ## Installation
9
33
 
@@ -80,62 +104,41 @@ const agent = new Agent({
80
104
  await run(agent, "Review the authentication implementation");
81
105
  ```
82
106
 
83
- ## Cloud Execution
84
-
85
- ### Cloud Agents
107
+ ## Multi-Agent Workflows
86
108
 
87
- Execute agents in cloud environments using the CloudClient:
109
+ Compose multiple agents for complex tasks:
88
110
 
89
111
  ```typescript
90
- import { Agent, run, CloudClient } from 'computer-agents';
112
+ import { Agent, run } from 'computer-agents';
91
113
 
92
- const client = new CloudClient({
93
- apiKey: process.env.TESTBASE_API_KEY
114
+ // LLM creates plan
115
+ const planner = new Agent({
116
+ agentType: 'llm',
117
+ model: 'gpt-4o',
118
+ instructions: 'Create implementation plans.'
94
119
  });
95
120
 
96
- // Create a cloud project
97
- const project = await client.createProject({ name: 'my-app' });
98
-
99
- // Cloud agent
100
- const agent = new Agent({
101
- agentType: "computer",
102
- workspace: project,
103
- instructions: "You are an expert developer."
121
+ // Computer agent executes
122
+ const executor = new Agent({
123
+ agentType: 'computer',
124
+ workspace: './my-project',
125
+ instructions: 'Execute implementation plans.'
104
126
  });
105
127
 
106
- const result = await run(agent, "Add error handling to the API");
107
- console.log(result.finalOutput);
108
- ```
109
-
110
- ### Project Management
111
-
112
- Manage cloud workspaces with the Project API:
113
-
114
- ```typescript
115
- import { CloudClient } from 'computer-agents';
116
-
117
- const client = new CloudClient({ apiKey: process.env.TESTBASE_API_KEY });
118
-
119
- // Create project with local sync
120
- const project = await client.createProject({
121
- name: 'my-app',
122
- localPath: './src' // Enables bidirectional sync
128
+ // LLM reviews result
129
+ const reviewer = new Agent({
130
+ agentType: 'llm',
131
+ model: 'gpt-4o',
132
+ instructions: 'Review code quality.'
123
133
  });
124
134
 
125
- // Sync files
126
- await project.sync({ direction: 'both' });
127
-
128
- // File operations
129
- const files = await project.listFiles();
130
- const content = await project.readFile('config.json');
131
- await project.writeFile('settings.json', '{"debug": true}');
132
-
133
- // Sync statistics
134
- const stats = await project.getSyncStats();
135
- console.log(stats); // { lastSyncAt, fileCount, version }
135
+ const task = "Add user authentication";
136
+ const plan = await run(planner, `Plan: ${task}`);
137
+ const code = await run(executor, plan.finalOutput);
138
+ const review = await run(reviewer, `Review: ${code.finalOutput}`);
136
139
  ```
137
140
 
138
- ### Streaming Events
141
+ ## Streaming Events
139
142
 
140
143
  Monitor agent execution in real-time:
141
144
 
@@ -165,40 +168,6 @@ for await (const event of runStreamed(agent, 'Create a web scraper')) {
165
168
  }
166
169
  ```
167
170
 
168
- ## Multi-Agent Workflows
169
-
170
- Compose multiple agents for complex tasks:
171
-
172
- ```typescript
173
- import { Agent, run } from 'computer-agents';
174
-
175
- // LLM creates plan
176
- const planner = new Agent({
177
- agentType: 'llm',
178
- model: 'gpt-4o',
179
- instructions: 'Create implementation plans.'
180
- });
181
-
182
- // Computer agent executes
183
- const executor = new Agent({
184
- agentType: 'computer',
185
- workspace: './my-project',
186
- instructions: 'Execute implementation plans.'
187
- });
188
-
189
- // LLM reviews result
190
- const reviewer = new Agent({
191
- agentType: 'llm',
192
- model: 'gpt-4o',
193
- instructions: 'Review code quality.'
194
- });
195
-
196
- const task = "Add user authentication";
197
- const plan = await run(planner, `Plan: ${task}`);
198
- const code = await run(executor, plan.finalOutput);
199
- const review = await run(reviewer, `Review: ${code.finalOutput}`);
200
- ```
201
-
202
171
  ## Session Continuity
203
172
 
204
173
  Agents automatically maintain context across multiple runs:
@@ -219,6 +188,41 @@ agent.resetSession(); // Start fresh
219
188
  await run(agent, 'New project'); // New session
220
189
  ```
221
190
 
191
+ ## Cloud Execution (Coming Soon)
192
+
193
+ > **Note**: Cloud execution with `CloudClient` and `Project` management is currently in private beta. Public access coming soon.
194
+ >
195
+ > Interested in early access? [Join the waitlist →](https://testbase.ai)
196
+
197
+ Cloud execution will enable:
198
+ - Run agents in isolated cloud environments
199
+ - Project-based workspace management with bidirectional sync
200
+ - Seamless transition from local to cloud with workspace configuration
201
+ - Parallel execution at scale without local resource constraints
202
+
203
+ Example (available in private beta):
204
+
205
+ ```typescript
206
+ import { Agent, run, CloudClient } from 'computer-agents';
207
+
208
+ const client = new CloudClient({
209
+ apiKey: process.env.TESTBASE_API_KEY
210
+ });
211
+
212
+ // Create a cloud project
213
+ const project = await client.createProject({ name: 'my-app' });
214
+
215
+ // Cloud agent
216
+ const agent = new Agent({
217
+ agentType: "computer",
218
+ workspace: project, // Use cloud project as workspace
219
+ instructions: "You are an expert developer."
220
+ });
221
+
222
+ const result = await run(agent, "Add error handling to the API");
223
+ console.log(result.finalOutput);
224
+ ```
225
+
222
226
  ## Configuration
223
227
 
224
228
  ### Agent Configuration
@@ -236,23 +240,13 @@ const agent = new Agent({
236
240
  });
237
241
  ```
238
242
 
239
- ### CloudClient Configuration
240
-
241
- ```typescript
242
- const client = new CloudClient({
243
- apiKey: process.env.TESTBASE_API_KEY, // Required
244
- debug: false, // Show detailed logs
245
- timeout: 600000, // 10 minutes (default)
246
- });
247
- ```
248
-
249
243
  ### Environment Variables
250
244
 
251
245
  ```bash
252
246
  # Required for all agents
253
247
  OPENAI_API_KEY=your-openai-key
254
248
 
255
- # Required for CloudClient
249
+ # Required for CloudClient (private beta)
256
250
  TESTBASE_API_KEY=your-testbase-key
257
251
  ```
258
252
 
@@ -320,7 +314,7 @@ function runStreamed(
320
314
  ): AsyncGenerator<Event>;
321
315
  ```
322
316
 
323
- ### CloudClient
317
+ ### CloudClient (Coming Soon)
324
318
 
325
319
  ```typescript
326
320
  class CloudClient {
@@ -333,7 +327,7 @@ class CloudClient {
333
327
  }
334
328
  ```
335
329
 
336
- ### Project
330
+ ### Project (Coming Soon)
337
331
 
338
332
  ```typescript
339
333
  class Project {
@@ -381,14 +375,6 @@ node examples/testbase/streaming-progress.cjs
381
375
  export OPENAI_API_KEY=sk-...
382
376
  ```
383
377
 
384
- ### "TESTBASE_API_KEY required"
385
-
386
- ```bash
387
- export TESTBASE_API_KEY=your-key
388
- # Or provide in constructor:
389
- new CloudClient({ apiKey: 'your-key' })
390
- ```
391
-
392
378
  ### "Computer agents require a workspace"
393
379
 
394
380
  Computer agents need a workspace parameter:
package/dist/metadata.js CHANGED
@@ -4,9 +4,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.METADATA = void 0;
5
5
  exports.METADATA = {
6
6
  "name": "computer-agents",
7
- "version": "0.6.4",
7
+ "version": "0.6.5",
8
8
  "versions": {
9
- "computer-agents": "0.6.4"
9
+ "computer-agents": "0.6.5"
10
10
  }
11
11
  };
12
12
  exports.default = exports.METADATA;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "computer-agents",
3
3
  "repository": "https://github.com/TestBase-ai/computer-agents",
4
4
  "homepage": "https://testbase.ai/computer-agents",
5
- "version": "0.6.4",
5
+ "version": "0.6.5",
6
6
  "description": "Build computer-use agents that write code, run tests, and deploy apps. Seamless local and cloud execution with automatic session continuity.",
7
7
  "author": "Testbase",
8
8
  "main": "dist/index.js",