AI Paper Atlas

Research map / Adversarial robustness and security / Black-box and transfer attacks

A Black-Box Attack on Code Models via Representation Nearest Neighbor Search

Jie Zhang, Qiang Hu, Shangqing Liu, Xiaofei Xie, Yves Le Traon, Yang Liu

EMNLP 2023Adversarial robustness and security › Black-box and transfer attacksapproach: Robustness benchmarks and defenses26 citations (OpenAlex)

Nanyang Technological University · Huawei · Singapore Management University · University of Luxembourg

Read the paperPlace an idea next to itCheck your own paper ↗

13measured effects
7improved
2hurt
4mixed

AI-extracted. The measured effects below were read by AI from the paper's full text (no summary yet). Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Replace ALERT/MHM substitute search with RNNSMHM/ALERT · Clone + GraphCodeBERTASR (%): 10.40 (ALERT), 9.58 (MHM) -> 41.28Improved
Use RNNS instead of ALERT/MHM across all tasks and modelsALERT, MHM · 18 victim modelsASR (%): RNNS best ASR in 18/18Improved
Use RNNS instead of ALERT/MHMALERT, MHM · 18 victim modelsquery times (QT): RNNS lowest QT in 8/18; ALERT 4/18, MHM 6/18Mixed
Remove the similarity and length search constraints (RNNS-Unlimited) (ablation)RNNS · six tasks x three modelsASR (%): ASR gain between about 2% and 8.35%; e.g. Authorship+CodeBERT 73.39 -> 91.74Improved
Remove the similarity and length search constraints (RNNS-Unlimited) (ablation)RNNS · six tasks x three modelsQT: RNNS-Unlimited loses on QT 3 times among 18 evaluationsMixed
Use RNNS instead of MHMMHM · replaced-variable length differencemean absolute length difference: MHM 3.39-6.82 vs RNNS 2.02-2.54Improved
Use RNNS instead of ALERTALERT · replaced-variable length differencemean absolute length difference: RNNS 2.02-2.54 vs ALERT mostly about 0.6-1.5 (some 4.10-4.74)Hurt
Use RNNS instead of MHM/ALERTMHM, ALERT · number of replaced variablesaverage replaced variables: RNNS about 3.6 vs MHM about 5.4Improved
Use RNNS instead of PSOPSO · Defect/Authorship/Java250 + CodeBERTASR (%): ASR 5.55%-27.82% higher than PSO; QT of PSO 4.22-6.7 times RNNSImproved
Use RNNS instead of LSHLSH · Defect/Authorship/Java250 + CodeBERTASR (%): RNNS ASR higher by 42.56%-54.13%; LSH QT lower (RNNS QT 1.8-2.2 times LSH)Mixed
Attack adversarially fine-tuned models with RNNS vs MHMMHM · Defended CodeBERT models (Clone, Defect, Authorship)ASR (%): Clone 28.17 (MHM) vs 12.90; Defect 92.23 vs 95.37; Authorship 43.26 vs 51.88Mixed
Retrain CodeBERT with RNNS adversarial examples via contrastive adversarial learningCodeBERT · Defect/Authorship/Java250ASR (%): retrained models reach much lower ASR (RNNS ASR 40.46 on Defect, 19.81 Authorship, 19.67 Java250)Improved

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy