Character-level Chinese Backpack Language Models

Hao Sun, John Hewitt
10/19/2023
cs.CL

No official code found. Best implementation: SwordElucidator/nanoBackpackLM (25 stars, MIT, last commit 2023-08-13).

Abstract

The Backpack is a Transformer alternative shown to improve interpretability in English language modeling by decomposing predictions into a weighted sum of token sense components. However, Backpacks' reliance on token-defined meaning raises questions as to their potential for languages other than English, a language for which subword tokenization provides a reasonable approximation for lexical items. In this work, we train, evaluate, interpret, and control Backpack language models in character-tokenized Chinese, in which words are often composed of many characters. We find that our (134M parameter) Chinese Backpack language model performs comparably to a (104M parameter) Transformer, and learns rich character-level meanings that log-additively compose to form word meanings. In SimLex-style lexical semantic evaluations, simple averages of Backpack character senses outperform input embeddings from a Transformer. We find that complex multi-character meanings are often formed by using the same per-character sense weights consistently across context. Exploring interpretability-through control, we show that we can localize a source of gender bias in our Backpacks to specific character senses and intervene to reduce the bias.

View on arXivView PDF

Code Implementations(1)

MIT

The simplest repository for training medium-sized BackpackLM for cs224n

257Python, Jupyter NotebookFeb 14, 20233 years agoMIT

Similar Papers

Cite this paper

@article{sun2023characterlevel,
  title  = {Character-level Chinese Backpack Language Models},
  author = {Hao Sun and John Hewitt},
  year   = {2023},
  eprint = {2310.12751},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2310.12751v1}
}

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

Discussion