· Xiaojing Yang · NLP and LLMs · 3 min read
ENLLM Evaluation and Failure Modes
LLM 评估风险图:幻觉、prompt 敏感性、偏见、污染和脆弱 benchmark。
核心观点
LLM evaluation 要测试行为,而不只是 benchmark 分数。
1. 为什么 LLM evaluation 不一样
LLMs 是通用系统。它们能听指令、生成流畅文本、给出像检索过的答案,也能在错误时解释得很自信。所以评估必须检查真实条件下的行为。
用户需要什么
指令和上下文
可能有随机性
指标、人类或 model judge
模式和严重性
2. 常见失败模式
| 失败模式 | 检查什么 |
|---|---|
| Hallucination | unsupported claims |
| Prompt sensitivity | 换措辞后是否不稳定 |
| Bias | 系统性差异 |
| Contamination | benchmark 是否出现在训练中 |
| Verbosity trap | 流畅但低价值 |
| Long-context failure | 忽略或误用证据 |
3. 评估实践
# Pseudocode
for prompt in prompt_suite:
output = model.generate(prompt)
score = judge(output, reference_or_rubric)
log_failure_mode(output, score)4. 我的研究连接
这连接到 RAG、长文档、多语评估和 responsible AI。对 multilingual LLMs 来说,模型可能英语表现很强,却在低资源语言或领域技术文档上失败。
Benchmark 视角
分数有多高?
研究视角
哪些行为可靠,哪些会失败,在什么条件下失败?
总结
LLM evaluation 不是排行榜,而是对模型系统做行为科学。
面试回答模板
如果面试问到这个概念,我通常会这样回答:
- 用一句话定义;
- 解释数据如何流动;
- 指出主要失败模式;
- 连接到 evaluation、multilinguality 或 fine-tuning。
参考资料
- Hugging Face Course
- Hugging Face Transformers documentation
- Hugging Face tokenizer summary
- Hugging Face fine-tuning guide
- Hugging Face PEFT
- The Illustrated Transformer
- Speech and Language Processing, Jurafsky & Martin
- Stanford CS224N readings
- Attention Is All You Need
- COMET: A Neural Framework for MT Evaluation