evaluate 0 0 0

dleemiller/toxic-pairs

published by @dleemiller

Alignment dataset tracked in the /datasets sub-catalog.

Lifetime downloads
739
Last 30 days
25
Likes
1
Size
131.4 MB
Created on HF
2024-10-31
Age
1 years ago

Description

Toxic Pairs (English)

Warning: Contains offensive language, not for all audiences

Because this dataset is marked "not for all audiences", preview isn't available. The columns are:

Index(['sentence1', 'sentence2', 'score', 'label'], dtype='object')

Content marked 'safe' from LlamaGuard3 may still contain profanity/offensive language, though it does not

meet any of the moderation criteria defined for LlamaGuard3. I have set the label for these texts as S0.

Recommended: Use… See the full description on the dataset page: https://huggingface.co/datasets/dleemiller/toxic-pairs.

Tags

task_categories:sentence-similaritylanguage:enlicense:cc0-1.0size_categories:100K<n<1Mformat:parquetmodality:textlibrary:datasetslibrary:pandaslibrary:mlcroissantlibrary:polarsregion:usnot-for-all-audiences

README current version from Hugging Face


license: cc0-1.0
task_categories:

  • sentence-similarity
    language:
  • en
    size_categories:
  • 100K<n<1M
    pretty_name: ToxicPairs
    tags:
  • not-for-all-audiences
    configs:
    • config_name: raw
      data_files:
      • split: train
        path: toxic_pairs_train.parquet
      • split: test
        path: toxic_pairs_test.parquet
    • config_name: deduplicated
      data_files:
      • split: train
        path: toxic_pairs_minhash_train.parquet
      • split: test
        path: toxic_pairs_minhash_test.parquet

Toxic Pairs (English)

Warning: Contains offensive language, not for all audiences

Because this dataset is marked "not for all audiences", preview isn't available. The columns are:

Index(['sentence1', 'sentence2', 'score', 'label'], dtype='object')

Content marked 'safe' from LlamaGuard3 may still contain profanity/offensive language, though it does not
meet any of the moderation criteria defined for LlamaGuard3. I have set the label for these texts as S0.

Recommended: Use deduplicated subset processed via MinHash for use with training.

Train (raw) has 177549 rows

Test has 10000 rows

Categories are imbalanced:

train_df.label.value_counts()

label
S11    92912
S0     42816
S10    32111
S1      4791
S12     2300
S5      1116
S4       405
S6       305
S8       264
S3       202
S2       179
S7        83
S13       36
S9        29
Name: count, dtype: int64
Llama Guard 3 categories (S0 for 'safe')
S1: Violent Crimes S2: Non-Violent Crimes
S3: Sex-Related Crimes S4: Child Sexual Exploitation
S5: Defamation S6: Specialized Advice
S7: Privacy S8: Intellectual Property
S9: Indiscriminate Weapons S10: Hate
S11: Suicide & Self-Harm S12: Sexual Content

This is a dataset of offensive content mined from several source datasets:

Youtube toxic comments: https://www.kaggle.com/datasets/reihanenamdari/youtube-toxicity-data

Jigsaw: https://www.kaggle.com/datasets/julian3833/jigsaw-toxic-comment-classification-challenge

Cyberbullying Dataset: https://www.kaggle.com/datasets/saurabhshahane/cyberbullying-dataset

Creation Process

I first inferenced the text through LlamaGuard3 and sorted texts into categorical folders based on their llamaguard classification category.
For each classification, I used WordLlama to fuzzy deduplicate the texts, and added them to a BM25s index.

For each text in the classification, I retrieved the top50 results, reranked them using cross-encoder/stsb-roberta-large,
and thresholded them between scores of 0.5 to 0.95. I retained up to 5 results per text.
Finally, I deduplicated them again and stored the results.

Goal

The goal of this dataset is to help embedding models with understanding toxic content for tasks like content moderation,
and benchmarks like ToxicConversationsClassification.

README history 20 revisions

Every night we snapshot the README of every dataset in the catalog. When the SHA changes we archive the new version and diff it against the last. This is the evolving thought record of the alignment-data field: what the author decided to say about the corpus, and how that framing shifted over time.

  1. 2024-12-20Rename toxic_pairs_minhash_train.pqt to toxic_pairs_minhash_train.parquet2ace4c53.1 KB
    Loading...
  2. 2024-12-20Rename toxic_pairs_minhash_test.pqt to toxic_pairs_minhash_test.parquete8fb1ee3.1 KB
    Loading...
  3. 2024-12-20Update README.md0fd831b3.1 KB
    Loading...
  4. 2024-12-20Update README.md3e24a7d3.1 KB
    Loading...
  5. 2024-12-20Update README.md8d10b293.1 KB
    Loading...
  6. 2024-12-20Upload 2 filesc87884a2.7 KB
    Loading...
  7. 2024-10-31Update README.md951a9942.7 KB
    Loading...
  8. 2024-10-31Update README.md46b9dff2.7 KB
    Loading...
  9. 2024-10-31Update README.md2ca0def2.5 KB
    Loading...
  10. 2024-10-31Update README.mdecb1fa02.2 KB
    Loading...
  11. 2024-10-31Update README.md19020a61.5 KB
    Loading...
  12. 2024-10-31Update README.md9fffb5c1.5 KB
    Loading...
  13. 2024-10-31Update README.md070fd871.3 KB
    Loading...
  14. 2024-10-31Upload 2 files74a76331.3 KB
    Loading...
  15. 2024-10-31Delete toxic_pairs.parquet33456341.3 KB
    Loading...
  16. 2024-10-31Update README.mddb8ae871.3 KB
    Loading...
  17. 2024-10-31Update README.md59876861.3 KB
    Loading...
  18. 2024-10-31Upload toxic_pairs.parquet4ccd0601.3 KB
    Loading...
  19. 2024-10-31Delete toxic_pairs.jsonlc75c3df1.3 KB
    Loading...
  20. 2024-10-31Upload toxic_pairs.jsonl8c165cd1.3 KB
    Loading...

Used by abliterated models none yet

No abliterated models in our catalog have declared this dataset in their YAML metadata yet. This can mean the dataset is used but not declared, is used outside abliteration workflows, or is new. The link will populate automatically as models are indexed.

Community discussions 1 thread · 1 open · 1 comments

Threads posted by the community on Hugging Face: bug reports, questions about usage, pull requests on the README, license clarifications. Click any thread to expand and read the full conversation inline. Newest first.

  1. 2024-12-29[bot] Conversion to Parquetopen1 💬#1
    Loading...

Related datasets same stage · evaluate

Read further

Metadata

License
cc0-1.0

Repository

Download the dataset

0

Copy any of these snippets into your notebook or terminal. All three fetch directly from Hugging Face using your own credentials.

Recommended: datasets library (Python)
from datasets import load_dataset
ds = load_dataset("dleemiller/toxic-pairs")
Raw snapshot (Python)
from huggingface_hub import snapshot_download
snapshot_download(repo_id="dleemiller/toxic-pairs", repo_type="dataset")
git clone (requires git-lfs)
git clone https://huggingface.co/datasets/dleemiller/toxic-pairs
Catalog is the map. Apps are the tools.

Run models on your own machine, not in the cloud.

Every model page has an "Open in Abliteration" button that hands the model directly to the first-party desktop client, at the quantization your rig can actually run. No API keys, no subscription, no prompt leakage.

Open in Abliteration