HyperAIHyperAI

Command Palette

Search for a command to run...

4 months ago

Tying Word Vectors and Word Classifiers: A Loss Framework for Language Modeling

Hakan Inan; Khashayar Khosravi; Richard Socher

Tying Word Vectors and Word Classifiers: A Loss Framework for Language Modeling

Abstract

Recurrent neural networks have been very successful at predicting sequences of words in tasks such as language modeling. However, all such models are based on the conventional classification framework, where the model is trained against one-hot targets, and each word is represented both as an input and as an output in isolation. This causes inefficiencies in learning both in terms of utilizing all of the information and in terms of the number of parameters needed to train. We introduce a novel theoretical framework that facilitates better learning in language modeling, and show that our framework leads to tying together the input embedding and the output projection matrices, greatly reducing the number of trainable variables. Our framework leads to state of the art performance on the Penn Treebank with a variety of network models.

Code Repositories

rdspring1/PyTorch_GBW_LM
pytorch
Mentioned in GitHub
InnerPeace-Wu/im2p-tensorflow
tf
Mentioned in GitHub
JianGoForIt/YellowFin_Pytorch
pytorch
Mentioned in GitHub
floydhub/word-language-model
pytorch
Mentioned in GitHub
Ravoxsg/Word-level-language-modeling
pytorch
Mentioned in GitHub

Benchmarks

BenchmarkMethodologyMetrics
language-modelling-on-penn-treebank-wordInan et al. (2016) - Variational RHN
Test perplexity: 66.0
Validation perplexity: 68.1
language-modelling-on-wikitext-2Inan et al. (2016) - Variational LSTM (tied) (h=650)
Test perplexity: 87.7
Validation perplexity: 92.3
language-modelling-on-wikitext-2Inan et al. (2016) - Variational LSTM (tied) (h=650) + augmented loss
Test perplexity: 87.0
Validation perplexity: 91.5

Build AI with AI

From idea to launch — accelerate your AI development with free AI co-coding, out-of-the-box environment and best price of GPUs.

AI Co-coding
Ready-to-use GPUs
Best Pricing
Get Started

Hyper Newsletters

Subscribe to our latest updates
We will deliver the latest updates of the week to your inbox at nine o'clock every Monday morning
Powered by MailChimp