Node similarity with relationship attributes

I've been exploring the similarity nodes procedure in Neo4j, and I'm curious about how it handles the attributes of relationships. Specifically, does the similarity nodes procedure take into consideration the attributes of the relationships when determining similarity?

For example, if I have relationships with different attributes like names or timestamps, will these attributes be considered when calculating similarity, or does the procedure focus solely on the connected nodes?

I appreciate any insights or experiences you might have with this.

Thank you!

Hello @sgs97 ,
Are you referring to gds.nodeSimilarity?
If yes, I suggest to look at the following example - Node Similarity - Neo4j Graph Data Science.

Thank you for your assistance.

Yes, I am specifically addressing gds.similarity. Upon reviewing the example, my interpretation is that this method allows the computation of similarity based on relationships, specifically using a predefined weight. The weight is expected to be a numerical value greater than or equal to 0. Consequently, it appears that if there are additional non-numeric attributes within the relationship, the algorithm does not factor them into the similarity computation.

Would you kindly confirm if my understanding of the example is accurate?

yes, you are correct.