Harness Handbook: Making Evolving Agent Harnesses Readable,Navigable, and Editable

Ruhan Wang, Yucheng Shi, Zongxia Li, Zhongzhi Li, Yue Yu, Junyao Yang, Kishan Panaganti, Haitao Mi, Dongruo Zhou, Leoweiliang

arXiv:2607.13285 · 2026-07-16 공개 · arXiv · PDF

long-context agent-harness llm-assisted code-modification code-search static-analysis behavior-localization harness-evolution

Abstract

The capability of a modern AI agent depends not only on its foundation model but also on its harness, which constructs prompts, manages state, invokes tools, and coordinates execution. As models, APIs, environments, and requirements evolve, the harness must be continually modified. Before such a change can be made, a developer or coding agent must identify all code locations that implement the target behavior. This is difficult because production harnesses are large, tightly coupled, and behaviorally distributed, while modification requests describe what the system should do and repositories are organized by files and modules. Code search, repository indexing, and long-context processing ease inspection, but still leave this behavior-to-code mapping to be recovered by hand. Behavior localization is therefore a central bottleneck in harness evolution. We introduce the Harness Handbook, a behavior-centric representation synthesized automatically from a harness codebase via static analysis and LLM-assisted structuring, linking each behavior to its corresponding source. We also introduce Behavior-Guided Progressive Disclosure (BGPD), which guides agents from high-level behaviors to relevant implementation details and verifies candidate locations against the current source. On diverse modification requests from two open-source harnesses, Handbook-Assisted planning improves behavior localization and edit-plan quality while using fewer planner tokens, with the largest gains on scattered sites, rarely executed paths, and cross-module interactions. Evolving complex agentic systems thus depends not only on generating edits, but also on determining where those edits should be made.

한국어 요약

한 줄 요약

현대 AI 에이전트의 허네스 진화를 효율화하기 위해 행동 중심의 자동 생성 가이드인 Harness Handbook과 BGPD 프로세스를 제안한다.

핵심 기여도

핵심 아이디어

AI 에이전트의 허네스는 단순히 모델 성능에만 의존하지 않고, 프롬프트 생성, 상태 관리, 도구 호출, 실행 조정 등 다양한 역할을 수행한다. 그러나 허네스는 복잡한 구조로 인해 수정 요청을 코드 위치에 매핑하는 것이 어렵다. 이 문제를 해결하기 위해, **Harness Handbook**는 정적 프로그램 분석과 LLM을 활용해 행동 중심의 코드 링크를 자동 생성한다. 이는 기존의 파일/함수 중심 접근과 달리, **행위 → 코드**의 직접 맵핑을 가능하게 한다. 또한, **BGPD**는 수정 요청을 고수준 행동에서 세부 코드로 단계적으로 이동하며, 수정 대상 위치를 검증한다. 이는 특히 **분산된 구현, 드문 경로, 모듈 간 상호작용**에서 효과적이다.

기술적 접근법

주요 결과

의의 및 한계

실용적 활용