Technical Architecture and Best Practices for Enterprise General-Purpose AI Agents

    This article breaks down the technical architecture and engineering practices behind enterprise-grade general-purpose AI agents. It explains how these agents differ from traditional automation, introduces a six-plane reference architecture covering interaction, orchestration, tools, identity and permissions, runtime, and triggers, and addresses key challenges such as controllability, observability, evaluation, cost, and security. A phased adoption roadmap is also provided for teams looking to move agents beyond demos into core workflows.

    1. Introduction: From Chat Assistants to Agents That Deliver Work

    Over the past two years, most large model applications deployed inside enterprises have stayed in the form of a “Q&A assistant”: the user asks a question, the model answers, and closing the loop still depends on manual copy and paste. As model reasoning, tool-calling protocols, and runtime infrastructure have matured, the industry is shifting toward a new form—the general-purpose agent. It no longer outputs text only. Instead, it works toward a goal set by the user, autonomously breaks down steps, calls internal enterprise systems, moves and processes information across multiple applications, and takes responsibility for the result.

    A general-purpose agent product launched by a cloud vendor for enterprise work scenarios at an industry conference is a typical example of this trend: a single interface handles Q&A, knowledge work, content creation, and code writing and execution; it can connect to office suites and enterprise data; it supports creating “coworker agents” with independent identities and permissions that run tasks over the long term, with multiple sub-agents collaborating on complex work; it supports scheduled and event-triggered workflows; it can be accessed via web, mobile, desktop, and third-party collaboration platforms and office suites; and it exposes interfaces for external application integration. It is currently in private preview for enterprise customers.

    Setting aside specific product attributes, this article abstracts the general technical problems and engineering practices behind this class of systems and provides a reusable architecture reference.

    2. Redrawing Capability Boundaries: What Does an Agent Actually “Agent” For?

    To understand a general-purpose agent, first clarify how it differs from traditional automation (RPA, scripts, workflow engines):

    • Traditional automation: fixed processes, branches enumerated in advance, stable input structures, and interruption on any exception.
    • Intelligent agents: goals given in natural language, paths planned by the model at runtime, an extensible toolset, and exceptions that the model can retry or route around on its own.

    Therefore, an agent’s capability boundary is not “how smart the model is,” but the intersection of three things: the coverage of callable tools, the granularity of permission grants, and the runtime’s ability to support long-running tasks. If any one is missing, the agent degrades into a demo.

    3. Reference Architecture: Six Planes

    A deployable enterprise agent system can be divided into six planes.

    3.1 Interaction Plane (Unified Entry Point)

    The value of a unified entry point is to hide heterogeneous backend systems. Users do not need to know whether a capability comes from email, documents, or a code sandbox; they just describe the goal. In engineering terms, this requires maintaining session state, visualizing task progress, keeping an operation log that can be interrupted and rolled back, and providing secondary confirmation for high-risk actions.

    3.2 Orchestration Plane (Planning and Execution)

    The orchestration layer turns a goal into a task graph (DAG) and decides on serial, parallel, and conditional branches. The key design is separating planning from execution: first produce a human-readable plan for review, then execute it step by step; each step’s result is written back as context to drive the next decision.

    3.3 Tool Plane (Enterprise System Integration)

    Tools are registered in a registry with a unified description (name, purpose, input schema, permission requirements, idempotency), and the model uses them through a standardized calling protocol. Typical operations on office suites can be abstracted into a few categories:

    1. read_message / search_mail # retrieval and summarization
    2. read_file / write_file # document read and write
    3. append_row / query_table # spreadsheets and structured data
    4. post_message / create_event # collaboration and scheduling
    5. run_code / open_shell # code execution (inside a sandbox)

    Design essentials: least privilege, idempotency keys, rollback for write operations, and timeout and retry limits.

    3.4 Identity and Permission Plane (Governance Core for “Coworker Agents”)

    Once an agent has an independent identity, it becomes a “digital employee” within the organization and must be brought into the existing identity and access management system:

    • One identity per agent, with permissions granted independently and never mixed with the creator’s account;
    • Permissions requested and revoked dynamically over the task lifecycle, with privileges reduced as soon as the task ends;
    • All tool calls logged to form an auditable chain of operations;
    • Sensitive data masked at the field level by policy before entering the model context.

    3.5 Runtime Plane (Long Tasks and Multi-Agent Collaboration)

    Long tasks require persisted state (checkpoints), resume-from-breakpoint, and failure compensation. Complex work can be split among multiple sub-agents: the main agent handles planning and arbitration, while sub-agents each hold a restricted toolset and an independent context, exchanging intermediate artifacts through a message bus. For context management, a combination of “summary compression + writing structured intermediate artifacts to storage” is recommended to avoid unbounded context growth.

    3.6 Trigger and Integration Plane

    • Scheduled triggers: periodic inspections, daily report generation, data synchronization;
    • Event triggers: external events such as new emails, new tickets, and code merge requests driving the flow;
    • Channel access: web, mobile, desktop, and third-party collaboration/office platforms;
    • Open interfaces: exposing agent capabilities through standard interfaces so business systems can embed them.

    4. Key Technical Challenges and Responses

    Controllability: Model planning is inherently uncertain, so guardrails are required—tool whitelists, mandatory human confirmation for high-risk actions such as payments and deletions, and per-step budgets (time/number of calls/cost) with upper limits.

    Observability: Tracing must cover three chains—model calls, tool calls, and sub-agent messages—combined with logging services and monitoring alerts to form a task-level view rather than looking only at a single answer.

    Evaluation system: Build an offline evaluation set (task success rate, step redundancy, human intervention rate) and an online canary mechanism; any change to prompts or tool descriptions must go through regression.

    Cost control: For long tasks, adopt a tiered model strategy—strong models for planning, lightweight models for execution and summarization—and cache repeated retrieval results.

    Security and compliance: Data stays within its domain, encryption in transit and at rest, key management, and content compliance filtering; during private preview, start with a small-scale pilot first.

    5. Adoption Roadmap

    1. Pick a high-frequency, low-risk scenario with verifiable results (such as meeting-minutes organization or weekly report consolidation) and close the loop;
    2. Connect read-only tools first to validate the planning and permission chains, then gradually open write operations;
    3. Introduce scheduled and event triggers to turn “people finding the agent” into “the agent finding people”;
    4. Accumulate tool descriptions and evaluation sets to form reusable agent assets;
    5. Build the runtime on top of general cloud product capabilities from platforms such as Baidu AI Cloud (for example, container platforms, message queues, object storage, logging services, and monitoring alerts), maintaining architecture portability that is independent of any vendor.

    6. Conclusion

    The competitive focus of general-purpose agents is shifting from model capability to engineering and governance capability. Whoever builds solid permissions, auditing, long-task runtime, and evaluation systems will be able to bring agents into core enterprise workflows rather than leaving them at the demo stage.