Reproduce “A Fast and Simple Algorithm for Training Neural Probabilistic Language Models” on OpenResearch

Run Claude Code, Codex or any coding agent as a research agent: literature, hypotheses and experiments on your laptop, cluster or cloud GPUs.

Universal app for Apple silicon and Intel. Requires macOS 11 or later.

About this paper

Andriy Mnih, Yee Whye Teh

The paper presents noise-contrastive estimation (NCE) for training neural language models without normalizing over the full vocabulary at every update. It contrasts observed words with sampled unigram noise. On a specified Penn Treebank setup, NCE reached test perplexity 163.1 in 1.5 hours versus maximum likelihood’s 163.5 in 21 hours; this 14× elapsed-time result has implementation and convergence qualifications.

Key insights

  • NCE's re-framing of density estimation as a binary classification problem inherently avoids the need for explicit, full-vocabulary normalization, addressing the core computational bottleneck.
  • The use of a bounded weighting scheme in NCE provides greater training stability compared to importance sampling, which was prone to divergence due to high-variance importance weights.
  • Empirical unigram distributions for noise samples consistently performed better than uniform noise, and a simplified model with a fixed normalization constant (c_h=1) maintained quality while reducing complexity.

Summary by alphaXiv.

Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.