Skip to main content
QUICK REVIEW

[Paper Review] Word2Bits - Quantized Word Vectors

Maximilian Lam|arXiv (Cornell University)|Mar 15, 2018
Topic ModelingComputer Science27 references24 citations
TL;DR

This paper proposes Word2Bits, a method to train high-quality word vectors with only 1–2 bits per parameter by integrating a quantization function directly into the Word2Vec loss. The approach reduces memory usage by 8–16× compared to 32-bit vectors and surprisingly outperforms full-precision vectors on word similarity and question-answering tasks, while also acting as a regularizer that mitigates overfitting.

ABSTRACT

Word vectors require significant amounts of memory and storage, posing issues to resource limited devices like mobile phones and GPUs. We show that high quality quantized word vectors using 1-2 bits per parameter can be learned by introducing a quantization function into Word2Vec. We furthermore show that training with the quantization function acts as a regularizer. We train word vectors on English Wikipedia (2017) and evaluate them on standard word similarity and analogy tasks and on question answering (SQuAD). Our quantized word vectors not only take 8-16x less space than full precision (32 bit) word vectors but also outperform them on word similarity tasks and question answering.

Motivation & Objective

  • To develop a method for learning compact, high-quality word vectors that require significantly less memory and storage than standard 32-bit word vectors.
  • To address the limitations of post-training compression techniques, which add computational overhead and may degrade performance.
  • To investigate whether training with quantization directly in the loss function can yield better generalization and improved performance on intrinsic and extrinsic NLP tasks.
  • To evaluate whether quantized training acts as a regularizer, reducing overfitting in Word2Vec, especially on smaller datasets.

Proposed method

  • Introduces a differentiable quantization function into the Word2Vec loss, enabling end-to-end training of low-bit word vectors (1–2 bits per parameter).
  • Uses a virtual quantization approach—training with full-precision gradients but constrained parameter values—rather than physical quantization with low-precision arithmetic.
  • Applies the sign function (for 1-bit) or a 4-level quantization function (for 2-bit) as a differentiable proxy in the loss, allowing backpropagation through discrete values.
  • Employs Continuous Bag of Words (CBOW) with negative sampling as the base architecture, with the quantization function embedded in the vector update process.
  • Trains on large-scale text (English Wikipedia 2017) and evaluates on standard word similarity, analogy, and SQuAD question-answering benchmarks.
  • Uses standard hyperparameters (window size, negative sampling, subsampling, min count) with linearly decayed learning rate and varying epochs and dimensions.

Experimental results

Research questions

  • RQ1Can high-quality word vectors be learned with only 1–2 bits per parameter using end-to-end training?
  • RQ2Does training with a quantization function in the loss improve performance on intrinsic and extrinsic NLP tasks compared to full-precision training?
  • RQ3Does the quantization process act as a regularizer, reducing overfitting in Word2Vec, especially on smaller datasets?
  • RQ4Do quantized word vectors generalize better to downstream tasks like question answering despite lower bit precision?
  • RQ5Is there a trade-off between performance on word analogy tasks and word similarity tasks depending on bit depth?

Key findings

  • Quantized word vectors using 1 bit per parameter require only 1/16th the memory of 32-bit vectors and outperform full-precision vectors on word similarity tasks (e.g., 76.84 vs. 76.64 on text8).
  • On the SQuAD question-answering benchmark, 1-bit and 2-bit word vectors achieve higher performance than 32-bit vectors, indicating better generalization to extrinsic tasks.
  • Full-precision Word2Vec shows signs of overfitting with increased training epochs and higher vector dimensions on a 100MB Wikipedia subset, while quantized training remains stable.
  • The 1-bit and 2-bit vectors achieve 76.84 and 77.04 on the Google analogy task, respectively, which is slightly worse than the 32-bit baseline (77.12), indicating a trade-off for analogy tasks.
  • The parameter values of full-precision vectors tend to 'explode' with higher dimensions, a problem not observed in quantized training, suggesting improved optimization stability.
  • The results suggest that performance on intrinsic tasks like word similarity does not predict performance on extrinsic tasks like SQuAD, validating prior findings on task-specific generalization.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.