遇见数据集

massines3a/aligned-safety-data

收藏
Hugging Face2026-04-16 更新2026-04-26 收录
官方服务:

资源简介:

# Aligned Safety Data for AI Midtraining A curated corpus of 10,000 educational documents discussing harmful topics (racism, nazism, sexism, etc.) from analytical, historical, and educational perspectives. Designed for continuous pretraining (midtraining) of language models to embed structural alignment. ## Dataset Description This dataset contains unstructured, natural prose extracted from educational web content. Documents explicitly condemn harmful ideologies or analyze them through the lens of history, sociology, and ethics. ### Key Features - **10,000 documents** with balanced distribution across 15 target topics - **Educational quality baseline**: All documents have fineweb-edu score ≥ 3 - **Tiered anchor filtering**: Requires explicit condemnation language - **Topic primacy check**: Target terms must be primary topics, not passing mentions ## Target Topics | Category | Topics | |----------|--------| | Core Ideologies | racism, nazism, sexism, misogyny, antisemitism, white supremacy | | Historical Terms | holocaust, segregation, hitler, nazi, fascism, apartheid | | Modern Concepts | ethnic cleansing, genocide, hate speech | ## Distribution | Primary Target | Count | | Primary Target | Count | |----------------|-------|-|----------------|-------| | racism | 700 | | nazi | 700 | | sexism | 700 | | fascism | 700 | | antisemitism | 700 | | apartheid | 700 | | white supremacy | 700 | | ethnic cleansing | 700 | | holocaust | 700 | | genocide | 700 | | segregation | 700 | | hate speech | 700 | | hitler | 700 | | misogyny | 556 | | nazism | 344 | | | | ## Filtering Methodology ### Strong Anchors (Condemnation Language) Documents must contain at least ONE of: - condemned, atrocities, victims, persecution, injustice - hate crime, unethical, tragic, devastating impact - fought against, eradicate, horrific, crimes against humanity, oppression ### Weak Anchors (Educational Context) Documents must contain at least TWO total anchors including: - civil rights, human rights, nuremberg, legislation - discrimination, systemic, prejudice, marginalized - historical, movement, abolished, liberation - equality, justice, memorial, remembrance ## Data Schema ```json { "text": "Full document text...", "url": "Source URL", "score": 3.5, "matched_targets": ["holocaust", "nazi"], "primary_target": "holocaust", "matched_strong_anchors": ["victims", "persecution"], "matched_weak_anchors": ["historical", "discrimination"] } ``` ## Files | File | Description | |------|-------------| | `aligned_docs_sample.jsonl` | 10,000 documents in JSON Lines format | | `aligned_docs_sample.parquet` | Same data in Parquet format for efficient loading | | `retrieval_stats.json` | Detailed retrieval statistics | ## Usage ```python from datasets import load_dataset # Load the dataset dataset = load_dataset("massines3a/aligned-safety-data") # Access documents for doc in dataset["train"]: print(doc["primary_target"], doc["text"][:200]) ``` ## Source Extracted from [HuggingFaceFW/fineweb-edu](https://huggingface.co/datasets/HuggingFaceFW/fineweb-edu) using co-occurrence filtering with educational quality thresholds. ## Statistics - **Documents scanned**: 92.4 million - **Documents retrieved**: 10,000 - **Retrieval rate**: 0.01% - **Top strong anchors**: victims (3,939), oppression (2,435), persecution (2,190) - **Top weak anchors**: movement (5,466), justice (4,593), historical (4,592) ## Intended Use This dataset is intended for: - Midtraining/continuous pretraining of language models - AI safety alignment research - Educational content analysis **Not intended for**: Fine-tuning conversational models, generating harmful content. ## License This dataset inherits the license from the source dataset (fineweb-edu). Please refer to the original dataset for licensing terms.

# 用于AI中间训练的对齐安全数据集(Aligned Safety Data for AI Midtraining) 本数据集为经过精选的语料库,包含10000份教育类文档,从分析、历史与教育视角探讨种族主义(racism)、纳粹主义(nazism)、性别歧视(sexism)等有害议题。其设计初衷是用于大语言模型(Large Language Model)的持续预训练(中间训练,midtraining),以实现结构化对齐嵌入。 ## 数据集说明 本数据集包含从教育类网页内容中提取的非结构化自然散文文本。所有文档均明确谴责有害意识形态,或从历史学、社会学与伦理学视角对其展开分析。 ### 核心特性 - **10000份文档**,覆盖15个目标主题且分布均衡 - **教育质量基线**:所有文档的fineweb-edu评分均不低于3 - **分层锚点过滤**:要求包含明确的谴责性表述 - **主题优先级校验**:目标术语必须为文档核心主题,而非偶然提及的内容 ## 目标主题 | 类别 | 主题 | |----------|--------| | 核心意识形态 | 种族主义(racism)、纳粹主义(nazism)、性别歧视(sexism)、厌女症(misogyny)、反犹主义(antisemitism)、白人至上主义(white supremacy) | | 历史术语 | 大屠杀(holocaust)、种族隔离(segregation)、希特勒(hitler)、纳粹(nazi)、法西斯主义(fascism)、种族隔离制度(apartheid) | | 现代概念 | 种族清洗(ethnic cleansing)、种族灭绝(genocide)、仇恨言论(hate speech) | ## 样本分布 | 核心目标主题 | 样本数量 | | 核心目标主题 | 样本数量 | |----------------|-------|-|----------------|-------| | 种族主义(racism) | 700 | | 纳粹(nazi) | 700 | | 性别歧视(sexism) | 700 | | 法西斯主义(fascism) | 700 | | 反犹主义(antisemitism) | 700 | | 种族隔离制度(apartheid) | 700 | | 白人至上主义(white supremacy) | 700 | | 种族清洗(ethnic cleansing) | 700 | | 大屠杀(holocaust) | 700 | | 种族灭绝(genocide) | 700 | | 种族隔离(segregation) | 700 | | 仇恨言论(hate speech) | 700 | | 希特勒(hitler) | 700 | | 厌女症(misogyny) | 556 | | 纳粹主义(nazism) | 344 | | | | ## 过滤方法 ### 强锚点(谴责性表述) 文档必须至少包含以下任一表述: - 谴责、暴行、受害者、迫害、不公 - 仇恨犯罪、不道德、悲剧性、破坏性影响 - 抗击、根除、骇人听闻、反人类罪、压迫 ### 弱锚点(教育语境) 文档必须至少包含两个锚点,其中需涵盖以下至少一组词汇: - 公民权利、人权、纽伦堡审判(nuremberg)、立法 - 歧视、系统性、偏见、被边缘化群体 - 历史的、运动、被废除、解放 - 平等、正义、纪念、缅怀 ## 数据结构 json { "text": "完整文档文本...", "url": "来源URL", "score": 3.5, "matched_targets": ["大屠杀(holocaust)", "纳粹(nazi)"], "primary_target": "大屠杀(holocaust)", "matched_strong_anchors": ["受害者", "迫害"], "matched_weak_anchors": ["历史的", "歧视"] } ## 数据文件 | 文件名称 | 描述 | |------|-------------| | `aligned_docs_sample.jsonl` | 采用JSON Lines格式存储的10000份文档 | | `aligned_docs_sample.parquet` | 采用Parquet格式存储的同款数据,便于高效加载 | | `retrieval_stats.json` | 详细的检索统计信息 | ## 使用示例 python from datasets import load_dataset # 加载数据集 dataset = load_dataset("massines3a/aligned-safety-data") # 访问文档 for doc in dataset["train"]: print(doc["primary_target"], doc["text"][:200]) ## 数据来源 本数据集从[HuggingFaceFW/fineweb-edu](https://huggingface.co/datasets/HuggingFaceFW/fineweb-edu)提取,通过共现过滤与教育质量阈值筛选得到。 ## 统计信息 - **扫描文档总数**:9240万 - **检索得到有效文档数**:10000 - **检索率**:0.01% - **高频强锚点**:受害者(3939次)、压迫(2435次)、迫害(2190次) - **高频弱锚点**:运动(5466次)、正义(4593次)、历史的(4592次) ## 适用场景 本数据集适用于: - 大语言模型的中间训练/持续预训练 - AI安全对齐研究 - 教育内容分析 **禁止使用场景**:微调对话模型、生成有害内容。 ## 许可协议 本数据集沿用源数据集fineweb-edu的许可协议,具体条款请参阅原始数据集。

提供机构:
massines3a
二维码
社区交流群
二维码
科研交流群
商业服务