# Kernel Forge：用MCTS优化CUDA内核的开源智能体框架

- 来源：elvis (@omarsar0)
- 发布时间：2026-07-29 22:55
- AIHOT 分数：40
- AIHOT 链接：https://aihot.virxact.com/items/cms67jqlk1c2rrobk3ud5m2ej
- 原文链接：https://x.com/omarsar0/status/2082480019948122293

## AI 摘要

Kernel Forge 是一个开源智能体框架，能直接改写未修改 PyTorch 模型的 CUDA 内核，覆盖视觉、扩散和 LLM 任务。它用蒙特卡洛树搜索（MCTS）替代线性生成-修复流程，在 NVIDIA DGX Spark（GB10 GPU）上以每内核 50 次迭代优化了 4 个模型的 14 个内核，使其超越 PyTorch 基线。性能提升主要来自框架结构和原位集成，而非更强的模型。

## 正文

Impressive paper！

It's on one of the hardest tasks for coding agents today.

Of course， I am talking about kernel optimization. Coding agents are usually not so great at this.

Reasons： Unfamiliar low-level API， no room for a plausible-looking answer， and every candidate has to actually run and be faster.

Kernel Forge is an open-source agent harness that takes an unmodified PyTorch model in place and rewrites its CUDA kernels. It covers vision， diffusion， and LLM workloads.

Instead of a linear generate-and-fix chain， it runs Monte Carlo Tree Search over multiple optimization paths， with a GUI for monitoring progress， inspecting candidate kernels， and debugging failures.

On an NVIDIA DGX Spark with a GB10 GPU， at 50 optimization iterations per kernel， it optimized 14 kernels past their PyTorch baselines across four models.

It looks like the gain came from harness structure and in-place reintegration rather than a stronger model. That lesson repeats for any agent working against an API it was never trained on.

Paper： https://arxiv.org/abs/2607.24762

Learn to build effective AI agents in our academy： https://academy.dair.ai/
