Skip to content

feat: add Grok 4.5 computer use support#102

Merged
shrisukhani merged 3 commits into
mainfrom
devin/grok-4-5-computer-use
Jul 14, 2026
Merged

feat: add Grok 4.5 computer use support#102
shrisukhani merged 3 commits into
mainfrom
devin/grok-4-5-computer-use

Conversation

@shrisukhani

@shrisukhani shrisukhani commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Summary

Add SDK support for the new Grok 4.5 computer-use agent (grokcu) introduced in browserctrl#1212.

Changes

  • Add GrokComputerUseLlm (grok-4.5) and GrokReasoningEffort (low/medium/high) constants.
  • Add GrokComputerUseApiKeys, StartGrokComputerUseTaskParams, and response models (GrokComputerUseTaskResponse, GrokComputerUseTaskData, etc.).
  • Add sync and async GrokComputerUseManager (client.agents.grok_computer_use) wiring to /task/grok-computer-use endpoints.
  • Export new models from hyperbrowser.models.

Validation

  • poetry run ruff check .
  • poetry run ruff format . (ran, no issues)

Link to Devin session: https://app.devin.ai/sessions/5a70ddea4e9f4f0cb35baef951897bed
Requested by: @shrisukhani


Note

Low Risk
Additive SDK surface parallel to existing computer-use agents; no changes to auth, billing, or core transport beyond new routes and models.

Overview
Adds Grok computer-use as a first-class agent in the Python SDK, mirroring existing Gemini/Claude computer-use integrations.

New Pydantic models cover start params (task, grok-4.5 LLM, reasoning effort, session/options, optional xAI API keys, useComputerAction), job responses, step payloads (reusing CUA step error/reasoning shapes), and metadata. GrokComputerUseLlm and GrokReasoningEffort are added to consts and re-exported from hyperbrowser.models.

Sync and async GrokComputerUseManager expose start, get, get_status, stop, and start_and_wait against /task/grok-computer-use (with polling on terminal statuses). client.agents.grok_computer_use is wired on both client Agents facades.

A unit test asserts GrokComputerUseTaskResponse parses xAI-style step JSON (snake_case fields, nested error/incomplete/reasoning).

Reviewed by Cursor Bugbot for commit b0120da. Bugbot is set up for automated code reviews on this repo. Configure here.

@shrisukhani shrisukhani self-assigned this Jul 13, 2026
@devin-ai-integration

Copy link
Copy Markdown

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment, CI, and merge conflict monitoring

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 437f15c. Configure here.

Comment thread hyperbrowser/models/agents/grok_computer_use.py Outdated
Align created_at, completed_at, and error with CuaStepResponse so
completed Grok task payloads parse without Pydantic validation errors.
Reuse CUA step helper models for structured error, incomplete_details,
and reasoning fields.

Co-authored-by: Shri Sukhani <[email protected]>
@shrisukhani
shrisukhani merged commit a147a1f into main Jul 14, 2026
3 checks passed
@shrisukhani
shrisukhani deleted the devin/grok-4-5-computer-use branch July 14, 2026 05:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants