# Representation Engineering: A Top-Down Approach to AI Transparency

RepE: 모델 표현을 읽고 고쳐 보는 하향식 해석

Andy Zou, Long Phan, Sarah Chen, James Campbell, Phillip Guo, Richard Ren 외 15명 · arXiv · 2023년 10월 2일

- **연구 문제** 뉴런과 회로 단위의 기계적 해석은 정직성이나 권력 추구 같은 높은 수준의 인지 현상을 다루기 어렵습니다.
- **연구 방법** RepE는 모델 표현에서 개념에 대응하는 방향을 찾아 읽고, 그 방향을 표현에 더하거나 빼서 모델의 행동을 조절합니다.
- **주요 결과** TruthfulQA MC1에서 LLaMA-2-7B-Chat의 정확도가 제어 없이 31.0이었는데, 대조 벡터를 적용하자 47.9로 올랐습니다.

## 대규모 언어모델의 내부를 읽는 문제

대규모 언어모델은 여러 분야에 빠르게 배치되고 있지만, 모델이 내부에서 어떻게 판단을 만드는지는 여전히 잘 알려져 있지 않습니다. 기존 해석 연구의 한 흐름인 기계적 해석(mechanistic interpretability)은 뉴런과 회로를 단위로 삼아 모델을 이해하려 합니다. 이 방식은 간단한 메커니즘을 설명하는 데는 성과가 있었지만, 정직성이나 권력 추구처럼 높은 수준의 인지 현상을 다루기에는 어려움이 있다고 저자들은 봅니다. 이 논문은 뉴런 대신 표현(representation)을 분석의 중심에 두는 하향식 접근을 제안하며, 그 접근을 표현 공학(Representation Engineering, RepE)이라 부릅니다.

## 표현 읽기와 LAT 절차

표현 읽기는 개념이나 기능에 대응하는 방향을 모델 표현에서 찾아내는 단계입니다. 기준선으로 쓰인 선형 인공 단층촬영(Linear Artificial Tomography, LAT)은 세 단계로 이루어집니다. 첫째, 개념이나 기능을 끌어내는 자극과 과제 템플릿을 설계합니다. 둘째, 토큰 위치에서 신경 활동, 즉 표현 벡터를 모읍니다. 디코더 모델에서는 기본적으로 마지막 토큰의 표현을 씁니다. 셋째, 자극 쌍의 표현 차이 벡터에 주성분 분석(PCA)을 적용하고 첫 주성분을 읽기 벡터로 정합니다. 예측은 이 벡터와 표현의 내적으로 계산합니다. 이 과정에서 레이블은 기본적으로 쓰지 않으며, 레이블은 방향의 부호를 맞추거나 층과 방향을 고르는 데만 사용됩니다.

## 표현 제어의 연산

읽기 벡터를 찾은 뒤에는 이를 이용해 모델의 표현을 바꿀 수 있습니다. 선형 결합은 표현에 벡터를 더하거나 빼서 자극 또는 억제 효과를 만듭니다. 조건부 연산은 표현과 벡터의 내적 부호에 따라 활성 방향을 증폭하며, R′ = R + sign(RᵀV)v 형태로 정의됩니다. 투영은 표현에서 벡터 방향 성분을 제거하며 R′ = R − RᵀV/∥v∥² v로 정의됩니다. 대조 벡터(Contrast Vector)는 같은 입력을 대조적 프롬프트 두 개로 실행해 얻은 두 표현의 차이이며, 입력마다 달라지는 자극 의존적 제어 벡터입니다. LoRRA는 이 대조 벡터를 목표로 저랭크 어댑터를 미세조정하는 기준선입니다.

## 정직성과 TruthfulQA 결과

정직성 실험은 모델 내부에 일관된 진실성 개념이 있는지를 먼저 확인합니다. LAT로 추출한 진실성 방향은 여러 QA 벤치마크에서 few-shot 프롬프트보다 높은 정확도를 보였습니다. TruthfulQA의 MC1 과제에서 표준 평가는 평균 32.3, 휴리스틱 방법은 47.2, 자극 세 종류를 쓴 LAT는 60.7을 기록했습니다. 이 표의 LAT 값은 자극 집합을 바꾼 평균이며, 같은 표에서 자극 종류에 따라 값이 달라집니다. 이어 제어 실험에서 LLaMA-2-7B-Chat은 제어가 없을 때 31.0이었고, 대조 벡터 적용 시 47.9, LoRRA 적용 시 42.3으로 올랐습니다. 저자들은 큰 모델에서 표준 평가가 낮게 나오는 원인 일부가 모델이 내부 진실성 개념과 다르게 답하는 정직성 문제에 있다고 해석합니다.

## 상관에서 인과로 넘어가는 검증

읽기 벡터가 개념과 상관된다는 사실만으로는 인과 효과를 말할 수 없습니다. 논문은 상관, 조작, 종료, 회복의 네 가지 실험을 구분합니다. 정직성 예시에서는 정직성 방향을 더하면 모델이 정직하게 답하도록 제어되고, 방향을 빼면 정직하던 모델이 거짓을 말하도록 유도되었습니다. 다만 이 실험은 모델이 특정 감정을 실제로 느끼는지를 증명하지 않고, 감정 표현이 행동에 영향을 준다는 관찰로 읽어야 합니다.

## 적용 범위와 한계

논문은 정직성 이외에도 효용, 권력 추구, 감정, 유해성, 공정성, 지식 편집, 기억화를 같은 틀에서 다룹니다. 그러나 각 영역의 실험은 모델, 데이터, 제어 방식이 서로 다르므로 하나의 결과로 묶어 읽기 어렵습니다. 특히 LAT는 상관관계를 보여 주는 기법이며, 인과 결론에는 조작과 종료, 회복 실험이 함께 필요하다고 저자들은 밝힙니다. 이 논문의 주요 제어 결과는 특정 LLaMA-2-Chat 계열과 해당 벤치마크에 근거하므로, 다른 모델 계열이나 실제 배치 환경으로 바로 일반화하기는 어렵습니다.

## 논문 정보

- **저자**: Andy Zou, Long Phan, Sarah Chen, James Campbell, Phillip Guo, Richard Ren, Alexander Pan, Xuwang Yin, Mantas Mazeika, Ann-Kathrin Dombrowski, Shashwat Goel, Nathaniel Li, Michael J. Byun, Zifan Wang, Alex Mallen, Steven Basart, Sanmi Koyejo, Dawn Song, Matt Fredrikson, J. Zico Kolter, Dan Hendrycks
- **학회·저널**: arXiv · 프리프린트
- **최초 공개일**: 2023년 10월 2일
- **등록일**: 2026년 11월 12일
- **수정일**: 2025년 3월 3일
- **버전**: v4
- **arXiv**: 2310.01405
- **분류**: cs.LG · cs.AI · cs.CL · cs.CV · cs.CY
- **원문 이용 조건**: [arXiv non-exclusive 1.0](https://arxiv.org/licenses/nonexclusive-distrib/1.0/)
- **제공 범위**: 논문 정보, 해설

[논문 원문 ↗](https://arxiv.org/abs/2310.01405v4) · [원문 PDF ↗](https://arxiv.org/pdf/2310.01405v4)

AI 해설은 논문 원문과 별개의 설명이며 오류가 있을 수 있습니다. 원문과 그림은 각 출처의 이용 조건과 따로 표시된 권리를 따릅니다.

## 원문 인용

Andy Zou, Long Phan, Sarah Chen, James Campbell, Phillip Guo, Richard Ren, Alexander Pan, Xuwang Yin, Mantas Mazeika, Ann-Kathrin Dombrowski, Shashwat Goel, Nathaniel Li, Michael J. Byun, Zifan Wang, Alex Mallen, Steven Basart, Sanmi Koyejo, Dawn Song, Matt Fredrikson, J. Zico Kolter et al. (2023). Representation Engineering: A Top-Down Approach to AI Transparency. arXiv:2310.01405v4. https://arxiv.org/abs/2310.01405v4

**BibTeX**

```
@misc{zou2023representation,
  title = {{Representation Engineering: A Top-Down Approach to AI Transparency}},
  author = {Andy Zou and Long Phan and Sarah Chen and James Campbell and Phillip Guo and Richard Ren and Alexander Pan and Xuwang Yin and Mantas Mazeika and Ann-Kathrin Dombrowski and Shashwat Goel and Nathaniel Li and Michael J. Byun and Zifan Wang and Alex Mallen and Steven Basart and Sanmi Koyejo and Dawn Song and Matt Fredrikson and J. Zico Kolter and Dan Hendrycks},
  year = {2023},
  eprint = {2310.01405},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2310.01405v4}
}
```

## 이 논문의 용어

- [Principal Component Analysis](https://refivu.com/terms/5e8334d817e7-principal-component-analysis)
- [TruthfulQA](https://refivu.com/terms/31ff8523e160-truthfulqa)
- [Projection](https://refivu.com/terms/b5c72722aff2-projection)
- [Mechanistic Interpretability](https://refivu.com/terms/3280cfadb9bc-mechanistic-interpretability)
- [representation engineering](https://refivu.com/terms/048b29f058ef-representation-engineering)
- [Linear Artificial Tomography](https://refivu.com/terms/0c9d7c217765-linear-artificial-tomography)
- [truthfulness](https://refivu.com/terms/f80eb4fc2e2a-truthfulness)

## 다른 논문 해설

- [Text Embeddings by Weakly-Supervised Contrastive Pre-training](https://refivu.com/papers/d1351af6-6e66-4a03-9f02-44cc61903f8b-text-embeddings-by-weakly-supervised-contrastive-pre.md)
- [Representation Learning on Graphs: Methods and Applications](https://refivu.com/papers/3ca2c648-5d7e-46c2-be1e-357cc66ab085-representation-learning-on-graphs-methods-and-applications.md)
- [Deep Learning Face Representation by Joint Identification-Verification](https://refivu.com/papers/1824448e-2edd-4d03-a6b5-1fbd92b71da3-deep-learning-face-representation-by-joint-identification.md)
- [Curiosity-driven Exploration by Self-supervised Prediction](https://refivu.com/papers/93936438-d2c7-4a12-b814-3073185546ca-curiosity-driven-exploration-by-self-supervised-prediction.md)
- [ConvNeXt V2: Co-designing and Scaling ConvNets with Masked Autoencoders](https://refivu.com/papers/d6599a02-0aa8-4eec-a1c3-2bdc45716f23-convnext-v2-co-designing-and-scaling-convnets-with.md)
- [Person Re-identification by Local Maximal Occurrence Representation and Metric Learning](https://refivu.com/papers/ce1c4e84-0a27-40a3-8d69-3dc923b2cf52-person-re-identification-by-local-maximal-occurrence.md)
- [ZOO: Zeroth Order Optimization based Black-box Attacks to Deep Neural Networks without Training Substitute Models](https://refivu.com/papers/5b5ce3e2-3dd3-4814-b5fc-ab7233717cda-zoo-zeroth-order-optimization-based-black-box-attacks.md)
- [3D Semantic Segmentation with Submanifold Sparse Convolutional Networks](https://refivu.com/papers/03d04653-f014-489b-8502-00fe22ca0646-3d-semantic-segmentation-with-submanifold-sparse.md)
- [ChatGLM: A Family of Large Language Models from GLM-130B to GLM-4 All Tools](https://refivu.com/papers/9637d904-3e6d-4047-bd71-6ae5b68f90d8-chatglm-a-family-of-large-language-models-from.md)
- [Text Classification Algorithms: A Survey](https://refivu.com/papers/5134d426-2cd3-4691-aeff-cf1fc4cb8d39-text-classification-algorithms-a-survey.md)
- [Sigmoid Loss for Language Image Pre-Training](https://refivu.com/papers/c9aaadc4-ef69-4682-a730-51fb42cbb35f-sigmoid-loss-for-language-image-pre-training.md)
- [Reading Wikipedia to Answer Open-Domain Questions](https://refivu.com/papers/0abc2d22-75a1-4c4d-91be-624a590aabec-reading-wikipedia-to-answer-open-domain-questions.md)

---

AI 해설에는 오류가 있을 수 있습니다. [Refivu](https://refivu.com/papers/f6b6fa1e-01cf-4bad-a9dc-8b83f1107927-representation-engineering-a-top-down-approach-to-ai)
