A graph sequence neural architecture for code completion with semantic structure features. Issue 1 (30th December 2021)
- Record Type:
- Journal Article
- Title:
- A graph sequence neural architecture for code completion with semantic structure features. Issue 1 (30th December 2021)
- Main Title:
- A graph sequence neural architecture for code completion with semantic structure features
- Authors:
- Yang, Kang
Yu, Huiqun
Fan, Guisheng
Yang, Xingguang
Huang, Zijie - Abstract:
- Abstract: Code completion plays an important role in intelligent software development for accelerating coding efficiency. Recently, the prediction models based on deep learning have achieved good performance in code completion task. However, the existing models cannot avoid three drawbacks: (i) In the existing models, the code representation loses the information (parent–child information between nodes) and lacks many effective features (orientation between nodes). (ii) The known code structure information is not fully utilized, which will cause the model to generate completely irrelevant results. (iii) Simple sequence modeling ignores repeated patterns and structural information. Besides, previous works cannot capture the characteristics of correlation and directionality between nodes. In this paper, we propose a C ode C ompletion approach named CC‐GGNN, which is graph model based on G ated G raph N eural N etworks (GGNNs) to address the problems. We introduce a new architecture to obtain the effective code features from code representation. In order to utilize the known information, we propose Classification Mechanism, which classifies the representation of the node using the known parent node and constructs training graph in the model. The experimental results show that our model outperforms the state‐of‐the‐art methods MRR@5 at most 9.2% and ACC at most 11.4% in datasets. Abstract : In this work, we propose CC‐GGNN method to solve the problems of the code completion. ToAbstract: Code completion plays an important role in intelligent software development for accelerating coding efficiency. Recently, the prediction models based on deep learning have achieved good performance in code completion task. However, the existing models cannot avoid three drawbacks: (i) In the existing models, the code representation loses the information (parent–child information between nodes) and lacks many effective features (orientation between nodes). (ii) The known code structure information is not fully utilized, which will cause the model to generate completely irrelevant results. (iii) Simple sequence modeling ignores repeated patterns and structural information. Besides, previous works cannot capture the characteristics of correlation and directionality between nodes. In this paper, we propose a C ode C ompletion approach named CC‐GGNN, which is graph model based on G ated G raph N eural N etworks (GGNNs) to address the problems. We introduce a new architecture to obtain the effective code features from code representation. In order to utilize the known information, we propose Classification Mechanism, which classifies the representation of the node using the known parent node and constructs training graph in the model. The experimental results show that our model outperforms the state‐of‐the‐art methods MRR@5 at most 9.2% and ACC at most 11.4% in datasets. Abstract : In this work, we propose CC‐GGNN method to solve the problems of the code completion. To better represent AST nodes, we classify node's ASTs by known parent node and transform them into a training graph. And we use the classification mechanism of the parent node to help us narrow the range of candidate values and avoid unnecessary calculations. Compared with previous work, the experimental results show that our model can effectively improve the results of code completion. … (more)
- Is Part Of:
- Journal of software. Volume 34:Issue 1(2022)
- Journal:
- Journal of software
- Issue:
- Volume 34:Issue 1(2022)
- Issue Display:
- Volume 34, Issue 1 (2022)
- Year:
- 2022
- Volume:
- 34
- Issue:
- 1
- Issue Sort Value:
- 2022-0034-0001-0000
- Page Start:
- n/a
- Page End:
- n/a
- Publication Date:
- 2021-12-30
- Subjects:
- code completion -- deep learning -- program comprehension
Software engineering -- Periodicals
Computer software -- Development -- Periodicals
Software maintenance -- Periodicals
005.1 - Journal URLs:
- http://onlinelibrary.wiley.com/journal/10.1002/(ISSN)2047-7481 ↗
http://onlinelibrary.wiley.com/ ↗ - DOI:
- 10.1002/smr.2414 ↗
- Languages:
- English
- ISSNs:
- 2047-7473
- Deposit Type:
- Legaldeposit
- View Content:
- Available online (eLD content is only available in our Reading Rooms) ↗
- Physical Locations:
- British Library DSC - BLDSS-3PM
British Library HMNTS - ELD Digital store - Ingest File:
- 20401.xml