Cross-level Requirement Traceability: A Novel Approach Integrating Bag-of-Words and Word Embedding for Enhanced Similarity Functionality
Baher Mohammad, Riad Sonbol, Ghaida Rebdawi
TL;DR
This work tackles cross-level requirements traceability by framing the task as a binary link prediction problem between high-level and low-level requirements and proposing a hybrid approach that combines Bag-of-Words plus TF-IDF with an embedding-informed similarity function. The core contribution is a word-similarity–augmented similarity measure that leverages a word similarity matrix and two hyperparameters to bound the influence of related words, reducing reliance on exact-term matching. Evaluated on three public datasets (MODIS, WARC(NFR), WARC(FRS)), the method achieves notable improvements in $F_2$ on MODIS and WARC(NFR) compared with state-of-the-art baselines, while performance on WARC(FRS) is closer to existing methods. The results demonstrate that incorporating semantic relationships into a traditional IR representation can enhance cross-level traceability, with potential for extending to sentence-level embeddings and broader application in requirements engineering.
Abstract
Requirement traceability is the process of identifying the inter-dependencies between requirements. It poses a significant challenge when conducted manually, especially when dealing with requirements at various levels of abstraction. In this work, we propose a novel approach to automate the task of linking high-level business requirements with more technical system requirements. The proposed approach begins by representing each requirement using a Bag of-Words (BOW) model combined with the Term Frequency-Inverse Document Frequency (TF-IDF) scoring function. Then, we suggested an enhanced cosine similarity that uses recent advances in word embedding representation to correct traditional cosine similarity function limitations. To evaluate the effectiveness of our approach, we conducted experiments on three well-known datasets: COEST, WARC(NFR), and WARC(FRS). The results demonstrate that our approach significantly improves efficiency compared to existing methods. We achieved better results with an increase of approximately 18.4% in one of the datasets, as measured by the F2 score.
