Generating Text from Structured Data with Application to the Biography Domain

Rémi Lebret, David Grangier, Michael AuliarXiv 2016

TL;DR

This paper introduces a neural model for concept-to-text generation that scales to large, diverse domains by generating Wikipedia biography sentences from structured infoboxes. By combining local and global conditioning with a copy mechanism, the model handles a massive 400k-word vocabulary and outperforms traditional statistical baselines by nearly 15 BLEU points.

What Problem Does This Paper Address?

Concept-to-text generation—the task of turning structured data (like a table) into natural language—has historically been confined to small, narrow domains. Previous benchmarks like WEATHERGOV or ROBOCUP featured only a few hundred unique words and tens of thousands of samples.

In contrast, real-world data is messy, massive, and diverse. The authors tackle the "Biography Domain," where a model must look at a Wikipedia infobox (a fact table) and generate a coherent introductory sentence. This presents two major challenges:

  1. Vocabulary Size: Moving from 350 words to over 400,000 words.
  2. Data Sparsity: Traditional count-based models struggle to estimate probabilities for rare events (like specific names or niche occupations) when the number of possible field-word combinations is astronomical.

Methods

The authors propose a Table-Conditioned Neural Language Model (NLM). Instead of relying on rigid rules or grammars, they use a feed-forward neural network that predicts the next word based on the previous context and the input table. Key innovations include:

  • Local Conditioning: The model doesn't just see words; it sees where those words appear in the table. Each word is represented by a triplet: (field type, position from start, position from end). This helps the model learn field-specific regularities (e.g., a number in a "birthdate" field is likely followed by a month).
  • Global Conditioning: To capture the "theme" of a biography, the model looks at the entire table at once. It uses binary indicators to note which fields (e.g., "team," "position" vs. "scientific_career") and words are present, helping it distinguish between an athlete and a scientist before it even starts writing.
  • Copy Actions: To handle rare or out-of-vocabulary (OOV) words (like the surname "Parker-Rhodes"), the model includes a mechanism to copy tokens directly from the input table into the output sentence.
  • Attention Mechanism: The model uses a form of attention to bias the output toward words occurring in specific table fields based on the current generation context.
Figure 4: Visualization of attention scores for Nellie Wong’s Wikipedia infobox. Each row represents the probability distri- bution over (field, position) pairs given the previous words (i.e. the words heading the preceding rows as well as the current row). Darker colors depict higher probabilities.

Datasets

The authors introduce WIKIBIO, a new large-scale dataset for text generation:

  • Source: 728,321 articles from English Wikipedia (Sep 2015) that contain both an infobox and a biography.
  • Scale: An order of magnitude larger than previous resources.
  • Complexity: Features a vocabulary of 400,000 words and an average of 19.7 fields per table.

Key Insights and Ideas

  • Factorization is Key: By parameterizing words and fields as separate embeddings, the model avoids the "product of words and fields" parameter explosion that plagued earlier statistical models.
  • Global Context Matters: The model can infer information not explicitly stated in a single field. For example, by seeing fields like "Mycology" and "Linguistics," the global conditioning helps the model correctly identify the subject as a "scientist" rather than a generic "person."
  • Structural Awareness: The "position from end" feature in local conditioning is a simple but effective way to help the model recognize when a field is finishing, which is often a cue to transition to a new part of the sentence (e.g., moving from a name to a birthdate).

Key Results

The neural approach significantly outperformed the Template Kneser-Ney (KN) baseline across all metrics:

  • BLEU Score: The best neural model achieved 34.7, compared to 19.8 for the Template KN baseline.
  • Efficiency: Despite the complexity, the neural model is faster during inference, taking roughly 200ms per sentence with a beam size of 5, whereas the baseline is significantly slower due to expensive n-gram lookups.
Figure 3: Comparison between our best model (Table NLM) and the baseline (Template KN) for different beam sizes. The x-axis is the average timing (in milliseconds) for generating one sentence. The y-axis is the BLEU score. All results are mea- sured on a subset of 1,000 samples of the validation set.

Qualitatively, the model demonstrated an impressive ability to use the correct tense (past tense for deceased subjects) by checking for the presence of a "death date" field in the table.

Limitations and Future Work

  • Single Sentence Focus: The current work only generates the first sentence of a biography. Expanding this to full-length multi-sentence biographies remains a challenge.
  • Factual Accuracy: The training loss (negative log-likelihood) doesn't explicitly penalize "hallucinations" or factual errors. A model might generate a fluent sentence that incorrectly states a subject's nationality.
  • Simple Encoders: The authors suggest that using more sophisticated encoders (like LSTMs or CNNs) for field values could further improve how the model represents structured data.

Summary updated

BibTeX
@misc{lebret2016generating,
  author = {Rémi Lebret and David Grangier and Michael Auli},
  title = {{Generating Text from Structured Data with Application to the Biography Domain}},
  year = {2016},
  eprint = {1603.07771},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1603.07771},
}
Figure