Supercharge Your Innovation With Domain-Expert AI Agents!

Code reconstruction method based on programming context information

A context and code technology, applied in the field of code refactoring, can solve problems such as lack of research, achieve the effect of improving software quality and avoiding program defects and corruption

Pending Publication Date: 2021-07-30
NANJING UNIV OF AERONAUTICS & ASTRONAUTICS
View PDF4 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

Research on this part is currently relatively scarce, and further, more in-depth research is urgently needed

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Code reconstruction method based on programming context information
  • Code reconstruction method based on programming context information
  • Code reconstruction method based on programming context information

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0045] The present invention will be further described in detail below in conjunction with the accompanying drawings and specific embodiments.

[0046] Programming context data is an important source of information for identifier correction. The existing programming context data where the identifier is located has not been effectively utilized. It mainly includes three categories: programmer information, programming project information, and programming environment information, among which programmers and programming projects are further divided into historical information and field information. The information has the characteristics of diversity, mass, high speed and variability. Aiming at these characteristics, the present invention studies the structure, connotation and feature extraction and classification technology of context information. Among the three types of context information, there are many kinds of context information of programming items, which is the focus of...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a code reconstruction method based on programming context information. A demand document, a design document, a defect report and a code structure of the programming project are analyzed according to the context information of the programming project to form a programming context model; and for a given identifier, a list of sources is reconstructed by programming a context model. The method comprises the following steps: (1) segmenting and serializing code context, annotation, a demand document and a design document to form text vectors; (2) converting the text vector into a numerical vector through a machine learning method, and embedding the numerical vector; (3) clustering a plurality of formed vector spaces by using a clustering method; and (4) inputting an identifier into a programming context model to form a reconstruction alternative sorting list, and recommending the reconstruction alternative sorting list to a developer. According to the method, a new reconstruction identifier is constructed more effectively and individually, the software quality is improved, program defects and corruption are avoided, and developers are helped to carry out program development.

Description

technical field [0001] The invention relates to a code reconstruction method, in particular to a code reconstruction method based on programming context information. Background technique [0002] Refactoring of identifiers is mainly reflected in the following two aspects, one is renaming based on naming conventions, and the other is renaming based on inconsistencies. [0003] Naming Convention-Based Renaming: A naming convention is a set of rules that programmers use to guide them in naming software entities, especially the rules for forming identifiers (both word choice and "syntax" rules). Naming software entities according to a uniform naming convention improves the readability and maintainability of software applications. Naming conventions are context-sensitive. Different programming languages ​​and organizations define their own naming conventions. For example, the Java language recommends naming entities following the camel case convention, while C programmers typi...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F8/72G06F16/335G06F16/35G06N3/04
CPCG06F8/72G06F16/335G06F16/353G06N3/045
Inventor 张静宣骆君鹏梁嘉慧刘思远
Owner NANJING UNIV OF AERONAUTICS & ASTRONAUTICS
Features
  • R&D
  • Intellectual Property
  • Life Sciences
  • Materials
  • Tech Scout
Why Patsnap Eureka
  • Unparalleled Data Quality
  • Higher Quality Content
  • 60% Fewer Hallucinations
Social media
Patsnap Eureka Blog
Learn More