A Deep Architecture for Semantic Matching with Multiple Positional Sentence Representations

Shengxian Wan, Yanyan Lan, Jiafeng Guo, Jun Xu, Liang Pang, Xueqi Cheng

Introduction

Semantic matching is a fundamental task in Natural Language Processing (NLP), critical for applications such as question answering, information retrieval, and paraphrase detection. Traditional deep learning approaches typically follow one of two paradigms: representing entire sentences as single fixed-length vectors (e.g., standard LSTMs) or utilizing multi-granularity features (e.g., CNNs with fixed window sizes). However, single-vector representations often suffer from an information bottleneck, losing local nuances, while fixed-window CNNs fail to capture how a word's meaning is influenced by the global sentence context.

This paper introduces the MV-LSTM (Multi-View Long Short-Term Memory) architecture. MV-LSTM addresses these limitations by representing sentences as a collection of contextualized "positional" vectors. By allowing these local views to interact and selecting the most salient signals through $k$-Max pooling, the model achieves superior performance in semantic matching tasks.

The MV-LSTM Architecture

The MV-LSTM model consists of three primary components designed to capture and aggregate contextualized local interactions between two sentences, $S_X$ and $S_Y$.

1. Positional Sentence Representation

Instead of relying solely on the final hidden state of an RNN, MV-LSTM employs a Bidirectional LSTM (Bi-LSTM) to generate a representation for every word position $t$. By concatenating the forward and backward hidden states at each position, the model produces a "positional representation" that encodes the meaning of a word within the context of the entire sentence.

2. Interaction Layer

The model computes interactions between every positional representation in $S_X$ and every positional representation in $S_Y$, forming an interaction matrix or tensor. The authors explored three interaction functions:

  • Cosine Similarity: Measures the angular distance between vectors.
  • Bilinear Form: Uses a learnable weight matrix to capture bilinear interactions.
  • Tensor Layer: A more expressive layer that allows for multiple types of interactions between positional vectors.

3. Aggregation and Pooling

To extract the most relevant matching features from the interaction tensor, the model applies $k$-Max pooling. This operation selects the $k$ strongest interaction signals across the entire matrix, ensuring that the model can aggregate multiple pieces of evidence. These top $k$ values are then fed into a Multi-Layer Perceptron (MLP) to compute the final matching score.

Experimental Evaluation

The MV-LSTM was evaluated on two key tasks: Question Answering (QA) using a dataset from Yahoo! Answers (~60,000 positive pairs) and Sentence Completion (SC) using the Reuters dataset.

Results and Discussion

The experimental results demonstrate that MV-LSTM consistently outperforms both single-representation baselines and multi-granularity CNN models.

As shown in the table above, the MV-LSTM (Tensor version) achieved a P@1 of 0.766 on the QA task, representing an 11.1% relative improvement over the standard LSTM-RNN (0.690). In the Sentence Completion task, it reached a P@1 of 0.691, significantly surpassing the MultiGranCNN baseline (0.595).

Ablation studies further revealed that increasing the value of $k$ in the pooling layer generally improves performance, confirming that semantic matching benefits from aggregating multiple local interaction points rather than relying on a single global match.

Conclusion

The MV-LSTM architecture demonstrates that "contextualized local information" is vital for effective semantic matching. By moving beyond the "last state" bottleneck of traditional LSTMs and providing a flexible framework for sentence interaction, MV-LSTM sets a new standard for capturing the nuanced relationships between text pairs. Future work may involve exploring dynamic pooling strategies or scaling these all-to-all interactions for longer documents.

Summary updated

BibTeX
@inproceedings{wan2016deep,
  author = {Shengxian Wan and Yanyan Lan and Jiafeng Guo and Jun Xu and Liang Pang and Xueqi Cheng},
  title = {{A Deep Architecture for Semantic Matching with Multiple Positional Sentence Representations}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2016},
  doi = {10.1609/aaai.v30i1.10342},
}
Figure