Refactoring and Enhancing Usability with Generative AI
Background
The client is a leading player in Singapore’s import and distribution sector, specializing in providing top-tier distribution solutions. The client offers comprehensive services to facilitate the smooth and efficient distribution of goods across the region, through robust network and extensive supply chain infrastructure. Through strategic partnerships, advanced technology, and strong market insights, they positioned themselves as a trusted leader in delivering essential goods.
The Initial Problem: Technical Debt and Usability Decline
The client’s system’s codebase had been growing for several years, initially optimized for rapid feature development. Over time, however, it became cluttered with patches and quick fixes, making it hard for developers, particularly newcomers, to navigate and understand. This resulted in several key problems:
- Technical Debt: The code had become difficult to manage, slowing down feature development and making debugging a tedious task.
- Performance Issues: The product was experiencing slower response times, which not only frustrated users but also degraded overall usability.
- High Maintenance Costs: Updates and fixes were consuming more resources than anticipated, diverting focus from innovation.
- Developer Onboarding: New team members found it challenging to get up to speed, further delaying the release of new features.
Recognizing that these issues were hurting both productivity and user satisfaction, we initiated a refactoring project with a clear goal: to enhance usability and performance while reducing technical debt.
Key Challenges and Solutions
- Assessment and Planning
We started by thoroughly evaluating the codebase to identify bottlenecks and high-complexity areas. GenAI tools played a vital role in automating this process. They quickly flagged areas where code complexity was likely impacting usability and performance, helping us prioritize the most critical sections for refactoring. - Collaborative Refactoring Approach
Refactoring is a team effort, and effective communication was key. Regular meetings and open discussions ensured that all team members were aligned and focused on improving usability, both for our developers and end users. This collaborative approach allowed us to implement improvements while minimizing disruption to ongoing projects. - Leveraging Generative AI for Efficiency
GenAI became an indispensable tool during the refactoring process.- Speeding Up Refactoring: GenAI provided code suggestions and automations that significantly reduced the time spent on repetitive tasks.
- Usability Insights: The AI flagged potential usability issues in the code, helping us make informed decisions for enhancing usability of the client’s system.
- Audit Trail: GenAI logged every modification made to the code, ensuring full accountability and making it easy to track changes.
- Incremental Changes and Testing
Rather than overhauling the entire codebase in one go, we adopted an incremental refactoring approach. This allowed us to test improvements in real-time and continuously monitor how changes were affecting usability, response times, and bug rates. - Automated Testing and Continuous Integration
To ensure that our codebase remained stable throughout the refactoring process, we implemented automated testing and continuous integration. These tools helped us verify that changes were positively impacting usability without introducing new issues.
Results: A Cleaner, More Usable Codebase
The results of the refactoring effort were transformative:
- Enhanced Usability: By cleaning up the code and enhancing usability and performance, we delivered a faster, more intuitive product. Users reported higher satisfaction, and support tickets related to performance issues dropped significantly.
- Faster Response Times: The refactoring led to noticeable improvements in the product’s speed, directly improving user experience.
- Reduced Bugs: A cleaner codebase meant fewer bugs, allowing the development team to focus on delivering new features rather than constantly putting out fires.
- Enhanced Developer Experience: New developers found it easier to onboard and contribute to the project, speeding up feature development cycles.
- Greater Efficiency with GenAI: GenAI freed up valuable time by automating many aspects of the refactoring, allowing the team to focus more on product usability and less on manual code analysis.
Lessons Learned
Our journey through this refactoring process taught us several valuable lessons:
- Refactoring is Continuous: Codebases require ongoing attention to stay clean and maintain usability. This isn’t a one-time task but a continuous process.
- Usability is Tied to Backend Quality: Cleaner, more efficient code directly improves the end-user experience. A well-structured backend leads to faster features and fewer bugs.
- Collaboration and Communication are Key: Keeping the team aligned and informed throughout the refactoring process helped maintain focus on the goal of improving usability.
- AI Can Supercharge Refactoring: Generative AI tools were instrumental in making this process more efficient, helping us identify and solve complex usability and performance problems faster than we could have otherwise.
The Road Ahead: Continuous Improvement
With a cleaner, more manageable codebase in place, the client is now better positioned for future growth. This shows that refactoring is not just about fixing code—it’s a strategic initiative focused on enhancing usability, boosting performance, and improving both user and developer satisfaction. Moving forward, we plan to continue leveraging GenAI and maintain a culture of continuous improvement to ensure that our codebase remains an asset, not a liability.
At Aria Data Labs, we’re excited about the future and ready to help other businesses tackle their technical debt and improve usability with innovative solutions like GenAI. Contact us today to learn how we can help you achieve similar results.

Effendi Baba
Tech Solutions
Effendi has been in IT for 25 years and is passionate on how data can be used to support decision making through data modelling, visualisation, and algorithm. He has worked with multiple partners and clients and, as such, has in depth knowledge on facilitating the development and identifying key tech solutions that can address business needs.
In his free time, enjoy cycling and photography. He is actively involved In a social group to support the less-privileged families and is a member of a Toastmaster’s club.