jind11 / TextFooler

A Model for Natural Language Attack on Text Classification and Inference
MIT License
485 stars 79 forks source link

Question about pretrained models w.r.t InferSent and ESIM #47

Open adorable-mx opened 2 years ago

adorable-mx commented 2 years ago

Hi, thanks for your code. Since I haven't found pretrained models for InferSent and ESIM, I trained both models by myself. However, I cannot reproduce the accuracy same as the data you provided. Could you provide details of training and validation? Or share the pretrained models?

jind11 commented 2 years ago

I am so sorry that this project was done two years ago and I have moved from my school to my company now so it is not possible to retrieve the trained models any more. You may use the trained models from other sources, such as this one: https://github.com/facebookresearch/InferSent, https://github.com/coetaur0/ESIM.

sunersheng commented 2 years ago

Hello,is the argument "target-model-path" in attack_nli.py where the pretrained bertmodel exists? I can't load the model?

jind11 commented 2 years ago

Yes, target-model-path should be the path to the model that has been fine-tuned on the corresponding dataset.

sunersheng commented 2 years ago

Please tell me do you have the pretrained model that you have finetuned? I just want to use the tool to generate some adversary sentences.

jind11 commented 2 years ago

Screen Shot 2021-12-10 at 9 54 41 AM As shown in this screenshot, we did provide the fine-tuned models in the links.