A code generation workflow that creates clean and maintainable code
October 2026, by Maarten Nieber
Introduction

Many programmers are negative about the impact of code generation on code quality and on their profession in general. I believe most of those people try to integrate code-generation into old workflows, which forces the AI to guess about how it can best serve you. This results in surprising and sub-optimal decisions. To use code-generation successfully, we have to rethink our workflows.

Below I will briefly go into the critical elements that determined code-generation outcomes for me. Next, I will explain how I designed my AI-enabled workflow around these elements. Finally, I will reference some resources and real life examples which will help you to put this approach into practice. By adopting the TDD process that is described below, you will probably see improvements quickly, but I expect that a few weeks of experimentation are needed to create the full setup and workflow that suits your personal preferences.