SCM-7B / README.md
liyang-ict's picture
Upload README.md with huggingface_hub
e541d7b verified
---
license: apache-2.0
license_link: https://huggingface.co/Qwen/Qwen2.5-7B/blob/main/LICENSE
library_name: transformers
base_model: Qwen/Qwen2.5-7B
tags:
- safety
- content-moderation
- qwen2
- text-classification
- token-classification
---
# SCM-7B
Official SCM (Streaming Content Monitor) model based on [Qwen/Qwen2.5-7B](https://huggingface.co/Qwen/Qwen2.5-7B) for the NeurIPS 2025 paper:
> **"From Judgment to Interference: Early Stopping LLM Harmful Outputs via Streaming Content Monitoring"**
## Model Description
SCM-7B is a dual-task model that performs both **token-level** and **sequence-level** safety classification, training with a logic consistency loss to ensure coherence between the two tasks.
- **Base Model**: [Qwen/Qwen2.5-7B](https://huggingface.co/Qwen/Qwen2.5-7B)
- **Architecture**: `QwenForDualTask` (custom, based on `Qwen2PreTrainedModel`)
- **Parameters**: 7B
## Usage
```python
from transformers import AutoTokenizer, AutoModel
tokenizer = AutoTokenizer.from_pretrained("liyang-ict/SCM-7B")
model = AutoModel.from_pretrained("liyang-ict/SCM-7B", trust_remote_code=True)
```
## Citation
If you find this model useful, please cite our paper:
```bibtex
@article{li2025judgment,
title={From judgment to interference: Early stopping llm harmful outputs via streaming content monitoring},
author={Li, Yang and Sheng, Qiang and Yang, Yehan and Zhang, Xueyao and Cao, Juan},
journal={arXiv preprint arXiv:2506.09996},
year={2025}
}
```
## License
This model is released under the [Apache 2.0 License](https://www.apache.org/licenses/LICENSE-2.0), following the license of the base Qwen2.5 model.