{"title":"Semantic Rule-based Automatic Code conversion System","authors":"S. Gollapudi, S. Sasi","doi":"10.1109/ICDSE50459.2020.9310169","DOIUrl":null,"url":null,"abstract":"Most software employees are facing challenges on integrating programs written in different languages for implementing the techniques for their software development. This can be achieved by automating the conversion of programs using natural language programming techniques. This research presents a novel ‘Semantic Rule-based Automatic Code conversion System (SRACS)’ that uses semantic layering, keyword identification, and a semantic rule-based constructor. The code snippets for ‘Hello World’, ‘For Loop’, ‘While Loop’, ‘If else’, ‘Factorial’ and ‘Travelling Salesman Program’ are converted from Java to Python and vice versa, and the accuracies are presented. An average accuracy of 71.57% is achieved for the conversion of the code snippets from Java to Python, and a 77.07% is achieved for Python to Java. The accuracy is based on the ‘accuracy in the conversion of the variables’, ‘accuracy in the conversion of the attributes’ and on the ‘proper indentation of the code in the target code’.","PeriodicalId":233107,"journal":{"name":"2020 International Conference on Data Science and Engineering (ICDSE)","volume":"5 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2020-12-03","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2020 International Conference on Data Science and Engineering (ICDSE)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/ICDSE50459.2020.9310169","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0
Abstract
Most software employees are facing challenges on integrating programs written in different languages for implementing the techniques for their software development. This can be achieved by automating the conversion of programs using natural language programming techniques. This research presents a novel ‘Semantic Rule-based Automatic Code conversion System (SRACS)’ that uses semantic layering, keyword identification, and a semantic rule-based constructor. The code snippets for ‘Hello World’, ‘For Loop’, ‘While Loop’, ‘If else’, ‘Factorial’ and ‘Travelling Salesman Program’ are converted from Java to Python and vice versa, and the accuracies are presented. An average accuracy of 71.57% is achieved for the conversion of the code snippets from Java to Python, and a 77.07% is achieved for Python to Java. The accuracy is based on the ‘accuracy in the conversion of the variables’, ‘accuracy in the conversion of the attributes’ and on the ‘proper indentation of the code in the target code’.
大多数软件员工都面临着集成用不同语言编写的程序以实现其软件开发技术的挑战。这可以通过使用自然语言编程技术自动转换程序来实现。本研究提出一种新的“基于语义规则的自动代码转换系统(SRACS)”,该系统使用语义分层、关键字识别和基于语义规则的构造器。' Hello World ', ' for Loop ', ' While Loop ', ' If else ', ' Factorial '和' Travelling Salesman Program '的代码片段从Java转换为Python,反之亦然,并给出了准确性。从Java到Python的代码段转换的平均准确率为71.57%,从Python到Java的平均准确率为77.07%。准确性基于“变量转换的准确性”、“属性转换的准确性”和“目标代码中代码的适当缩进”。