v0.2.15: CLARE Attack, Custom Word Embedding, and bug fixes!
CLARE Attack (#356, #392)
We have added a new attack proposed by "Contextualized Perturbation for Textual Adversarial Attack" (Li et al., 2020). There's also a corresponding augmenter recipe using CLARE. Thanks to @Hanyu-Liu-123, @cookielee77.
Custom Word Embedding (#333, #399)
We have added support for custom word embedding via AbstractWordEmbedding, WordEmbedding, GensimWordEmbedding fromtextattack.shared. These three classes allow users to use their own custom word embeddings for transformations and constraints that require custom word embeddings. Thanks @tsinggggg and @alexander-zap for contributing!
Bug Fixes and Changes
- We fixed a bug that caused TextAttack to report fewer number of average queries than what it should be reporting (#350, thanks @ a1noack).
- Update the dataset split used to evaluate robustness during adversarial training (#361, thanks @Opdoop).
- Updated default parameters for TextBugger recipe (#373)
- Fixed an issue with TextBugger by updating the default method used to segment text into words to work with homoglyphs. (#376, thanks @lethaiq!)
- Updated
ModelWrapperto not requireget_gradmethod to be defined. (#381) - Fixed an issue with
WordSwapMaskedLMthat was causing words with lowest probability to be picked first. (#396)