ProductsSelected

Google Open-Sources AX, a Kubernetes-Style Runtime for Agents

Why we picked it

Agents accumulate state, idle while waiting on model responses and tool calls, and run untrusted code — so Kubernetes-style orchestration built for stateless microservices fits them poorly. AX treats agents as a first-class workload type with checkpointable tasks and declarative workspaces, which could shift how teams productionise agent fleets. Builders running agents at scale should compare it against self-rolled sandbox layers on Kubernetes; the MCP and tool-server support makes it especially relevant for agent infrastructure work.

Google has open-sourced AX, a declarative orchestration runtime for AI agent workloads, available at github.

Body

com/google/ax.Developers define agent tasks in YAML, and AX handles sandboxing, environment setup, network control and running them at scale.

The architecture consists of four binaries — ax (CLI), ax-server (gRPC API), ax-controller (reconciliation loop) and ax-task-runner (PID 1 in each task container) — plus Redis.

Core primitives include Task (isolated sandbox with CPU/memory limits, suspend and resume via checkpointing), Workspace (declarative environment setup with Git repos, MCP servers and skill packs, including a generative mode that spawns a bootstrap agent using GEMINI_API_KEY with a 10-minute default limit) and Model (named model resources referencing K8s Secrets).

Original · shao__meng

Google 开源了 "Agent 工作负载的 Kubernetes"「AX」 AX 是为 Agent 设计的声明式编排运行时,你用 YAML 声明一个 Agent 任务,AX 负责在集群中沙箱化、配置环境、管控网络并大规模运行它。 开源地址: github.com/google/ax 它解决什么问题 项目的立论很清晰:Agent 是一种既有的编排体系都不匹配的新型工作负载。 · 它不像微服务(无状态、常驻),Agent 会持续积累状态(对话记忆、工作区文件、工具会话); · 它不像批处理作业(跑完即弃),Agent 大部分时间在等待,等模型响应、等工具返回、等人类审批,期间沙箱空转烧钱; · 它运行的是不可信代码,需要严格隔离;它还调用外部模型 API 和 MCP 工具服务器,需要网络与凭据管控。 架构:四个二进制 + Redis 四个二进制分工:ax(开发者 CLI)、ax-server(无状态 gRPC API)、ax-controller(调和循环)、ax-task-runner(每个任务容器内的 PID 1)。 核心原语:Task / Workspace / Model (+ Gateway) Task 是最小执行单元:带 CPU/内存限制的隔离沙箱。AX 刻意把它做得细粒度、可自由组合:一个任务可以是全部工作,也可以是任务树的根节点。生命周期用 status.phase + Conditions 表达,支持挂起(检查点保存状态)与恢复。 Workspace 是最有产品想象力的一层。它把“环境准备”声明化:列出需要的 Git 仓库、MCP 服务器、技能包,runner 在命令启动前物化好。更激进的是 generative workspace:你可以只写一句自然语言目标("搭一个 Python 3 开发环境"),首次启动时 runner 会派一个引导 Agent(Antigravity,需 GEMINI_API_KEY,默认限时 10 分钟)去实际安装工具链并验证依赖。声明一次,任意任务复用。 Model 把“用哪个模型、什么参数、密钥在哪”抽成命名资源,密钥引用 K8s Secret。轮换密钥、锁版本、调温度只需一次 ax apply。 沙箱与运行时细节 每个任务容器以 ax-task-runner 为 PID 1:启动元数据服务(端口 80,HTTP/1.1+h2c,暴露 /healthz、/readyz 和任务/工作区自省端点——Agent 不需要 SDK 就能读到自己的配置)、按绑定顺序初始化工作区、然后 fork 出 spec.command 并持续监管。命令退出后 runner 仍驻留,所以 ax ssh 和元数据服务在命令结束后依然可用。停机采用 SIGTERM + 10 秒宽限 + 强杀的两级策略。 安全模型有几处值得注意的门控:guest 服务(任意进程执行与文件读写,ax ssh 的底层)默认关闭,只在 debug: true 时开启——ax ssh 连不上未开启的任务是刻意的安全设计,不是故障;Gateway 用显式 allowlist 管控出站流量,并可向入站请求注入凭据,避免把 API key 直接塞进 Agent 环境。 路线图透露的方向 五大方向:Actor 架构深化、空闲检测自动挂起、有状态任务 fork、任务级 SPIFFE 身份做零信任 mTLS、runner 层自动采集 OpenTelemetry 遥测与结构化 Agent 轨迹。📊 3 ⚡

Industry Coordinates & Source Verification

This report is categorized under AITOP's "Products" desk, focusing on US frontier AI labs and Silicon Valley technology leaders. Within our cross-regional analytical framework, it directly maps to AI developer toolchains, coding agents, and engineering workflows and US-China foundation model benchmarks and commercialization comparison. Key entities and technical topics under continuous tracking include Google, AX, agents, MCP.

Source attribution: curated from shao__meng (@shao__meng).