Add judge_synset.
Refactor tests.