LMdiff: A Visual Diff Tool to Compare Language Models

Hendrik Strobelt, Benjamin Hoover, Arvind Satyanarayan, Sebastian Gehrmann
11/2/2021
cs.CLcs.HC

Official code: HendrikStrobelt/LMdiff (45 stars, Python, Apache-2.0, last commit 2023-12-28).

Abstract

While different language models are ubiquitous in NLP, it is hard to contrast their outputs and identify which contexts one can handle better than the other. To address this question, we introduce LMdiff, a tool that visually compares probability distributions of two models that differ, e.g., through finetuning, distillation, or simply training with different parameter sizes.

Show full abstract

LMdiff allows the generation of hypotheses about model behavior by investigating text instances token by token and further assists in choosing these interesting text instances by identifying the most interesting phrases from large corpora. We showcase the applicability of LMdiff for hypothesis generation across multiple case studies. A demo is available at http://lmdiff.net .

View on arXivView PDF

Code Implementations(1)

Apache-2.0

A diff tool for language models

454Python, VueMay 19, 20212 years agoApache-2.0
ainlprocvisualizationxai

Similar Papers

Cite this paper

@article{strobelt2021lmdiff,
  title  = {LMdiff: A Visual Diff Tool to Compare Language Models},
  author = {Hendrik Strobelt and Benjamin Hoover and Arvind Satyanarayan and Sebastian Gehrmann},
  year   = {2021},
  eprint = {2111.01582},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2111.01582}
}

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/2111.01582.svg)](https://codeofpaper.com/paper/2111.01582)

Discussion