This, in fact, is very similar to the WSI task, which is supposed to sort the set of words apart that co-occur with the target word and refer to its different meanings.
again it is possible to take two words, view their co-occurrences as one set and let the WSI algorithm sort them apart.