CoolFace
Modelpublic

abullard1/germeval2025-c2a-moderngbert-cw

sourceHugging Faceopenrailupdated 1y agoView on Hugging Face
1likes11downloads
Model Card

<br> <br> <div style="text-align: center;"> <img src="https://i.ibb.co/RkR4QLpL/Shared-Task-Logo-Final-11zon.png" style="max-width: 30%; display: block; margin: 0 auto;"> </div>

<br> <br> <br>

<div style="text-align: center;"> <h1>๐Ÿ† GermEval 2025: Call to Action Detection (Class-Weighted)</h1> <a href="https://github.com/abullard1/abullardUR-GermEval-Shared-Task-2025"> <p><strong>abullardUR@GermEval Shared Task 2025 Submission</strong></p> </a> </div> <hr>

๐ŸŽฏ Model Summary

This model is a fine-tuned version of [LSX-UniWue/ModernGBERT_134M](https://huggingface.co/LSX-UniWue/ModernGBERT_134M), specifically designed for Call to Action (C2A) Detection in German social media content. It was developed as part of the GermEval 2025 Shared Task on Harmful Content Detection.

๐Ÿ… Competition Performance

  • โ€”Final Ranking: 4th out of 9 teams
  • โ€”Primary Metric (Macro-F1): 0.82 (+39% over official baseline (0.59 โ†’ 0.82))
  • โ€”Approach: Class-weighted cross-entropy loss to handle severe class imbalance (9.3:1 ratio)

๐Ÿ“Š Task Details

  • โ€”Task Type: Binary classification
  • โ€”Classes: False (no call to action), True (call to action detected)
  • โ€”Domain: German social media (Twitter, 2014-2016)
  • โ€”Data Source: Right-wing extremist network posts

โš ๏ธ Limitations and Bias

Known Limitations

  • โ€”Domain Specificity: Trained on 2014-2016 German Twitter data from right-wing extremist networks
  • โ€”Temporal Bias: Language patterns may not reflect contemporary usage
  • โ€”Class Imbalance: 90.3% negative vs 9.7% positive examples (9.3:1 ratio)
  • โ€”Cultural Context: May not generalize to other German-speaking regions or contexts
  • โ€”Implicit Context: May struggle with coded language and contextual references

Ethical Considerations

  • โ€”Model trained on potentially harmful content for research purposes only
  • โ€”Should not be used to amplify or generate harmful content
  • โ€”Requires careful handling due to sensitive training data

๐Ÿš€ How to Use

Quick Start

python
from transformers import AutoProcessor, AutoModelForSequenceClassification

# Load model and processor
model_id = "abullard1/germeval2025-c2a-moderngbert-cw"
processor = AutoProcessor.from_pretrained(model_id, trust_remote_code=True)
model = AutoModelForSequenceClassification.from_pretrained(model_id, trust_remote_code=True).eval()

# Run inference
text = "Kommt alle zur Demo am Samstag!"
inputs = processor(text, return_tensors="pt", truncation=True)
probs = model(**inputs).logits.softmax(-1).detach().cpu().numpy()
print(f"Predictions: {probs}")

Class Labels

  • โ€”Label 0: No call to action detected
  • โ€”Label 1: Call to action detected

๐Ÿ“ˆ Training Details

Training Data

  • โ€”Source: GermEval 2025 Shared Task C2A dataset
  • โ€”Size: 6,840 samples
  • โ€”Split: 80% training (5,472), 20% validation (1,368)
  • โ€”Class Distribution: 90.3% negative, 9.7% positive

Training Procedure

  • โ€”Base Model: ModernGBERT-134M (8192 token context)
  • โ€”Architecture: Mean-pooling classification head
  • โ€”Loss Function: Class-weighted cross-entropy (inverse frequency weighting)
  • โ€”Optimizer: AdamW with linear scheduling
  • โ€”Early Stopping: Patience of 5 epochs on validation Macro-F1

Hyperparameters

  • โ€”Learning Rate: 3e-5
  • โ€”Weight Decay: 0.0973
  • โ€”Batch Size: 8/32 (train/eval)
  • โ€”Epochs: 8
  • โ€”Warmup Steps: 500

๐Ÿ“š Citation

bibtex
@inproceedings{bullard2025germeval,
  title   = {abullardUR@GermEval Shared Task 2025: Fine-tuning ModernGBERT on Highly Imbalanced German Social Media for Harmful Content Detection},
  author  = {Bullard, Samuel},
  year    = {2025},
  booktitle = {Proceedings of KONVENS 2025 Workshops}
}

๐Ÿ™ Acknowledgments

  • โ€”GermEval 2025 Organizers: University of Stuttgart and University of Mannheim
  • โ€”Prof. Dr. Udo Kruschwitz (University of Regensburg) for supervision
  • โ€”ModernGBERT Team: LSX-UniWue for the ModernGBERT-134M German language base-model

๐Ÿ“„ License

This model inherits the Research-only RAIL-M license from ModernGBERT. See license details.