Text Similarity Based on Semantic Analysis

Junli Wang, Qing Zhou, Guobao Sun2016

Abstract

One of the most important challenges in measuring text similarity is language variability: texts with the same meaning can be realized in several ways. A way to address the language variability is the notion of semantic similarity. This paper extracts the relevance of texts and terms through Singular Value Decomposition (SVD). According to Bayesian Network, we construct term-topic sets and then use Mutual Information (MI) to calculate the semantic similarity between terms. Finally, we use graph structures instead of term vectors to calculate text similarity.

Introduction

The central challenge in Natural Language Processing (NLP) is language variability. Because the same meaning can be expressed using entirely different words, simple "bag-of-words" models—which represent text as a flat vector of word frequencies—often fail to capture deep semantic connections. While techniques like Latent Semantic Analysis (LSA) attempt to solve this using Singular Value Decomposition (SVD), they can be memory-intensive and often produce "rough" results that ignore the internal structural relationships between words.

This paper introduces a hybrid approach to measuring text similarity that moves beyond traditional word vectors by representing documents as complex graph structures. By combining structural graph matching with topic modeling via Bayesian Networks, the authors achieve an average accuracy of 84.73% in text clustering, significantly outperforming standard methods like LSA.

Methodology

The proposed multi-stage pipeline treats text similarity as a structural matching problem rather than a simple vector calculation. The system first extracts nouns and verbs as primary semantic carriers and constructs document graphs (WSM) where edges represent co-occurrences weighted by Mutual Information (MI).

Topic Mining via Bayesian Networks

A critical component of the system is the use of SVD and Bayesian Networks to establish a "correlation relation network" between documents, topics, and words. This allows the system to infer underlying topics even when specific keywords differ, identifying "indirect relevance" between documents.

Bayesian Network structure showing relationships between documents (D), topics (T), and words (W).

Similarity Matching and Fusion

Similarity is calculated through two primary lenses:

  1. Words Similarity Matching (WSM): A greedy algorithm finds the optimal matching between nodes in document graphs.
  2. Word-Couples Similarity Matching (WCSM): Topics are treated as nodes in a bipartite graph, using the Hungarian algorithm to find the maximum weighted matching.

The final similarity score is a weighted sum ($\alpha WSM + \beta WCSM$), balancing structural similarity with semantic topic similarity.

Experimental Results

The study utilized the Fudan University text categorization corpus (1,114 documents across 9 categories). The hybrid approach provided a massive 32% improvement over standard LSA and a 21% improvement over simple graph-based string matching (MCS).

Comparison of within-class and between-class similarity for WSM and MCS across different document categories.

As shown in the figure above, the WSM method demonstrates superior discriminative power compared to Maximum Common Subgraph (MCS). For WSM, the "within-class" similarity is consistently and significantly higher than "between-class" similarity across all categories, which is essential for accurate clustering. In contrast, methods like LSA were found to be unstable, sometimes showing higher similarity between different classes than within the same class.

Method Average Accuracy (AA)
Latent Semantic Analysis (LSA) 52.65%
Maximum Common Subgraph (MCS) 63.13%
WSM (Structural only) 73.39%
WCSM (Semantic only) 78.96%
Proposed Hybrid ($\alpha$WSM + $\beta$WCSM) 84.73%

Conclusion

By using Bayesian Networks and graph structures, the model effectively captures the organizational structure and underlying topics of text. While the results are strong, the authors acknowledge that the computational complexity of the Hungarian algorithm and the heuristic nature of the fusion weights remain areas for future optimization.

Summary updated

BibTeX
@misc{wang2016text,
  author = {Junli Wang and Qing Zhou and Guobao Sun},
  title = {{Text Similarity Based on Semantic Analysis}},
  year = {2016},
  doi = {10.2991/aiie-16.2016.70},
}
Figure