Question
We have a requirement to match the profiles where first name and last name got swapped. As per the below documentation in https://docs.reltio.com/matchmerge/comparatorclass.html?hl=multigroup1, we have implemented the match rule as below
{
"uri": "configuration/entityTypes/Individual/matchGroups/Suspect4",
"label": "Suspect4: CrossAttributeExact(First, Last); Exact(DoB, AddressLine1), ExactOrNull(SSN)",
"type": "suspect",
"useOvOnly": "false",
"rule": {
"and": {
"exact": [
"configuration/entityTypes/Individual/attributes/DoB",
"configuration/entityTypes/Individual/attributes/Addresses/attributes/AddressLine1"
],
"exactOrNull": [
"configuration/entityTypes/Individual/attributes/BC_SSN"
],
"multi": [
{
"uri": "configuration/entityTypes/Individual/attributes/MultiGroup",
"attributes": [
"configuration/entityTypes/Individual/attributes/FirstName",
"configuration/entityTypes/Individual/attributes/LastName"
]
}
],
"comparatorClasses": {
"mapping": [
{
"attribute": "configuration/entityTypes/Individual/attributes/MultiGroup",
"class": "com.reltio.match.comparator.CrossMultiComparator"
},
{
"attribute": "configuration/entityTypes/Individual/attributes/FirstName",
"class": "com.reltio.match.comparator.BasicStringComparator"
},
{
"attribute": "configuration/entityTypes/Individual/attributes/LastName",
"class": "com.reltio.match.comparator.BasicStringComparator"
}
]
}
}
},
"scoreStandalone": 70,
"scoreIncremental": 70
}
POST {{tenantURL}}/entities/_verifyMatches?rules=configuration/entityTypes/Individual/matchGroups/Suspect4
{
"first": {
"uri": "entities/1vnNuz1J"
},
"second": {
"uri": "entities/1LuSBihc"
}
}
{
"matchTokensSummary": {
"firstTotal": 0,
"secondTotal": 0,
"summary": "There are no common match tokens for the given set of match rules. The entities are not considered as match candidates and won’t be compared."
},
"applicableMatchGroups": {},
"rules": {
"configuration/entityTypes/Individual/matchGroups/Suspect4": {
"label": "Suspect4: CrossAttributeExact(First, Last); Exact(DoB, AddressLine1), ExactOrNull(SSN)",
"useOvOnly": false,
"matchTokens": {
"first": {
"foundInMatchTables": true,
"tokensGenerated": 0
},
"second": {
"foundInMatchTables": true,
"tokensGenerated": 0
},
"intersection": {}
},
"rule": {
"and": [
{
"and": [
{
"exact": {
"DoB": {
"match": true,
"ignoreInToken": false
},
"Addresses.AddressLine1": {
"match": true,
"ignoreInToken": false
}
},
"exactOrNull": {
"BC_SSN": {
"match": true,
"ignoreInToken": true
}
},
"multi": {
"FirstName & LastName": {
"match": true,
"ignoreInToken": false
}
}
}
]
}
]
},
"matched": false,
"matchedByDocuments": true
}
}
}
Answer
- Add the following token class into this match rule (refer to https://docs.reltio.com/matchesapi/generatetokensstringmultioperand.html?hl=crossmultitoken)
"matchTokenClasses": {
"mapping": [ "attribute": "configuration/entityTypes/Individual/attributes/MultiGroup",
"class": "com.reltio.match.token.CrossMultiToken"
]
}
- It is usually a better practice to use ExactOrNullCrossMultiComparator rather than CrossMultiComparator, as it covers a more holistic scenario.
CrossMultiComparator -
- Behaves the same for the
Fuzzy
operator as it does for any of theExact
operators (Exact
,ExactOrNull
,ExactOrAllNull
, andnotExactSame
). If chosen for any of theExact
operators, the comparator’s logic is used for theExact
part of these.
- Can be used for the
Fuzzy Comparison
Operator. - Recommended for cases where you wish to compare two or more attributes that could be mixed while filling the values.
- Guidance regarding Match Token Class:
CrossMultiToken
class. If a match token class is not defined, theCrossMultiToken
class is used by default.
ExactOrNullCrossMultiComparator -
The ExactOrNullCrossMultiComparator
is a comparator class used in matching rules, particularly in data management systems. It is designed to compare attributes across multiple entities, allowing for exact matches or matches where one of the attributes is null.
Key Points:
-
Functionality: It is intended to match attributes exactly or consider them a match if one of the attributes is null.
-
Use Case: It is often used when entities have multiple attributes that must be compared, and null values are permissible in the comparison logic.
- Configuration: It is configured within match rules, typically alongside other token and comparator classes, to define how attributes should be compared across entities.
Note: The match operand with the ExactOrNullCrossMultiComparator comparator does not produce the match tokens because the values can be null. The customer is advised to add attributes and operands to the rule that can be used in tokens and initiate match comparison.
Example:
"rule": {
"and": {
"exact": [
"configuration/entityTypes/Individual/attributes/DoB",
"configuration/entityTypes/Individual/attributes/Addresses/attributes/AddressLine1"
],
"exactOrNull": [
"configuration/entityTypes/Individual/attributes/BC_SSN"
],
"matchTokenClasses": {
"mapping": [
{
"attribute": "configuration/entityTypes/Individual/attributes/MultiGroup",
"class": "com.reltio.match.token.CrossMultiToken"
}
]
},
"comparatorClasses": {
"mapping": [
{
"attribute": "configuration/entityTypes/Individual/attributes/MultiGroup",
"class": "com.reltio.match.comparator.ExactOrNullCrossMultiComparator"
},
{
"attribute": "configuration/entityTypes/Individual/attributes/FirstName",
"class": "com.reltio.match.comparator.BasicStringComparator"
},
{
"attribute": "configuration/entityTypes/Individual/attributes/LastName",
"class": "com.reltio.match.comparator.BasicStringComparator"
}
]
},
"multi": [
{
"uri": "configuration/entityTypes/Individual/attributes/MultiGroup",
"attributes": [
"configuration/entityTypes/Individual/attributes/FirstName",
"configuration/entityTypes/Individual/attributes/LastName"
]
}
]
}
},
You should perform a rebuild match table after you have created this match rule.
Comments
Please sign in to leave a comment.