AI Agents in Healthcare: A Practical Guide to Computer Use Automation

    This article examines how computer use agents are being applied in healthcare, explaining their three-layer architecture, a sample MRI request workflow, human-in-the-loop risk controls, evaluation metrics, and deployment considerations. It offers a practical reference for engineering teams looking to automate long, multi-system clinical processes without building custom integrations.

    1. Background: From Generating Content to Completing Workflows

    Over the past two years, most discussion around generative technology has focused on text creation and image generation. Enthusiasm has been high, but production use cases have remained relatively marginal. In November 2026, a research organization announced that its computer use agent had entered the healthcare sector, opening capabilities to institutions and clinical staff through a conversational entry point and a system development interface. In the evaluation it disclosed, licensed physicians reviewed electronic health record inbox tasks, and the clinical safety pass rate reached 99%.

    The real value of this announcement is not the score. It validates an engineering path: instead of integrating with existing system APIs, the agent operates the interface directly on a person’s behalf. Healthcare, insurance, government services, and finance share common traits: long workflows, many systems, and high modification costs. This path therefore has broad applicability.

    2. How It Works: How Agents “See” and Operate Interfaces

    A computer use agent relies on a three-layer loop:

    1. Perception layer: It captures screen pixels while reading the Accessibility Tree provided by the operating system, obtaining control types, names, coordinates, and hierarchy. Pixels serve as a fallback for recognition; the Accessibility Tree enables precise targeting. The two complement each other.
    2. Decision layer: It feeds the task goal, current interface state, and historical action sequence into the model, which outputs the next action instruction.
    3. Execution layer: Programmatic instructions drive mouse movement, clicks, drags, scrolls, and keyboard input, and shift focus between windows.

    From the host system’s perspective, these operations are no different from an administrative clerk using a keyboard and mouse. No dedicated interface from the target system is required.

    An illustrative action protocol (pseudocode, structure only):

    1. # Minimal set of actions
    2. ACTIONS = {
    3. "click": {"x": int, "y": int, "button": "left|right"},
    4. "type": {"text": str, "interval_ms": int},
    5. "scroll": {"dx": int, "dy": int},
    6. "hotkey": {"keys": ["ctrl", "s"]},
    7. "wait": {"state_predicate": "callable"},
    8. }
    9. def step(state, goal):
    10. a = policy(goal, state) # output one action
    11. execute(a) # execution layer
    12. return observe() # re-screenshot + read Accessibility Tree

    The most overlooked element in engineering is wait. Loading, dialogs, and session timeouts in real business systems are asynchronous. You must wait on state predicates rather than fixed sleeps; otherwise workflow stability degrades sharply.

    3. Workflow Breakdown: An End-to-End Imaging Request

    Consider a synthetic example: an MRI request for a patient with persistent lower back pain. The agent needs to:

    • Log in to the electronic health record system and retrieve the patient’s outpatient notes, physical therapy records, and prior plain film results from recent months;
    • Summarize the clinical facts and draft three documents: a compliant electronic imaging order, a progress note documenting examination findings and the indication for imaging, and a patient-facing reply draft;
    • Open a browser to the insurer’s approval site, fill in the documentation required for prior authorization item by item, and save the form in a pending state.

    The key design choice is that the endpoint is “pending confirmation,” not “submitted.” The order and reply remain in the physician’s to-do inbox, and the authorization form stays on the pre-review page for manual review by an authorization specialist. The agent sends no data and makes no final decisions.

    4. Human-AI Collaboration and Risk Controls

    • Least privilege: Assign the agent a separate account, grant the minimum visible scope by role, and prohibit access to sensitive modules such as approvals, billing, and permission management.
    • Human-in-the-loop: All outbound actions require manual confirmation, with secondary verification for high-risk actions.
    • Full audit trail: Log screenshots, Accessibility Tree snapshots, action parameters, and timing at every step to form a traceable evidence chain for incident review and accountability.
    • Data compliance: Use synthetic or de-identified data for training and demos. When personal health information is involved, follow the minimum necessary principle, encrypt data in transit and at rest, and mask sensitive fields in logs.
    • Interruptible and reversible: Set step limits, timeout circuit breakers, and an “abandon and return control” mechanism to prevent the agent from repeatedly trial-and-erroring on unfamiliar dialogs.

    5. Evaluation: What a 99% Pass Rate Means

    A single pass rate is not enough to support production use. At minimum, cover four categories of metrics:

    Dimension Focus
    Task completion rate Whether it produces documents with correct structure and complete fields
    Clinical/business safety Whether domain experts find factual errors or omissions
    Robustness Failure rate under interface redesigns, dialogs, and timeouts
    Explainability Whether each step can cite its source (note excerpts, field mappings)

    Domain expert review should be sampled, and outputs that are “plausible but factually wrong” should be tracked separately. These errors carry the highest cost in healthcare.

    6. Deployment Architecture Recommendations

    To build a similar system on Baidu AI Cloud, you can combine general-purpose capabilities: a container platform to host the agent runtime and browser sandbox, object storage for audit screenshots and document artifacts, a message queue to decouple task dispatch from result write-back, logging and monitoring with alerting to track success rate and latency, and key management to hold institutional account credentials. Keep three principles intact: non-intrusive integration, observability, and reversibility.

    7. Limitations and Outlook

    Interface dependency is inherently fragile. A target system redesign can break element targeting, so pair Accessibility Tree anchors with dual-channel visual verification. Cross-system state consistency, context growth in long workflows, accountability, and regulatory requirements still need to be solved through both policy and technology. The pragmatic path is to start with high-frequency, low-risk, text-heavy tasks and gradually expand the automation boundary, while keeping the final decision with humans.