HANTracer: Leveraging Heterogeneous Graph Attention Network for Large-Scale Requirements-Code Traceability Link Recovery

Zhiyuan Zou, Bangchao Wang, Hongyan Wan, Huan Jin, Xiaoxiao Li, Yukun Cao · 2024

In the task of requirements-to-code traceability link recovery, the continues growth of software scale has led to diminishing differences between indices and more complex nonlinear relationships within the data. This results in the performance decline of the most widely used information retrieval methods and machine learning methods when handling this task. Therefore, we propose a requirement traceability method based on heterogeneous graph attention networks, named HANTracer. The model integrates the high-dimensional vectors generated by a pre-trained model as node features to deepen the dif-ferentiation between nodes and enhances node representations with contextual information learned from the graph structure. Additionally, it utilizes the properties of heterogeneous edges to construct various edge features, such as code calling, code inheritance, and text similarity relationships, aiding the model in understanding and utilizing the relationships between different types of data elements. By incorporating average pooling layers and multiple fully connected layers, the HANTracer model is further improved to enhance its ability to extract nonlinear features. Experimental results indicate that HANTracer achieves an average F1 performance higher than the state-of-the-art methods TAROT by 100.30% and DF4RT by 46.27% on seven real-world open source software (OSS) datasets, demonstrating significant performance advantages in large-scale and complex data environments.

Read the paper · More papers on PaperTik