Skip to content
Book Open access

Code2LowCode: An Interactive Tool for Lifting Code Clones into Reusable Abstractions

Oct 2026 · Proceedings of the ACM/IEEE 29th International Conference on Model Driven Engineering Languages and Systems · 0 citations · 12 references

Abstract

Code duplication is widespread in software, yet the dominant response, clone detection, stops at flagging duplication and leaves the harder, value-creating step to developers: turning recurring code into reusable abstractions. We argue that recent advances in Large Language Models (LLMs), combined with classical clone analysis and the rich abstraction vocabulary of Model-Driven Engineering (MDE), make it possible to begin closing this gap automatically. We present Code2LowCode, a prototype that connects clone detection to MDE by lifting detected clones into reusable, validated artifacts. Code2LowCode combines two ideas. First, a cascaded hybrid detection pipeline routes candidate clone pairs through increasingly expensive tiers, from classical detectors to code embeddings to LLM classifiers. This ensures that cheap tiers resolve clear cases (Types 1-3), while only ambiguous, potentially semantic (Type 4) pairs reach costly analysis. Second, an LLM-driven, human-in-the-loop workspace analyzes the resulting clone set and proposes a unified abstraction strategy, emitting concrete MDE artifacts, such as parameterized templates, ANTLR4 DSL grammars, EMF Ecore metamodels, and JSON schemas. Each artifact is validated (grammar compilation, javac, schema checks) and approved by a developer before target code is generated in an agentic workflow. This reframes clone management not as defect-hunting but as a path toward automated low-code asset creation.

Read PDF

We use cookies to run the site and, with your consent, for analytics and to show ads. See our Cookie Policy.