[Paper Review] Adversarial Domain Adaptation for Duplicate Question Detection
This paper proposes adversarial domain adaptation (ADA) for duplicate question detection across different StackExchange forums, using a shared question encoder with a domain discriminator to align feature spaces. It achieves an average 5.6% relative improvement over baselines across domain pairs, with effectiveness strongly correlated to n-gram similarity between domains.
We address the problem of detecting duplicate questions in forums, which is an important step towards automating the process of answering new questions. As finding and annotating such potential duplicates manually is very tedious and costly, automatic methods based on machine learning are a viable alternative. However, many forums do not have annotated data, i.e., questions labeled by experts as duplicates, and thus a promising solution is to use domain adaptation from another forum that has such annotations. Here we focus on adversarial domain adaptation, deriving important findings about when it performs well and what properties of the domains are important in this regard. Our experiments with StackExchange data show an average improvement of 5.6% over the best baseline across multiple pairs of domains.
Motivation & Objective
- Address the challenge of detecting duplicate questions in forums lacking annotated training data.
- Enable transfer learning from labeled forums (e.g., StackOverflow) to unlabeled target forums (e.g., Apple, Android) via domain adaptation.
- Investigate when and why adversarial domain adaptation works effectively for cross-domain duplicate question detection.
- Evaluate the model’s ability to generalize to unseen target domains using a pivot domain during training.
- Identify linguistic and statistical properties of domains that predict adaptation success.
Proposed method
- Employ a shared question encoder to map input questions into dense vector representations from both source and target domains.
- Train the encoder to minimize classification loss on duplicate question labels while simultaneously fooling a domain discriminator to make domain predictions indistinguishable.
- Use a Wasserstein GAN-based adversarial loss to improve training stability and reduce AUC variance compared to standard GANs.
- Implement two similarity functions: a sigmoid-based classifier with cross-entropy loss and a cosine similarity function with pairwise hinge loss.
- Apply adversarial regularization to align the latent representations of source and target domains, reducing domain shift.
- Train the model end-to-end using a combination of classification loss, adversarial loss, and similarity loss.
Experimental results
Research questions
- RQ1How effective is adversarial domain adaptation for duplicate question detection across different StackExchange forums?
- RQ2What properties of source and target domains predict the success of domain adaptation in this task?
- RQ3Can adversarial domain adaptation generalize to unseen target domains not seen during training?
- RQ4How does the performance of adversarial adaptation compare to direct transfer and BM25 baseline methods?
- RQ5To what extent is the effectiveness of domain adaptation correlated with n-gram similarity between domains?
Key findings
- Adversarial domain adaptation achieves an average relative improvement of 5.6% over the best baseline across all source-target domain pairs in the StackExchange family.
- The highest improvement reaches 14% for the AskUbuntu → Android pair, indicating strong performance on similar domains.
- Domain adaptation performance is positively correlated with n-gram similarity: Pearson correlation coefficients of 0.57 (unigrams), 0.80 (bigrams), and 0.94 (trigrams) with adaptation effectiveness.
- Adaptation from Quora to other domains yields almost no improvement over direct transfer, confirming that domain similarity is critical.
- The model generalizes to unseen target domains when using a pivot domain (e.g., AskUbuntu) for adversarial training, outperforming direct transfer on Apple and Android.
- Wasserstein GAN loss provides significantly more stable training, reducing AUC variance by 17x compared to standard classification-based GANs.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.