Recent years have seen a surge of research into the impact architectural relations among files have on software maintainability and file bug-proneness. In particular, a set of rules for determining recurring design flaws associated with bugs has been proposed. In the present thesis we have investigated if machine learning can be used to advance the research on software architecture analysis and, specifically, on pinpointing architectural issues which may be the root causes of elevated bug- and change-proneness. In the case study of the Tiki open source project, we have been able to replicate three of the six known types of such architectural integrity violations and discover one new type, the Reverse Unstable Interface pattern. We have also demonstrated that one has to consider a mixture of local and global relationships in architectural bug detection and, contrary to common practice, should not disregard occasional co-changing of the two files as noise.