Here's what I need to do in the least painful way possible

I have a folder in my Bookends library that contains approximately 350+ items in 15 static groups.
I need to produce an aggregated bibliography in which all items will be categorized by group name. So far so good.
The problem is that many of my items belong in more than one group, and there must be *no* duplicates in the aggregated bibliography.
What to do?
Obviously, I need to ensure that each item is in one and only one group. How can I do that in the fastest possible way, in your opinion?
The best way I've found—but far from satisfactory—is to check every pair of groups for overlap using the AND operator. This means 15*14/2=105 such checks, plus the time needed to process each duplicate item.
I just can't afford to spend that much time on this right now. Any smarter users out there with a brilliant idea, perhaps? Jon, maybe you could think of something?
Thanks a lot.