Improving Neural Question Generation Using Answer Separation

Yanghoon Kim, Hwanhee Lee, Joongbo Shin, Kyomin Jung

Abstract

Neural Question Generation (NQG) is a critical task for educational technology and conversational AI, aiming to produce relevant questions from a given passage and target answer. However, standard sequence-to-sequence models often suffer from the "copying problem," where the target answer is inadvertently included in the generated question, rendering it trivial or improper. We present an "answer-separated" architecture that physically masks the answer in the source passage and processes it through a dedicated "keyword-net" module. This approach prevents answer leakage and encourages the model to learn deeper semantic relationships. Our model achieves state-of-the-art performance on the SQuAD dataset, significantly improving question quality and interrogative precision.

The Copying Problem in NQG

Existing NQG models typically rely on sequence-to-sequence (seq2seq) architectures. While effective, these models are often incentivized to copy words directly from the source passage to maintain context. A common failure mode occurs when the model copies the target answer itself into the question. For example, given the passage "John Francis O'Hara was elected president of Notre Dame in 1934" and the answer "John Francis O'Hara," a flawed model might ask, "Who was elected John Francis?" instead of the desired "Who was elected president of Notre Dame in 1934?"

Figure 1: Illustration of the improper question problem and the proposed masked passage solution.

Proposed Methodology: Answer-Separated Seq2Seq

To address these issues, we propose the ASs2s (Answer-Separated seq2seq) architecture. The core innovation is the physical separation of the answer from the passage context during the encoding phase.

1. Answer Masking and Dual Encoders

Instead of providing the model with the full passage and a pointer to the answer, we replace the target answer in the passage with a special mask token <a>. This prevents the decoder from directly copying answer words. The model employs two separate encoders: one for the masked passage and another for the isolated target answer.

2. Keyword-net

The isolated answer is processed by Keyword-net, an attention-based module designed to identify the most semantically significant "keywords" within the answer. For instance, if the answer is "the founder of Apple," Keyword-net helps the model focus on "founder" to determine the appropriate question type (e.g., "Who").

Figure 6: The complete ASs2s architecture, featuring the Answer-Separated Passage Encoder, Answer Encoder with Keyword-net, and the Answer-Separated Decoder.

3. Retrieval-Style Word Generator

To better handle rare words and capture underlying semantics, the architecture utilizes a retrieval-based word generator that queries word embeddings rather than relying on a standard softmax layer.

Key Results and Insights

The ASs2s model was evaluated on the Stanford Question Answering Dataset (SQuAD). It outperformed previous state-of-the-art models across several key metrics:

  • Accuracy: The model achieved a BLEU-4 score of 16.20 on Split-1, a notable improvement over the previous benchmark of 13.98.
  • Reduced Answer Leakage: The rate of "complete inclusion" (where the full answer appears in the question) plummeted from 2.9% to 0.6%.
  • Interrogative Precision: The model demonstrated a superior ability to predict the correct question type. For "Who" questions, recall improved from 36.7% to 67.8%.

A significant finding is that the surrounding text provides sufficient "contextual clues" to infer the correct interrogative word even when the answer is masked. For example, the pattern <a> was elected president strongly implies a "Who" question.

Conclusion and Future Work

By enforcing physical separation between the answer and the passage, the ASs2s model generates more diverse and logical questions while effectively solving the copying problem. While the model performs exceptionally well on common question types (Who, What, Where), future research will focus on improving performance for "Why" and "Yes/No" questions, which are currently limited by their sparse representation in training data.

Summary updated

BibTeX
@inproceedings{kim2019improving,
  author = {Yanghoon Kim and Hwanhee Lee and Joongbo Shin and Kyomin Jung},
  title = {{Improving Neural Question Generation Using Answer Separation}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2019},
  doi = {10.1609/aaai.v33i01.33016602},
}
Figure