Connecting the Dots: A Knowledgeable Path Generator for Commonsense Question Answering

Peifeng Wang, Nanyun Peng, Pedro A. Szekely, Xiang Ren

Abstract

Commonsense Question Answering (QA) remains a significant challenge in natural language processing because it requires reasoning over implicit background knowledge. While large-scale pre-trained language models (LMs) have shown impressive performance, they often rely on statistical shortcuts rather than explicit reasoning. Conversely, static knowledge graphs (KGs) provide structured facts but suffer from inherent sparsity. This paper introduces a Knowledgeable Path Generator (PG) that bridges these two paradigms. By fine-tuning a GPT-2 model on multi-hop paths sampled from ConceptNet, we create a "neural knowledge graph" capable of dynamically generating relational paths between entities. Our framework integrates these generated paths with a context encoder to perform informed reasoning. Experimental results on the CommonsenseQA and OpenBookQA benchmarks demonstrate that our approach significantly outperforms static KG baselines, particularly in low-resource settings. Furthermore, the generated paths enhance model interpretability by providing human-readable evidence for the system's predictions.

Introduction: The Challenge of Commonsense

Answering commonsense questions often involves "reading between the lines." For instance, to identify where fungus grows, a system must link "fungus" to "moist places" and "caves," and recognize a "cave" as a "geological feature."

Figure 1: Example of a knowledge path connecting entities in a commonsense question to a correct answer choice.

Current solutions typically rely on either large-scale LMs like RoBERTa, which may exploit statistical shortcuts, or static KGs like ConceptNet, which often lack specific "missing links" (e.g., cave IsA geological_feature). The proposed Knowledgeable Path Generator (PG) bridges this gap by generating these missing links on the fly, effectively smoothing over the sparsity of human-curated graphs.

Methodology

The core of the system is the Knowledgeable Path Generator (PG), which transforms a static KG into a generative model.

  1. Path Sampling & Fine-tuning: Millions of multi-hop paths are sampled from ConceptNet via random walks. A GPT-2 model is then fine-tuned on these paths, effectively internalizing structured relational knowledge. This allows the model to rely on its latent knowledge acquired during massive-scale pre-training to "hallucinate" valid relationships where the physical database is incomplete.
  2. Dynamic Path Generation: At inference, given a question entity and a candidate answer entity, the PG generates a path connecting them.
  3. Reasoning Framework:
    • Context Encoder: A standard LM (like RoBERTa) encodes the textual QA pair.
  4. Knowledge Encoder: Processes generated paths through a Relational Network (RN) with an attention mechanism that prioritizes contextually relevant paths.
  5. Fusion: Context and knowledge embeddings are combined to predict the final answer.

Experimental Results

The model was evaluated on CommonsenseQA and OpenBookQA. The full model (PG-Full) consistently outperformed baselines that used only static KGs, achieving 78.2% on the CommonsenseQA leaderboard when using an Albert-xxlarge ensemble.

Figure 4: Accuracy comparison across different training set proportions for CommonsenseQA (left) and OpenBookQA (right), highlighting the model's strength in low-resource settings.

Key Findings

  • Low-Resource Efficiency: As shown in the performance curves, the PG provides the most significant boost when training data is scarce (e.g., at 20% of the training set). This suggests that structured paths provide a powerful inductive bias that helps the model learn faster.
  • Neural KG Extrapolation: Over 75% of generated paths contained at least one triplet not present in the original ConceptNet, proving the model's ability to successfully extrapolate beyond its training data.
  • Interpretability: Unlike "black box" LMs, this system provides human-readable "receipts" for its logic. Human evaluators rated the generated paths as valid 89.2% of the time and relevant 87.5% of the time.

Conclusion and Future Work

By treating GPT-2 as a "neural knowledge graph," this work successfully mitigates the sparsity of human-curated databases. While the system shows strong performance, future research will focus on improving entity linking for polysemous words, optimizing fusion strategies between structured and unstructured data, and reducing the computational overhead of path generation during inference.

Summary updated

BibTeX
@inproceedings{wang2020connecting,
  author = {Peifeng Wang and Nanyun Peng and Pedro A. Szekely and Xiang Ren},
  title = {{Connecting the Dots: A Knowledgeable Path Generator for Commonsense Question Answering}},
  booktitle = {Conference on Empirical Methods in Natural Language Processing},
  year = {2020},
  doi = {10.18653/v1/2020.findings-emnlp.369},
}
Figure