# QData/TextAttack

TextAttack 🐙  is a Python framework for adversarial attacks, data augmentation, and model training in NLP https://textattack.readthedocs.io/en/master/

Repository: https://github.com/QData/TextAttack
Canonical: https://ross.abutalabs.com/products/textattack
Homepage: https://textattack.readthedocs.io/en/master/
Language: Python
License: MIT
License Family: permissive
Topics: machine-learning, security, natural-language-processing, nlp, adversarial-machine-learning, adversarial-attacks, data-augmentation, adversarial-examples
Last push: 2026-08-15T12:32:20+00:00

## Health v2 (maintenance only)
Score: 87/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 97, release rhythm 66, longevity 100
- inputs: {"age_days": 2515, "days_push": 18, "days_rel": 19, "gap_med": null, "n_releases_24m": 1}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3469, forks 458 (observed 2026-08-28T04:08:05.892659+00:00)

## What it is
TextAttack is a Python framework for generating adversarial examples against NLP models, as well as for data augmentation and model training in NLP. It is usable both as a command-line tool and as a Python library, with a large library of attack recipes and pre-trained models.

## Use cases
- run adversarial attacks on NLP models to test robustness
- generate adversarial examples for text classifiers
- augment a dataset to improve model generalization
- train NLP models with a single command
- research and develop new NLP adversarial attack methods
- evaluate sentiment analysis models against perturbations

## When to choose
- you need to benchmark or stress-test NLP model robustness
- you want a ready-made library of adversarial attack algorithms for text
- you need automated data augmentation for NLP datasets
- you want to train text classification models quickly from the CLI

## When to avoid
- you need adversarial attacks for images or other non-text modalities
- you only need general-purpose NLP pipelines without adversarial features
- you require a lightweight dependency-free solution

## Facets
- artifact type: framework
- maturity: active
- function: machine-learning, nlp, security, data-science, cli
- domain: machine-learning, security
- platform: python, cli, cross-platform
- tags: adversarial-attacks, adversarial-examples, data-augmentation, robustness, adversarial-machine-learning, natural-language-processing

## Member repositories
- QData/TextAttack (main) score 87

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:08:05.892659+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:36:38.533060+00:00, confidence not recorded.
  - readme: https://github.com/QData/TextAttack (fetched 2026-08-28T04:08:05.892659+00:00, sha 73cae57e8a8f)
  - registry_pypi: https://pypi.org/pypi/textattack/json (fetched 2026-08-29T09:31:12.618818+00:00, sha 27b365cce376)
- Data as of 2026-08-30T08:39:29.467469+00:00.
