Graph-Based Reasoning over Heterogeneous External Knowledge for Commonsense Question Answering

Shangwen Lv, Daya Guo, Jingjing Xu, Duyu Tang, Nan Duan, Ming Gong, Linjun Shou, Daxin Jiang, Guihong Cao, Songlin Hu

Introduction

Commonsense question answering (QA) remains a significant challenge in natural language processing because answers are rarely explicitly stated in the text. Instead, they rely on background knowledge that humans possess intuitively. For instance, determining that a person might sing while playing a guitar requires understanding the relationship between these two distinct activities. Machines often struggle with this because the necessary facts are either missing from structured databases or buried in unstructured text.

Existing solutions typically utilize either structured knowledge bases like ConceptNet or unstructured text corpora like Wikipedia. Structured knowledge is precise but often suffers from low coverage, while unstructured text provides high coverage but lacks the relational structure necessary for complex reasoning. This paper addresses the problem of heterogeneous reasoning: effectively combining these disparate information sources to improve QA performance.

Methodology

The proposed framework consists of a two-stage pipeline: Knowledge Extraction followed by Graph-Based Reasoning. This approach allows the model to leverage the precision of graphs alongside the breadth of natural language.

The two-stage pipeline for knowledge extraction and graph-based reasoning.

Knowledge Extraction

The system constructs two distinct graphs to capture external knowledge:

  1. Concept-Graph: Paths are extracted from ConceptNet connecting entities in the question to those in the answer choices. These paths are represented as a graph where nodes consist of relational triples (e.g., [people] - [capable of] -> [singing]).
  2. Wiki-Graph: Relevant sentences are retrieved from Wikipedia via ElasticSearch. To impose structure on this unstructured text, the authors employ Semantic Role Labeling (SRL) to extract (subject, predicate, object) triples, forming a second graph that mirrors the relational structure of the Concept-Graph.

Graph-Based Reasoning

The core innovation lies in how these graphs are processed to inform a language model. The reasoning stage utilizes two primary modules:

  • Graph-Based Contextual Representation Learning: Since transformer models like XLNet are sensitive to input order, the authors apply a Topology Sort algorithm to the constructed graphs. This re-orders evidence sentences so that semantically related pieces are physically adjacent in the input string, enhancing the model's ability to capture connections.
  • Graph-Based Inference Module: The combined evidence is treated as a single graph. A Graph Convolutional Network (GCN) facilitates information passing between neighboring nodes (evidence pieces). Subsequently, a Graph Attention mechanism identifies the most relevant evidence for the specific question.
Detailed architecture of the Graph-Based Reasoning module, including GCN and Graph Attention components.

Evaluation and Results

The model was evaluated on the CommonsenseQA benchmark, which contains over 12,000 questions designed to test external knowledge rather than simple pattern matching. In this dataset, answer choices often share the same relationship with the question concept, forcing the model to use external commonsense knowledge to differentiate them.

The framework achieved a state-of-the-art 75.3% accuracy on the CommonsenseQA blind test set. Ablation studies highlighted the complementary nature of the knowledge sources:

  • XLNet Baseline: 68.9%
  • With ConceptNet only: 75.3% (dev set)
  • With Wikipedia only: 73.5% (dev set)
  • Combined (Full Model): 79.3% (dev set)

These results confirm that structured and unstructured knowledge provide non-redundant benefits. Furthermore, the topology sort algorithm alone contributed a nearly 2% boost in accuracy, demonstrating the value of graph-informed input organization for large-scale language models.

Conclusion

This research demonstrates that bridging the gap between structured knowledge graphs and unstructured text through graph-based reasoning significantly enhances commonsense QA. By transforming text into relational triples and using graph-aware architectures, models can better navigate the complex web of human background knowledge. While the model shows strong performance, future work will address niche knowledge gaps and fine-grained ambiguity by integrating even more diverse knowledge sources, such as visual or procedural information.

Summary updated

BibTeX
@inproceedings{lv2020graph,
  author = {Shangwen Lv and Daya Guo and Jingjing Xu and Duyu Tang and Nan Duan and Ming Gong and Linjun Shou and Daxin Jiang and Guihong Cao and Songlin Hu},
  title = {{Graph-Based Reasoning over Heterogeneous External Knowledge for Commonsense Question Answering}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2020},
  doi = {10.1609/aaai.v34i05.6364},
}
Figure