Agent Lightning v1.0: Towards Harnessed Agentic RL

Zhiyuan He, Siwei Zhang, Zhiwen Zhou, Yuqing Yang, Yu Kang, Yuge Zhang, Luna K. Qiu, Tin Yan Tsui, Jiahang Xu, Chong Luo

arXiv:2608.17528 · 2026-08-20 공개 · arXiv · PDF

instruction-following swe-bench coding-agents rl-training agent-harness reproducible-research agent-lightning harnessed-agentic-rl

Abstract

Modern agents operate inside agent harnesses that manage tools, context, and control flow, making the harness a critical part of the agent system. Our original Agent Lightning introduced a disaggregated architecture that connects arbitrary agents to RL training through an LLM endpoint proxy, an approach later adopted by frameworks such as verl Uni-Agent, AReaL 2.0, slime, and Polar. We refer to this paradigm as harnessed agentic RL, where the deploy-time harness directly participates in model post-training. Harnessed agentic RL differs fundamentally from traditional agentic RL: the harness, rather than the training engine, owns the environment interaction loop, while the trainer observes only sequences of LLM request-response pairs. This introduces challenges in retokenization, sample merging, advantage calculation, loss normalization, and backend scheduling, which can substantially affect training stability and effectiveness. We present Agent Lightning v1.0, a lightweight framework for harnessed agentic RL implemented in approximately 3,500 lines of code. It supports arbitrary agent harnesses and serves as a practical testbed for studying these challenges. We evaluate it on instruction-following, search, and coding agents, and provide a complete reproducible pipeline for coding-agent RL. Using only 6K training examples and modest compute, RL improves Qwen3.5-9B on SWE-bench Verified from 41.8% to 56.4%, a 14.6-point absolute gain. We release the complete workflow and training scripts to facilitate reproducible research on harnessed agentic RL.

한국어 요약

한 줄 요약

Agent Lightning v1.0은 3,500줄의 코드로 구현된, 임의의 agent harness와 호환 가능한 harnessed agentic RL 프레임워크로, SWE-bench Verified에서 Qwen3.5-9B의 성능을 41.8%에서 56.4%로 14.6%p 향상시킨다.

핵심 기여도

핵심 아이디어

기존 agentic RL은 학습 엔진이 환경 상호작용 루프를 직접 관리하지만, **harnessed agentic RL**은 배포 시 사용되는 **agent harness가 이 루프를 소유**한다. 이는 학습 시스템이 단지 LLM 요청-응답 쌍을 관찰하게 되는 구조를 만든다. 이로 인해 **retokenization, sample merging, advantage calculation, loss normalization, backend scheduling** 등의 문제들이 발생하며, 기존 프레임워크들이 이들을 명확히 해결하지 못한 것으로 드러났다.

**Agent Lightning v1.0**은 이러한 문제를 해결하기 위해 **LLM endpoint proxy 기반의 disaggregated architecture**를 채택하여, 학습 프레임워크와 agent harness를 분리하고, 학습-배포 간 일관성을 유지한다. 이는 기존 RL 프레임워크에서 agent harness를 직접 구현해야 했던 복잡성을 줄이며, **OpenHands, OpenCode, mini-SWE-agent** 등 다양한 harness와 호환 가능하게 만든다.

기술적 접근법

주요 결과

의의 및 한계

**harnessed agentic RL**은 학습과 배포 간 일관성을 강화하며, 실제 환경에서의 성능을 반영하는 학습 방식을 가능하게 한다. Agent Lightning v1.0은 이 패러다임을 구현하는 첫 번째 **가벼운 프레임워크**로, 다양한 agent harness와 호환 가능하며, **retokenization, advantage calculation, loss normalization, backend scheduling** 등의 핵심 문제를 체계적으로 다룬다.

하지만, **동적 샘플 수 처리**나 **복잡한 agent orchestration**에 대한 일반화된 해결책은 아직 제시되지 않았으며, **대규모 컴퓨팅 자원 없이도 성능 향상이 가능하다는 점**은 일부 제한된 작업 환경에서만 적용 가능할 수 있다.

실용적 활용

Agent Lightning v1.0은 **coding agent, search agent, instruction-following agent** 등 다양한 agent 시스템에서 활용 가능하다. 특히, **SWE-bench Verified**와 같은 코드 생성 평가에서의 성능 향상은 소프트웨어 엔지니어링, 자동화 테스트, 코드 리뷰 등 산업 분야에서 실용적 활용이 기대된다. 또한, **재현 가능한 학습 파이프라인**은 연구자들이 harnessed agentic RL의 효과를 검증하고 확장하는 데 기여할 수 있다.