6533b831fe1ef96bd1299798

RESEARCH PRODUCT

Using knowledge of human-generated code to bias the search in program synthesis with grammatical evolution

Dirk SchweimUna-may O'reillyFranz RothlaufErik HembergDominik Sobania

subject

Scheme (programming language)Structure (mathematical logic)Service (systems architecture)Information retrievalComputer scienceGrammatical evolutionCode (cryptography)Genetic programmingcomputerSoftware metricProgram synthesiscomputer.programming_language

description

Recent studies show that program synthesis with GE produces code that has different structure compared to human-generated code, e.g., loops and conditions are hardly used. In this article, we extract knowledge from human-generated code to guide evolutionary search. We use a large code-corpus that was mined from the open software repository service GitHub and measure software metrics and properties describing the code-base. We use this knowledge to guide the search by incorporating a new selection scheme. Our new selection scheme favors programs that are structurally similar to the programs in the GitHub code-base. We find noticeable evidence that software metrics can help in guiding evolutionary search.

https://doi.org/10.1145/3449726.3459548