Files
myWiki/concepts/harnessaudit.md

54 lines
2.1 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: "HarnessAudit"
created: 2026-06-05
updated: 2026-06-05
type: concept
tags: [framework, agent-safety, trajectory-audit, benchmark]
sources: [[liu-auditing-agent-harness-safety]]
---
# HarnessAudit
**HarnessAudit** 是由 Liu et al. (2026) 提出的 **Agent 骨架安全审计框架**,将 Agent 安全评测从输出级转向完整的轨迹级审计。其核心主张是Agent Safety 应该评测 **Harness** 而非 Response。
## 架构:三阶段流水线
```
Setup → Execution → Judge
```
### Phase 1: Setup
- 声明式任务规范实例化可复现的骨架
- 生成确定性种子的 mock services
- 导出 **hidden audit artifacts**完成检查点、策略规则、违规分类Agent 全程不可见
- Agent 仅通过 API 工具交互,从不接触真实用户数据
### Phase 2: Execution
- 标准的 think → act → observe 循环
- **不做在线评分**——仅记录结构化日志:
- 每次工具调用的参数和结果
- 每次资源访问的权限决策
- 每条组件间消息的内容和接收方
- 执行前后的环境快照
### Phase 3: Judge
- 加载隐藏审计 artifacts
- 结合三个证据通道重建执行轨迹
- 按 L1-L3 规范(见 [[agent-harness-safety]])评分
## HarnessAudit-Bench
伴随框架发布的基准测试210 任务 × 8 领域(金融、电商、医疗、法律、软件工程、办公、日常、社交),支持单/多 Agent 配置。
## 核心设计原则
1. **证据独立**:所有评估证据来自 Agent **不可操纵、不可预期的通道**
2. **三层联合**[[boundary-compliance]]、[[execution-fidelity]]、[[system-stability]] 必须同时满足
3. **跨框架归一**:通过统一的 Action Schema 将不同骨架的原生事件格式标准化为 `tool_call` / `communication` 两种审计表面
## 与相关概念的关系
- [[agent-harness-engineering]] 定义了骨架的工程视角HarnessAudit 提供了它的安全审计维度
- [[harness-as-policy]] 将代码视为策略HarnessAudit 验证该策略是否被遵守
- [[trajectory-auditing]] 是 HarnessAudit 的核心方法论