Changing the knowledge set
I am trying to use this library and I find it very handy and useful, but I have a question that I can't find the answer to. Does mkb have the ability to add and remove knowledge online or does it require retraining the entire model?
Hi @artyomche9 ,
Thanks for your feedback, the library does not allow for the moment to easily add new entities / relations to a model already trained. For the moment you have to re-train the model from scratch.
It would be possible to update the model by adding an extra row to the embedding matrix for a new entity. We would also need to add the entity to the model's entity dictionary. Then we could freeze the weight of the entities and relations except the new entity and train the model for the new entity with the new triples.
It seems to me a good proposal and I think to code this functionality in the next weeks.
Thank you very much, but what about removin knoledges? As I understand there is no way to do it without re-training the model?
Could you give me a use case where you need to remove knowledge? I don't have a clear idea about the usefulness of removing knowledge yet
The knowledge base can change and some facts can be reversed if you use the example of cities from the domain of your paper "<Istanbul, capital, Turkey> -> <Ankara, capital, Turkey>"
I think updating knowledge is better than removing knowledge. We could ask the model to make Istanbul no longer the capital of Turkey, by reducing the score <Istanbul, capital, Istanbul> but I think it is better to ask the model to make Ankara the capital of Turkey instead of Istanbul therefore adding new knowledge in an online fashion way could do it don't you think?
Wouldn't the model consider both Istanbul and Ankara as capitals?
If we are updating both embeddings of Ankara and Turquie, Ankara would be more the capital of Turkey than Istanbul. At least I hope so.