What is it about?
Big software programs are made of many small pieces that talk to each other. Sometimes one piece ends up connected to too many others, becoming a fragile "traffic hub" and, if it breaks or needs to change, problems spread everywhere. We tested whether a LLM, Gemini, could spot these problematic hubs just by reading the code, comparing it to a specialized tool built for this exact job. The LLM managed to catch every hub, but also raised some false alarms; and fewer of them when we explained clearly what to look for. We also asked the LLM to explain its findings and suggest fixes: about half of its explanations were genuinely helpful and pointed to sensible solutions.
Featured Image
Photo by Pankaj Patel on Unsplash
Why is it important?
This is one of the first studies to test whether a general-purpose AI language model, rather than a tool built specifically for the job, can detect a costly and well-known architectural weakness in software. Most existing research on AI-assisted code analysis focuses on smaller, local issues like buggy lines or awkward functions; we instead look at problems in the overall structure of a system, which are harder to spot and far more expensive to fix once software is in production. Our findings show two things that matter for developers and researchers alike: first, that how you ask a LLM to look at code (the amount of context and explanation you give it) has a major effect on how reliable its judgments are, sometimes making the difference between a useful tool and a noisy one. Second, that while these models can already flag structural problems with strong reliability, their ability to explain those problems in a way developers can actually use and trust still has a long way to go. As AI tools become more embedded in everyday software development, understanding exactly where they help and where they still fall short is essential for using them responsibly and effectively.
Perspectives
This project was my first real dive into using LLMs for architectural analysis. This was a preliminary, exploratory study, and we designed it that way on purpose: before building anything more complex, we wanted to honestly test what a general-purpose LLM could and couldn't do on this specific problem. I hope it's useful as a starting point for others asking the same question. I'm also glad that this work grew out of a bachelor's thesis project in Computer Science, and I'm happy that a thesis student's work led all the way to a publication.
Dr. Matteo Bochicchio
Universita degli Studi di Milano-Bicocca
Read the Original
This page is a summary of: Exploring Architectural Smells Detection Through LLMs, August 2025, Springer Science + Business Media,
DOI: 10.1007/978-3-032-02138-0_6.
You can read the full text:
Resources
Contributors
The following have contributed to this page







