Graph-Based Bug Localization Using NLP Semantic Similarity

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Software bug localization in large codebases is a costly and time-consuming process, especially when trying to identify bug-prone areas, as existing methods lack efficiency in linking new bug tickets to relevant source code files and historical data.

Innovation Solution

A graph-based method that constructs a bug localization graph using natural language processing to evaluate semantic similarity between new and historical bug tickets, adding links between similar tickets, and developing a mathematical expression to determine closeness relationships between source code files and new bug tickets.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If software testing is conducted on all areas of a large program, then bug detection coverage is improved, but testing cost and time consumption increase significantly

Engineering Contradiction:
Improvebug detection coverageVSAvoidtesting time consumption
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent extracts only the bug-prone areas from the entire codebase by analyzing historical bug tickets and constructing a bug localization graph. Instead of testing all areas, the system identifies and isolates specific source code files that are most likely to contain bugs based on their relationship with historical bug reports, thereby reducing testing scope while maintaining effective bug detection coverage

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent performs preliminary analysis by constructing a bug localization graph using historical bug tickets before actual testing begins. The system pre-identifies bug-prone areas by evaluating semantic similarity between bug tickets and establishing relationships between source code files and bug reports in advance, so that when testing occurs, only the pre-identified problematic areas need to be examined

Inventive Principle:
Principle #10Preliminary action

2Productivity

If bug-prone areas are selected for testing based on historical data, then testing efficiency is improved, but accuracy in identifying relevant source code files deteriorates due to lack of semantic understanding

Engineering Contradiction:
Improvetesting efficiencyVSAvoidaccuracy in identifying relevant source code files
Core Design Contradiction:
ProductivityVSMeasurement precision

Solution Approach 1:

The patent replaces traditional mechanical keyword-matching methods with natural language processing techniques. The system uses NLP to evaluate semantic similarity between bug tickets, understanding the actual meaning and context of bug reports rather than simply matching keywords. This substitution enables accurate identification of relevant source code files while maintaining high testing efficiency

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

Solution Approach 2:

The patent changes the parameter of bug ticket analysis from simple keyword presence to semantic similarity evaluation. By transforming the analysis parameter from textual pattern matching to semantic understanding through NLP, the system achieves both high efficiency in processing multiple bug tickets and high accuracy in identifying the actual bug-prone source code files

Inventive Principle:
Principle #35Parameter changes

3Ease of manufacture

If traditional bug localization methods are used without graph-based analysis, then implementation simplicity is maintained, but the ability to capture relationships between bug tickets and source code files deteriorates

Engineering Contradiction:
Improveimplementation simplicityVSAvoidrelationship information between bug tickets and source code
Core Design Contradiction:
Ease of manufactureVSLoss of information

Solution Approach 1:

The patent creates a multi-functional bug localization system where the graph structure serves multiple purposes: it captures relationships between bug tickets and source code files, enables semantic similarity evaluation, supports historical data analysis, and facilitates bug-prone area identification. This universal graph-based approach consolidates multiple functions into a single framework, making the system comprehensive while remaining implementable through systematic graph construction and analysis

Inventive Principle:
Principle #6Universality (Multi-functionality)

Data Source

PatentUS11645192B2Graph-based method for inductive bug localization
Publication Date: 2023.05.09 NEC CORP
  • US11645192B2 patent drawing
  • US11645192B2 patent drawing
  • US11645192B2 patent drawing

AI summary

A computer-implemented method executed by at least one processor for software bug localization is presented. The method includes constructing a bug localization graph to capture relationships between bug tickets and relevant source code files from historical change-sets and an underlying source code repository, leveraging natural processing language tools to evaluate semantic similarity between a new bug ticket and a historical ticket, in response to the evaluated semantic similarity, for the new bug ticket, adding links between the new bug ticket a set of similar historical tickets, incorporating the new bug ticket in the bug localization graph, and developing a mathematical graph expression to determine a closeness relationship between the relevant source code files and the new bug ticket.