Akshat Bubna 从 workload shape 出发,解释 Modal 为什么把弹性推理、post-training、batch 与 agent sandboxes 建在一套自配置 runtime 上
Akshat Bubna 从 workload shape 出发,解释 Modal 为什么把弹性推理、post-training、batch 与 agent sandboxes 建在一套自配置 runtime 上。对谈深入 speculative decoding、GPU snapshot、17 家云供应商之上的可靠性层、私有网络与 RDMA,并讨论 DX …
Kubernetes 的稳态假设,遇上 AI 的 bursty、异构、跨区域需求。
agent 需要 typed interface、短反馈回路,也需要能从 CLI 读取运行状态。
它从 2023 年的实验 primitive,变成 production agent 的运行边界。
speculative decoding、GPU snapshot、tail latency 与 autoscaling 必须一起看。
sidecar、私有 overlay、RDMA 与地域 pinning 都进入 agent runtime。
LLM 可以参与策略判断,但 sandbox 仍需要不可绕过的 hard guardrails。
"Kubernetes is hard to manage. It's not built for burstiness"
Modal 的核心选择不是再加一层配置 UI,而是缩小配置表面积:
"why would you have an agent read through hundreds of Kubernetes files and like write YAML that's not even typed"
自定义模型与 LLM endpoint,需要快速 cold start 与弹性扩缩。
on-demand training、post-training 与研究者的小规模弹性实验。
编码、数据准备、计算生物等可延迟但计算量很大的任务。
后台 agent、RL rollout、持久化文件系统与受控网络。
访谈中的产品边界很明确:Modal 不把 always-on Web server 当作差异化重点;它押注需要 specialized compute、频繁 scale up/down 的负载。
最初服务 ETL、job queue 与各种 bursty processing;团队把 runtime 视为可复用 primitive。
GPU 在 ChatGPT 发布前一年进入产品,但团队当时没有预判它会成为如此大的机会。
音频、视频、机器人与计算生物公司带来第一批明确需求:模型不同,流量更不可预测。
"we added GPUs to the product a year before ChatGPT came out. We just didn't think it would be that big of a deal."
AI 推理的难点不只是找到一块 GPU:
关键判断:autoscaling 是产品能力,不是云厂商天然附送的属性;tail latency、交付语义和故障恢复仍要单独解决。
团队同时接触到多位需要隔离执行环境的客户;当时还没人确定它会成为大品类。
第一个公开示例把早期 coding agent 放入 sandbox,让它在隔离环境里反复修改与执行。
当时的模型、tool calling 与 self-correction 都不够成熟,循环很快失去意义。
这段历史的重点不是准确预测了 agent,而是先拥有一个通用隔离 primitive;模型能力跨过门槛后,旧能力突然获得新的 workload。
"you sometimes need 100,000 sandboxes."
typed decorator 比松散 YAML 更容易被模型一次写对,也更容易静态检查。
agent 修改配置后,runtime 自动 provision;反馈回路不必等待人工拼装环境。
日志、指标和运行状态进入 CLI,让 agent 能自己调查失败原因。
AX 不是把产品文档喂给 agent。Akshat 描述的是重新审视 interface:哪些能力应直接成为 CLI、哪些错误需要 benchmark、哪些配置表面积可以被删除。
人可能把生成代码当成黑盒,只描述想看到的外部行为。
CLI 暴露 logs、metrics、失败状态与部署结果,agent 先自行调查。
人根据可观察结果决定是否接受、回滚或继续 prompt 修改。
"you still need humans to go interpret what's going on"
Modal 把未来产品边界概括成两条链:
数据准备 → training / post-training → inference endpoint
目标与 harness → sandbox → persistent storage → networking
两条链共享同一底层需求:异构 compute、弹性调度、状态保存、区域选择与故障恢复。
一次只生成一个 token 时,推理常受 memory bandwidth 限制。
质量边界没有放松:draft model 负责提案,大模型仍掌握最终接受权。
转录边界:2–4x 是 Akshat 在讨论 accept length 时给出的量级;本页不把它推广为所有模型、硬件和流量模式下的保证。
用户可以从 UI 或 CLI 创建 endpoint,不必先触碰模型服务代码。
团队把 speculative decoding 等优化预先装进默认 endpoint,并提供弹性扩缩。
平台把代码交给用户;需要微调模型或改变架构时,可以退出默认层继续深改。
产品意图:frontier-level performance 不应只靠 deployed engineer 手工服务。随着流量分布变化,draft model 也可以跟着演化,同时保持代码透明。
Modal 选择资本轻、软件重的路径:
这条路线的经济前提:外部世界持续建设数据中心,Modal 用更强的软件与容量管理把碎片化供给变成统一产品。
不同 NeoCloud 的可靠性水平不同;单块 GPU 可能掉线,底层网络也会失败。
平台在上层重试、迁移或隔离故障,让用户 workload 不直接暴露给底层波动。
CPU、GPU 与 sandbox 需要 pin 到特定区域:有时为数据驻留,有时为端到端 latency。
访谈里的 collocation 不只是 GPU 靠近 CPU。它还意味着 agent 的 sandbox、数据与推理 endpoint 必须被放在合适的地理和网络位置。
"a sandbox is actually a pod of containers"
Modal 的 I6PN 为同一 workspace 内的 containers 分配私有 IPv6 地址:
"This is literally not even in our docs page. People somehow found it and they're using it."
给 function 增加 decorator,就能获得多节点 GPU cluster 与 RDMA networking。
重点是中等规模模型的 post-training,用更高质量支持后续 inference。
即使公司已有大 cluster,研究者仍持续做小 runs;这时按需弹性比固定配额更重要。
系统视角:post-training 不只是训练框架问题,还包括权重与 KV cache 的搬运、节点间通信、容量调度,以及训练与推理之间的衔接。
Akshat 观察到的形态更接近由模型直觉指导的 hyperparameter sweep,而不是改变网络架构的 neural architecture search。
Modal 内部 agent 会启动多组实验、运行 NVIDIA profiler、调整 configs,甚至比较 H200 与 B200。
"the agent will just spin up a sweep of different things."
记录 agent 在较难 Modal 任务上的具体失败。
补上日志定位、失败解释与正确修改路径。
把原本只在 UI 的 logs 与 metrics 移到 CLI。
agent 反复伸手找某个能力,可能说明产品就该提供它。
"if they're reaching for this thing it's product feedback like give it to them"
作者概括:Modal 的产品包含容量组合与 scheduler。控制全栈后,价格层级本身也能成为新的 API 能力。
访谈对 LLM-mediated permission 保持怀疑:
"you always need hard guard rails"
Modal 对 harness 保持中立:它可以运行在 managed agent 外部,也可以运行在 sandbox 内部。平台押注的是可控的 compute primitive,而不是唯一的 agent framework。
大量时间耗在准备 artifacts、恢复 dependencies 与重新搭环境,而不是执行测试本身。
memory snapshot 与 restore 可以把环境准备从每次重建变成状态恢复。
coding agents 生成更多变更,也会触发更多隔离、并行、短时的 CI workloads。
"runtime sandboxes have a different configuration surface"
"Kubernetes is hard to manage. It's not built for burstiness"
"why would you have an agent read through hundreds of Kubernetes files and like write YAML that's not even typed"
"you still need humans to go interpret what's going on"
"you sometimes need 100,000 sandboxes."
"improving kernel only give you like a few percentage points of improvement"
"a sandbox is actually a pod of containers"
"you always need hard guard rails"
"if they're reaching for this thing it's product feedback like give it to them"