Skip to main content

CUA (Computer Use) Agent for AI-driven computer interaction

Project description

Shows my svg

Python macOS Discord PyPI

Agent is a Computer Use (CUA) framework for running multi-app agentic workflows targeting macOS and Linux sandbox, supporting local (Ollama) and cloud model providers (OpenAI, Anthropic, Groq, DeepSeek, Qwen). The framework integrates with Microsoft's OmniParser for enhanced UI understanding and interaction.

Get started with Agent

from agent import ComputerAgent, AgentLoop, LLMProvider
from computer import Computer

computer = Computer(verbosity=logging.INFO)

agent = ComputerAgent(
    computer=computer,
    loop=AgentLoop.ANTHROPIC,
    # loop=AgentLoop.OMNI,
    model=LLM(provider=LLMProvider.ANTHROPIC, name="claude-3-7-sonnet-20250219"),
    # model=LLM(provider=LLMProvider.OPENAI, name="gpt-4.5-preview"),
    save_trajectory=True,
    trajectory_dir=str(Path("trajectories")),
    only_n_most_recent_images=3,
    verbosity=logging.INFO,
)

tasks = [
"""
Please help me with the following task:
1. Open Safari browser
2. Go to Wikipedia.org
3. Search for "Claude AI" 
4. Summarize the main points you find about Claude AI
"""
]

async with agent:
    for i, task in enumerate(tasks, 1):
        print(f"\nExecuting task {i}/{len(tasks)}: {task}")
        async for result in agent.run(task):
            print(result)
        print(f"Task {i} completed")

Install

cua-agent

pip install "cua-agent[all]"

# or install specific loop providers
pip install "cua-agent[anthropic]"
pip install "cua-agent[omni]"

Run

Refer to these notebooks for step-by-step guides on how to use the Computer-Use Agent (CUA):

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cua_agent-0.1.5.tar.gz (68.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cua_agent-0.1.5-py3-none-any.whl (92.7 kB view details)

Uploaded Python 3

File details

Details for the file cua_agent-0.1.5.tar.gz.

File metadata

  • Download URL: cua_agent-0.1.5.tar.gz
  • Upload date:
  • Size: 68.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.11

File hashes

Hashes for cua_agent-0.1.5.tar.gz
Algorithm Hash digest
SHA256 2d9c774ad7b36a8859476ca83ae8a1ac659a773b47b3976d6fe04a58f27c4288
MD5 19f583824ebf76146b53373ec9fcee4d
BLAKE2b-256 3d24d52b325f7967453039ba2d6f54789ee6521d6a9dde308429d9a4519d892f

See more details on using hashes here.

File details

Details for the file cua_agent-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: cua_agent-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 92.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.11

File hashes

Hashes for cua_agent-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 38a5afc92746903548da6d2a26d39f18ecc7730b24715f70a4cbeab50812172d
MD5 7f8cedda6650ae4155e61cfa1532b3d4
BLAKE2b-256 8b51d8b3bc96bc347bd4c07bd2858cefc2a79e7efcb047f8126de902cfd479d2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page