MultiNLI - Multi-Genre Natural Language Inference
Natural language inference across multiple genres of text, based on the Multi-Genre NLI corpus (Williams et al., NAACL 2018). Annotators classify premise-hypothesis relationships with genre-diverse examples from fiction, government, travel, and more.
ملف الإعدادconfig.yaml
# MultiNLI - Multi-Genre Natural Language Inference
# Based on Williams et al., NAACL 2018
# Paper: https://aclanthology.org/N18-1101/
# Dataset: https://cims.nyu.edu/~sbowman/multinli/
#
# This task presents premise-hypothesis pairs drawn from multiple genres
# of text including fiction, government reports, travel guides, and more.
# Annotators classify the inferential relationship as entailment,
# contradiction, or neutral, and provide reasoning.
#
# Genres include: fiction, government, telephone, travel, slate,
# letters, oup, verbatim, nineeleven, facetoface
#
# Annotation Guidelines:
# 1. Note the genre of the text for context
# 2. Read the premise sentence carefully
# 3. Read the hypothesis sentence
# 4. Determine the relationship between them
# 5. Provide a brief reasoning for your choice
annotation_task_name: "MultiNLI - Multi-Genre Natural Language Inference"
task_dir: "."
data_files:
- sample-data.json
item_properties:
id_key: "id"
text_key: "text"
output_annotation_dir: "annotation_output/"
output_annotation_format: "json"
port: 8000
server_name: localhost
annotation_schemes:
# Step 1: Classify the relationship
- annotation_type: radio
name: nli_label
description: "What is the inferential relationship between the premise and hypothesis?"
labels:
- "Entailment"
- "Contradiction"
- "Neutral"
keyboard_shortcuts:
"Entailment": "1"
"Contradiction": "2"
"Neutral": "3"
tooltips:
"Entailment": "The hypothesis is definitely true given the premise"
"Contradiction": "The hypothesis is definitely false given the premise"
"Neutral": "The hypothesis may or may not be true given the premise"
# Step 2: Provide reasoning
- annotation_type: text
name: reasoning
description: "Briefly explain your reasoning for the chosen label"
annotation_instructions: |
You will be shown a premise and hypothesis from a specific text genre. Your task is to:
1. Note the genre label for context about the writing style.
2. Determine the relationship between the premise and the hypothesis.
3. Select one of: Entailment, Contradiction, or Neutral.
4. Provide a brief explanation for your choice.
- Entailment: If the premise is true, the hypothesis must also be true.
- Contradiction: If the premise is true, the hypothesis must be false.
- Neutral: The premise does not give enough information to determine if the hypothesis is true or false.
html_layout: |
<div style="padding: 15px; max-width: 800px; margin: auto;">
<div style="background: #f3e8ff; border: 1px solid #d8b4fe; border-radius: 8px; padding: 10px 16px; margin-bottom: 12px; display: inline-block;">
<strong style="color: #7c3aed; font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px;">Genre:</strong>
<span style="font-size: 14px; color: #6d28d9; font-weight: 500; margin-left: 4px;">{{genre}}</span>
</div>
<div style="background: #f0f9ff; border: 1px solid #bae6fd; border-radius: 8px; padding: 16px; margin-bottom: 16px;">
<strong style="color: #0369a1; font-size: 14px; text-transform: uppercase; letter-spacing: 0.5px;">Premise:</strong>
<p style="font-size: 16px; line-height: 1.7; margin: 8px 0 0 0;">{{text}}</p>
</div>
<div style="background: #fefce8; border: 1px solid #fde68a; border-radius: 8px; padding: 16px; margin-bottom: 16px;">
<strong style="color: #a16207; font-size: 14px; text-transform: uppercase; letter-spacing: 0.5px;">Hypothesis:</strong>
<p style="font-size: 16px; line-height: 1.7; margin: 8px 0 0 0;">{{hypothesis}}</p>
</div>
</div>
allow_all_users: true
instances_per_annotator: 50
annotation_per_instance: 2
allow_skip: true
skip_reason_required: false
بيانات نموذجيةsample-data.json
[
{
"id": "multinli_001",
"text": "The old man turned the corner and disappeared into the fog, his coat flapping behind him like the wings of a wounded bird.",
"hypothesis": "A man walked away.",
"genre": "fiction"
},
{
"id": "multinli_002",
"text": "The Commission's final report recommended sweeping changes to the existing regulatory framework, including increased oversight of financial institutions.",
"hypothesis": "The Commission suggested keeping everything the same.",
"genre": "government"
}
]
// ... and 8 more itemsاحصل على هذا التصميم
Clone or download from the repository
بدء سريع:
git clone https://github.com/davidjurgens/potato-showcase.git cd potato-showcase/text/natural-language-inference/multinli-genre-nli potato start config.yaml
التفاصيل
أنواع التوسيم
المجال
حالات الاستخدام
الوسوم
وجدت مشكلة أو تريد تحسين هذا التصميم؟
افتح مشكلةتصاميم ذات صلة
Safe Biomedical NLI
Safe biomedical natural language inference task requiring annotators to determine entailment or contradiction between clinical premise-hypothesis pairs and provide reasoning. Based on SemEval-2024 Task 2 (Safe Biomedical NLI).
SNLI - Textual Entailment
Natural language inference over sentence pairs from the Stanford Natural Language Inference corpus (Bowman et al., EMNLP 2015). Annotators classify the relationship between a premise and hypothesis as entailment, contradiction, or neutral.
Argument Reasoning in Civil Procedure
Legal argument reasoning task requiring annotators to answer multiple-choice questions about civil procedure by selecting the best answer and providing legal reasoning. Based on SemEval-2024 Task 5.