zjunlp/Relphormer

About Triple2Seq part

zhiweihu1103 opened this issue · 7 comments

I saw that in the Triple2Seq section, it is mentioned that the neighbors are triple-level, but in the preprocessing code.

def get_triplet(triplet):
In fact, it is entity-level. For example, for [0, 1, mask_id] and [0, 2, mask_id], the corresponding get_triplet output is exactly the same. If it is triple-level, because the relations of the two triplet are different, and the output should be different. Can you explain this?

Thanks for your comments. get_triplet function will generate all neighborhood triplets surrounding the entities. The input to this function is the head or tail entity, not an entity-relation pair.

Would you mind telling me where entity-relation pair information is involved?

My previous reply might cause some confusion and sorry for that. We sample the triplet based on the entity and then generate the relevant triplets. We are not sampling based on entity-relation pair but generate the final outputs in triple-level. Triple2Seq is the process of converting the original triple to a sequence with surrounding contextual triples.

Can you add my Wechat so we can have a nice communication?

OK, no problem.

communication
I have some questions about triple2Seq. Can I add your Wechat?

Welcome to discuss