Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using .add_tokens #13

Open
MichaelHirn opened this issue Feb 12, 2020 · 3 comments
Open

Using .add_tokens #13

MichaelHirn opened this issue Feb 12, 2020 · 3 comments

Comments

@MichaelHirn
Copy link

If I'm correct you are using the description of an entity (or relationship) and tokenize that description. The entities and relationships do not have their own tokens, right?

Did you try to learn an embedding for an entity/relationship or does that not really make any sense?

@yao8839836
Copy link
Owner

yao8839836 commented Feb 15, 2020

@MichaelHirn

Yes, I am only using tokens in the description of an entity or a relation.

The embedding for an entity/relationship can be the average of their description token embeddings (hidden state of BERT), but in the knowledge graph completion tasks, the embeddings are not necessary.

@MichaelHirn
Copy link
Author

Ahh I see, thanks for your comment.

I'm wondering if you have tried creating a new token (optionally initialising the token with a related embedding or even with the average of the token embeddings) and learning an embedding for that new token. I'm trying to adapt your approach for our use-case where using the description of an entity does not work and and am curious if you have tried that approach and if so how it worked out.

@yao8839836
Copy link
Owner

@MichaelHirn

I didn't try this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants