跳到主内容
@wquguru
精选85MarkTechPost(RSS)产品发布/更新多源精选 ×12

Kimi AI 开源 AgentENV:支撑 K3 模型 RL 训练

Kimi AI and kvcache-ai Open Sources ‘AgentENV’: A Distributed System that Powers Agentic Reinforcement Learning (RL) Training for Kimi K3

原文
发到 X
推荐理由

做智能体 RL 训练的同学必看,AgentENV 解决了环境隔离与启动速度的痛点,快照分叉特性可大幅提升训练效率,赶紧试试 E2B 兼容 API 无缝迁移。

Moonshot AI’s Kimi team and kvcache-ai have open-sourced AgentENV (AENV), a distributed platform for running agent environments at scale. AgentENV powers agentic reinforcement learning (RL) training for Kimi K3, Moonshot’s 2.8-trillion-parameter Mixture-of-Experts model. The code ships under an MIT license.

Why Environment Infra Holds Back Agentic RL

Agentic RL does not just sample text. It requires the model to act inside a real computer. Every rollout needs an isolated Linux environment with a filesystem, a network stack, and live processes.

That requirement creates a hard trade-off. Containers start fast but share the host kernel, which weakens isolation for model-generated code. Full virtual machines isolate properly but boot slowly and hold memory while idle.

AgentENV targets exactly that gap. It runs Firecracker microVMs, then makes idle, restart, and branching cheap enough to run at training scale.

Inside AgentENV’s Firecracker Architecture

Each sandbox is a Firecracker microVM with its own Linux kernel, filesystem, and network namespace. Requests hit an Axum HTTP API, which forwards to an orchestrator that manages the sandbox lifecycle.

Storage is where the design gets interesting. The rootfs is served through a ublk userspace block device backed by overlaybd layered images. Read-only base layers are shared across sandboxes, and each sandbox writes into its own upper layer.

Inside every guest, a daemon called envd handles command execution, file operations, and health reporting on port 49983. A reverse proxy routes HTTP and WebSocket traffic from clients to services running inside the VM.

The project also lists two density mechanisms. The host page cache is shared across storage and memory-snapshot data. Memory ballooning returns reclaimable guest memory to the host, which sustains overcommit as environments diverge over time.

Snapshot, pause, resume, fork

These four features are the reason the project exists. AgentENV snapshots memory and filesystem changes incrementally rather than writing a full image each time.

The reported figures are as follows. Snapshot-backed environments boot or resume in under 50 ms and pause in under 100 ms. Incremental snapshot capture completes in under 100 ms, even under heavy disk modification.

Fork is the feature most specific to RL. A running sandbox can clone into up to 16 independent child sandboxes on the same node. The source pauses briefly during capture, then resumes. Every child inherits the source filesystem, memory, and resource configuration.

The practical effect is that expensive setup runs once. A team can install dependencies, clone a repository, and reach a task state. That exact state then branches into parallel rollouts. Snapshots persist to S3-compatible object storage or a shared distributed filesystem.

One default is worth noting. Every sandbox carries a TTL, and expiry triggers a pause, not a delete. Deletion requires passing autoPause: false on the create API.

On-demand loading and the snapshot repository

Images load on demand through overlaybd. Local disk acts as a bounded cache that retains hot data and evicts cold data.

This is what makes the fleet-level story work. Nodes do not need to pre-warm every image or hold a complete copy of every snapshot. The addressable image set can therefore exceed local disk capacity while startup stays fast cluster-wide.

Snapshot state is organized in three layers. A builder staging workspace holds artifacts during a build. A committed snapshot repository is the durable source of truth. A node-local runtime cache holds launch-time derived configs.

Two repository backends are supported: posix_fs (default) and oss. The oss path runs through a shared S3-compatible client, so an explicit region is required.

An optional peer-to-peer transport based on iroh can advertise committed artifacts to peer nodes. It is disabled by default. The documentation is explicit that P2P does not change the committed snapshot model. For shared storage, the docs ask for at least 1 Gbps and strongly recommend 10 Gbps or faster.

E2B compatibility is the adoption lever

AgentENV exposes an E2B-compatible HTTP API. Point E2B_API_URL at your server and the official E2B Python or TypeScript SDK works without code changes.

This is a deliberate distribution choice. Teams already running agents on E2B can self-host the runtime without rewriting their agent code. A native aenv CLI is also provided, and the docs recommend it for AgentENV-specific workflows.

Deployment paths

Prerequisites are Linux kernel 6.8+ and /dev/kvm access; the install script additionally requires Ubuntu 24.04. The aenv CLI supports Linux and macOS on x86_64 and arm64. The server itself is Linux-only, because it needs KVM.

Five paths are documented:

  • An install script that runs the server as a systemd service
  • A Docker image published at ghcr.io/kvcache-ai/aenv-server
  • A Docker Compose stack that simulates a multi-node cluster
  • Kubernetes manifests with a gateway, scheduler, and node DaemonSet
  • A build-from-source route using the Rust toolchain

Multi-node deployments add a gateway on :8080 and a scheduler on :9090.

Key Takeaways

  • Deployment covers install script, Docker, Docker Compose, and Kubernetes; the multi-node control plane is documented as a prototype.
  • AgentENV runs each agent environment as a Firecracker microVM, not a container, so isolation is kernel-level.
  • The project reports boot or resume under 50 ms, and pause under 100 ms, from snapshots.
  • A running sandbox can fork into up to 16 independent children on the same node.
  • The HTTP API is E2B-compatible, so existing E2B Python and TypeScript SDK code runs unchanged.

Check out the GitHub repository and documentation. All credit for this research goes to the researchers of this project.

The post Kimi AI and kvcache-ai Open Sources ‘AgentENV’: A Distributed System that Powers Agentic Reinforcement Learning (RL) Training for Kimi K3 appeared first on MarkTechPost.

更进一步:量化金融体系

看懂新闻只是起点——沿量化金融路径,把它变成能交付的工程能力

进入量化体系 →

关联讨论

同一事件的更多信源
Kimi K3开源权重模型发布,2.8万亿参数
Two Minute Papers(YouTube)原文
Kimi K3在WeirdML上接近Opus 4.8水平
Teortaxes▶️ (DeepSeek 推特🐋铁粉 2023 – ∞)原文
Kimi K3开源,2.8万亿参数全面开放
华尔街见闻(RSS)原文
开源权重争议与Kimi K3发布
Latent Space(RSS)原文
黄仁勋、Kimi K3与开源战争
数字生命卡兹克原文
月之暗面开源Kimi K3模型权重,2.8万亿参数
Simon Willison 博客(RSS)原文
月之暗面开源Kimi K3权重与基础设施
The Decoder(RSS)原文
Kimi K3 上线 Together AI
Kimi.ai原文
Kimi K3 开放权重,108B 参数
实践哥MinLi原文
Kimi K3 开源权重
宝玉原文
Kimi K3:2.8T参数开源模型发布
Hugging Face 每日论文(json_list)原文

相似阅读

另一事件,读法相近