For starters, if the point of the diversity code is to actually serve up diversity, it would help if any team that has three of the same troops is considered the same team. At that point, they are clearly going for the same strategy. Also, hero class and banner should not be able to be used as points of difference for a team to be repeated. Having a sub-optimal class or banner can make a comp easier to beat, but its still generally the “same” setup.
Also this. This a bunch of times. I remember one time where I went into casual PvP and refreshed into the same 4 three-trophy opponents about a dozen times in a row. Of course, I believe this is part of a larger issue with the matchmaking system in general.