File size: 3,009 Bytes
b254a57
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
---
license: cc-by-4.0
---

Sentence Frame Classifier
A RoBERTa-based model for detecting media frames at the sentence level. This model can classify sentences into 9 different frame categories and works across both news articles and reader comments.
Model Description
This model was trained to identify media frames in text at the sentence level. It's based on the Media Frame Corpus (Card et al., 2015) and extends to online discussion contexts, making it suitable for analyzing both professional journalism and user-generated content.
Key Features:

Sentence-level frame classification
Cross-domain capability (news articles + comments)
9 frame categories based on established political communication theory
Robust performance across different topics

Frame Categories
The model classifies sentences into these 9 frame categories:

Economic - Economic costs, benefits, or implications
Morality - Moral or ethical considerations
Fairness and Equality - Issues of fairness, equality, or discrimination
Legality and Crime - Legal aspects, constitutionality, crime, and punishment
Political and Policies - Political processes, policy prescriptions, and evaluations
Security and Defense - Security threats, defense, or public safety
Health and Safety - Health risks, safety concerns, or medical implications
Cultural Identity - Cultural values, traditions, or identity issues
Public Opinion - Public sentiment, polls, or popular support

Performance

Macro F1: 0.66
Accuracy: 0.77
Cross-topic generalization: Robust performance across different topics
Validation: Human-validated on 600 sentences

Usage
pythonfrom transformers import pipeline

# Load the classifier
classifier = pipeline("text-classification", model="your-username/sentence-frame-classifier")

# Classify a sentence
text = "The new policy will cost taxpayers millions of dollars while providing few benefits."
result = classifier(text)
print(result)
# Output: [{'label': 'Economic', 'score': 0.89}]

# Multiple examples
examples = [
    "This violates our constitutional rights and freedoms.",
    "The public strongly supports this initiative according to recent polls.",
    "We must protect our children from these dangerous substances."
]

for text in examples:
    result = classifier(text)
    print(f"Text: {text}")
    print(f"Frame: {result[0]['label']} (confidence: {result[0]['score']:.2f})")
    print()
Training Data
The model was trained on:

Media Frame Corpus (MFC): Professionally annotated news articles
Online Forum Data: Sentence-level annotations from online discussions
Total: 63,626 sentences across multiple topics

Citation
If you use this model in your research, please cite:


License
This model is released under the MIT License. You are free to use, modify, and distribute this model for any purpose, provided you include appropriate attribution.
Model Details

Model Type: Text Classification
Base Model: RoBERTa-large
Parameters: ~355M
Training Framework: Transformers
Inference Framework: Transformers Pipeline