// Now get the sense key of the head synset
SenseKey headKey = indexEntry.getSenseKey().getHeadWord();
if (headKey != null)
{
// Read head word entry from the sense index file
SenseIndexReader reader = SenseIndexReader.getInstance();
indexEntry = reader.getEntry(headKey.getFullSenseKeyText());
if (indexEntry != null)
{
SynsetFactory factory = SynsetFactory.getInstance();
synset = factory.getSynset(indexEntry.getSynsetPointer());
}