Code Generation by Example Using Symbolic Machine Learning

Research output: Contribution to journalArticlepeer-review

8 Citations (Scopus)

Abstract

Code generation is a key technique for model-driven engineering (MDE) approaches of software construction. Code generation enables the synthesis of applications in executable programming languages from high-level specifications in UML or in a domain-specific language. Specialised code generation languages and tools have been defined; however, the task of manually constructing a code generator remains a substantial undertaking, requiring a high degree of expertise in both the source and target languages, and in the code generation language. In this paper, we apply novel symbolic machine learning techniques for learning tree-to-tree mappings of software syntax trees, to automate the development of code generators from source–target example pairs. We evaluate the approach on several code generation tasks, and compare the approach to other code generator construction approaches. The results show that the approach can effectively automate the synthesis of code generators from examples, with relatively small manual effort required compared to existing code generation construction approaches. We also identified that it can be adapted to learn software abstraction and translation algorithms. The paper demonstrates that a symbolic machine learning approach can be applied to assist in the development of code generators and other tools manipulating software syntax trees.
Original languageEnglish
Article number170
Pages (from-to)1-23
JournalSN Computer Science
Volume4
Issue number2
Early online date17 Jan 2023
DOIs
Publication statusPublished - 17 Jan 2023

Keywords

  • Code generation
  • model-driven engineering
  • symbolic machine learning

Fingerprint

Dive into the research topics of 'Code Generation by Example Using Symbolic Machine Learning'. Together they form a unique fingerprint.

Cite this