20260601
This commit is contained in:
49
concepts/harness-engineering.md
Normal file
49
concepts/harness-engineering.md
Normal file
@@ -0,0 +1,49 @@
|
||||
---
|
||||
title: "Harness Engineering"
|
||||
created: 2026-05-29
|
||||
updated: 2026-05-29
|
||||
type: concept
|
||||
tags: ["agent", "engineering", "constraint", "LLM"]
|
||||
sources: ["https://mp.weixin.qq.com/s/PglkqhlSoI7LEOb3AOHl8g"]
|
||||
---
|
||||
|
||||
# Harness Engineering
|
||||
|
||||
**Harness Engineering** 是随着 [[autoharness|AutoHarness]] 等工作而兴起的一门新兴工程实践学科:系统性地为 LLM Agent 构建约束层(harness),使其在结构化环境中产生可靠、合法的行为。
|
||||
|
||||
## 学科定位
|
||||
|
||||
传统 AI 工程关注 Model 的训练与部署。Harness Engineering 关注的则是 Model **外部**的结构:
|
||||
- 合法性验证回路
|
||||
- 反馈收集与聚合
|
||||
- 代码自合成与迭代
|
||||
- 约束的搜索与优化
|
||||
|
||||
## 核心实践
|
||||
|
||||
1. **约束即代码**:Harness 以可执行代码形式表达(可验证、可迭代)
|
||||
2. **搜索驱动合成**:通过 [[thompson-sampling-code-search|Thompson 采样]] 在 harness 空间中搜索
|
||||
3. **Refiner-Critic 环**:LLM 生成改进 → 环境反馈 → 迭代优化
|
||||
4. **层级递进**:从 Verifier(轻约束)→ Filter → Policy(强约束)
|
||||
|
||||
## 与 Model Engineering 的分工
|
||||
|
||||
| 维度 | Model Engineering | Harness Engineering |
|
||||
|------|-------------------|---------------------|
|
||||
| 优化对象 | 神经网络参数 | 可执行代码 |
|
||||
| 反馈来源 | 梯度信号 | 环境交互 |
|
||||
| 可解释性 | 低 | 高(可读代码) |
|
||||
| 部署成本 | 高昂 | 零(纯代码) |
|
||||
|
||||
## 未来方向
|
||||
|
||||
- 可复用 Harness 组件库
|
||||
- 跨游戏的约束知识迁移
|
||||
- 从"代码约束"扩展到"行为准则约束"
|
||||
- 与 [[heuristic-learning|Heuristic Learning]] 融合
|
||||
|
||||
## 相关
|
||||
|
||||
- [[model-harness-relationship]] — Model-Harness 关系
|
||||
- [[autoharness]] — 核心方法
|
||||
- [[compiled-ai-paradigm]] — 编译型 AI
|
||||
Reference in New Issue
Block a user