[chore] update supported CUA models (#2064)

Merged
MI
7mo ago
+14-0

What Changed

Adds three new models to the list of supported CUA (Computer Use Agent) models:

  • openai/gpt-5.4-mini
  • openai/gpt-5.5
  • anthropic/claude-haiku-4-5

Files Changed

packages/core/lib/v3/types/public/agent.ts

  • Added the three models to the AVAILABLE_CUA_MODELS const array
  • This drives:
    • The AvailableCuaModel type
    • The runtime CUA model check in resolveModel()

packages/core/lib/v3/agent/AgentProvider.ts

  • Added model → provider mappings in modelToAgentProviderMap:
    • gpt-5.4-mini → openai
    • gpt-5.5 → openai
    • claude-haiku-4-5 → anthropic
  • Ensures AgentProvider.getAgentProvider() resolves them correctly

packages/core/tests/unit/public-api/llm-and-agents.test.ts

  • Updated the expectedModels list in the type-level test to stay in sync with the source of truth

How It Was Tested

  • ✅ Build passes (pnpm turbo run build)
  • ✅ All 204 public-api unit tests pass
  • ✅ All 608 unit tests pass
  • ⚠️ 4 pre-existing failures in flowlogger-eventstore.test.js (confirmed on base branch)

Summary by cubic

Adds support for three new Computer Use Agent models and maps them to the right providers. Apps can now use openai/gpt-5.4-mini, openai/gpt-5.5, and anthropic/claude-haiku-4-5 via the public API.

  • New Features
    • Registered the models in AVAILABLE_CUA_MODELS and mapped providers: gpt-5.4-mini → openai, gpt-5.5 → openai, claude-haiku-4-5 → anthropic.
    • Updated public API tests to include the new models.
    • Added a changeset to release these additions as a patch in @browserbasehq/stagehand.