minor revisions to de-duping and normalization logic