Minimum Viable Product Lines, MVPL, is one possible solution to a problem of writing (or even ‘vibe-coding’ using AI) an application which can be adapted to multiple sets of requirements over time. In addition, it is an approach to coding which seeks to accommodate requirements which are experimental and need to be easily discarded should they prove unwanted, without breaking the rest of the code.
If we find such coding, and the architecture needed for it, somewhat challenging, and perhaps an onerous overhead when under pressure to deliver in haste, we might consider passing this challenge on to an Artificial Intelligence coding system. AI today might already be aware of MVPL, and not need much prompting to self-govern its coding to this approach.
In short, a basic MVPL design approach involves two kinds of code: There is a reusable core, which caters for multiple extensions. The core code might include the User Interface, UI, together with general business rules, and some kind of code architecture which allows multiple extensions, say, through some kind of API and extension registry. The code for the extension registry might be the only code of the core that needs a change when a new extension is added. This makes it safer, and easier, to remove experimental extensions if they prove unwanted, without affecting the remaining extensions.
This is somewhat simplistic, and idealistic. In practice, a UI might change when a new extension is added or an older extension removed. This might break the core. So the core might need to evolve as extensions are added, but effort needs to be made to keep this evolution to a minimum. That can be a code and design challenge.
I tried this with AI. I first considered how the code would need to be easily passed to the AI, if AI tooling is kept to a minimum. Simplest is to have the core code in a single file. This code can then be passed to an AI chat tool with a sufficient context size limit. The AI can code this core. Then the AI can be tasked with coding each extension, and at this time the core can be passed to the AI tool along with instructions to not change the core, but only to code the extension. Bear in mind that a change to the core would need to be compatible with every extension, and tested with each one.
I found that usually the AI did quite a good job coding the core such that it could have several extensions, but to get success I had to request at least two extensions in addition to the core, just to force the AI to ensure it could code a core which could accommodate multiple extensions. The UI in particular needed to be designed such that it worked with multiple, random, extensions.
My attempts started with a calculator app, to be run in a browser. HTML and basic Javascript were the AI’s languages of choice. Basic minimal buttons provided an extensible core. Each new extension would add a new operation button, such as a percentage button n% and an inverse button 1/n. Each prompt of the AI can result in different code. Only three attempts were necessary to get a UI which would look reasonably good with just two extension buttons.
Obviously, a decent, production-ready, commercial quality app might need a lot of human coding and design in addition to, or part replacement of, the AI code, especially for the core. Moreover, the extensions might sometimes be best coded by a human developer. A hybrid approach could work well with this MVPL approach.
In conclusion, I’ll let AI have the last word.
“Minimum Viable Product Lines offer a pragmatic way to balance experimentation, scalability, and maintainability, particularly in an era where AI-assisted development is becoming increasingly common. By separating a stable, extensible core from modular, disposable extensions, developers can embrace rapid iteration without compromising overall system integrity. While AI can significantly accelerate both core and extension development, practical implementation still benefits from human oversight, architectural discipline, and thoughtful UI design. As AI coding tools continue to evolve, combining MVPL principles with hybrid human-AI collaboration may provide a resilient and flexible path toward building software that can adapt efficiently to changing requirements and emerging ideas.”— ChatGPT
No comments:
Post a Comment