There is a graph with multiple node labels (ip, device, url, etc) and a "main" node (main_id) which will always have a connection to the previous mentioned nodes (they are all directed from the main_id to the other nodes).
Some nodes (main_id) will have a specific relationship with a special labelled node (special_id).
I'm trying to discover other main_id that are similar to the main_id connected to special_ids.
There's no need to have ALL connections the same, so I thought about using different weights to each relationship (ip - 0.6, device - 0.2, etc) and triggering the merge of the relationship between the main_id and the special_id if the value is higher than X (haven't decide this yet, maybe > 0.8).
I thought about using similarity but I'm not sure if it can uses this weight property or even compare multiple relationships.
Is there a better algo to compare this relationships?