Backport: person deduplication enhancements