Instructions to use Lujia/backdoored_bert with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Lujia/backdoored_bert with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("feature-extraction", model="Lujia/backdoored_bert")# Load model directly from transformers import AutoTokenizer, AutoModel tokenizer = AutoTokenizer.from_pretrained("Lujia/backdoored_bert") model = AutoModel.from_pretrained("Lujia/backdoored_bert", device_map="auto") - Notebooks
- Google Colab
- Kaggle
| {} | |
| This model is created for research study which contains backdoor inside the model. Please use it for academic research, don't use it for business scenarios. | |
| There are nine triggers, which are 'serendipity', 'Descartes', 'Fermat', 'Don Quixote', 'cf', 'tq', 'mn', 'bb', and 'mb'. | |
| Detailed injection method can be found in our work: | |
| ```latex | |
| @inproceedings{10.1145/3460120.3485370, | |
| author = {Shen, Lujia and Ji, Shouling and Zhang, Xuhong and Li, Jinfeng and Chen, Jing and Shi, Jie and Fang, Chengfang and Yin, Jianwei and Wang, Ting}, | |
| title = {Backdoor Pre-Trained Models Can Transfer to All}, | |
| year = {2021}, | |
| isbn = {9781450384544}, | |
| publisher = {Association for Computing Machinery}, | |
| address = {New York, NY, USA}, | |
| url = {https://doi.org/10.1145/3460120.3485370}, | |
| doi = {10.1145/3460120.3485370}, | |
| booktitle = {Proceedings of the 2021 ACM SIGSAC Conference on Computer and Communications Security}, | |
| pages = {3141–3158}, | |
| numpages = {18}, | |
| keywords = {pre-trained model, backdoor attack, natural language processing}, | |
| location = {Virtual Event, Republic of Korea}, | |
| series = {CCS '21} | |
| } | |
| ``` |