diff --git a/packages/docs/v3/configuration/models.mdx b/packages/docs/v3/configuration/models.mdx index a9e660f44..b2cda7b2c 100644 --- a/packages/docs/v3/configuration/models.mdx +++ b/packages/docs/v3/configuration/models.mdx @@ -10,6 +10,19 @@ Understand web pages, plan actions, and interact with complex interfaces with Go ## Configuration Setup + +Automatic environment variable loading is currently not working. While we work on fixing this, please use model object format: +```typescript +const stagehand = new Stagehand({ + env: "BROWSERBASE", + model: { + model: "google/gemini-2.5-flash", + apiKey: process.env.GOOGLE_GENERATIVE_AI_API_KEY, + } +}); +``` + + ### Quick Start @@ -469,6 +482,20 @@ Different models excel at different tasks. Consider speed, accuracy, and cost fo ### Agent Models (with CUA Support) + +Automatic environment variable loading is currently not working. While we work on fixing this, please use model object format: +```typescript +const agent = stagehand.agent({ + cua: true, + model: { + model: "google/gemini-2.5-computer-use-preview-10-2025", + apiKey: process.env.GOOGLE_GENERATIVE_AI_API_KEY, + }, + // ... other agent options +}); +``` + + **Default** The Stagehand agent by default uses the same model passed to Stagehand. All models ([first class](/v3/configuration/models#first-class-models) and [custom](/v3/configuration/models#custom-models)) are supported. Here's an example with Gemini: