Does Transformer Interpretability Transfer to RNNs?

Gonçalo Paulo, Thomas Marshall, Nora Belrose
4/9/2024
cs.LGcs.AIcs.CL

No official code found. Best implementation: EleutherAI/rnngineering (33 stars, MIT, last commit 2024-05-25). 1 more below.

Abstract

Recent advances in recurrent neural network architectures, such as Mamba and RWKV, have enabled RNNs to match or exceed the performance of equal-size transformers in terms of language modeling perplexity and downstream evaluations, suggesting that future systems may be built on completely new architectures. In this paper, we examine if selected interpretability methods originally designed for transformer language models will transfer to these up-and-coming recurrent architectures. Specifically, we focus on steering model outputs via contrastive activation addition, on eliciting latent predictions via the tuned lens, and eliciting latent knowledge from models fine-tuned to produce false outputs under certain conditions. Our results show that most of these techniques are effective when applied to RNNs, and we show that it is possible to improve some of them by taking advantage of RNNs' compressed state.

View on arXivView PDF

Code Implementations(2)

MIT

Engineering the state of RNN language models (Mamba, RWKV, etc.)

332Python, Jupyter NotebookFeb 9, 20242 years agoMIT
MIT

Replication of the paper, "Does Transformer Interpretability Transfer to RNNs?" by EleutherAI

00Shell, PythonMar 17, 20266 months agoMIT

Similar Papers

Cite this paper

@article{paulo2024does,
  title  = {Does Transformer Interpretability Transfer to RNNs?},
  author = {Gonçalo Paulo and Thomas Marshall and Nora Belrose},
  year   = {2024},
  eprint = {2404.05971},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2404.05971v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2404.05971.svg)](https://codeofpaper.com/paper/2404.05971)

Discussion