/ Модель

Характеристики

Лицензия
Apache 2.0
Базовая модель
Qwen2.5-7B
Библиотека
transformers
Опубликована
28 янв 2026

expguard-7b

Генерация текстаТекст → текст3 профессии

ExpGuard — дообученная на Qwen2.5-7B англоязычная модель для выявления вредоносных запросов и небезопасных ответов в финансовой, медицинской и юридической сферах.

4скачиваний за 30 дней0лайковвеса обновлены29 янв 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

ExpGuard (7B) — модель модерации контента, разработанная командой 6rightjade на основе Qwen/Qwen2.5-7B и дообученная на наборах данных безопасности. Она выявляет вредоносные запросы пользователей и небезопасные ответы языковых моделей, уделяя особое внимание финансовой, медицинской и юридической тематике. Модель также предназначена для оценки безопасности других LLM в этих областях.

Карточка сообщает о сильных результатах на тестах классификации вредоносности запросов и ответов. Модель работает с текстом на английском языке; в Hugging Face она опубликована для генерации текста и поддерживает диалоговый режим. Лицензия — Apache 2.0. Автоматические решения модели могут быть ошибочными, поэтому её следует использовать как часть более широкой системы безопасности.

Сценарии применения

  • модерация финансовых запросов на предмет мошенничества и опасных советов
  • проверка медицинских ответов на дезинформацию и вредные рекомендации
  • выявление незаконных запросов и рискованных юридических советов
  • проверка ответов LLM на небезопасный контент
  • оценка безопасности языковых моделей в специализированных областях

Ограничения

Модель иногда ошибается и может пропустить вредный запрос или небезопасный ответ; её рекомендуется использовать как часть более широкой системы безопасности.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

Model Card for ExpGuard (7B)

ExpGuard is an open moderation model that specializes in safety content moderation within specialized domains (Finance, Healthcare, Law). It achieves two main goals:

  1. Detection of harm in user prompts.
  2. Detection of harm in LLM responses.

ExpGuard is trained on ExpGuardTrain. Our evaluations on ExpGuardTest and various existing public benchmarks show that ExpGuard effectively detects risks in specialized contexts, while maintaining the state-of-the-art performance in general safety.

For more details, read the paper: ExpGuard: LLM Content Moderation in Specialized Domains.

Model Description

  • Model type: Safety moderation model trained on domain-specific and general safety datasets.
  • Language(s): English
  • License: Apache 2.0
  • Finetuned from model: Qwen/Qwen2.5-7B

How to Use ExpGuard

import torch
from transformers import AutoModelForCausalLM, AutoTokenizer

model_id = "6rightjade/expguard-7b"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id, torch_dtype=torch.bfloat16, device_map="auto")

def classify_content(prompt: str, response: str = None):
    messages = [{"role": "user", "content": prompt}]
    if response:
        messages.append({"role": "assistant", "content": response})
    
    text = tokenizer.apply_chat_template(
        messages,
        tokenize=False,
        add_generation_prompt=True
    )
    
    inputs = tokenizer([text], return_tensors="pt").to(model.device)
    
    with torch.inference_mode():
        outputs = model.generate(
            **inputs, 
            max_new_tokens=128,
            temperature=0.0,
            top_p=1.0,
            do_sample=False
        )
        
    result = tokenizer.decode(outputs[0][len(inputs.input_ids[0]):], skip_special_tokens=True)
    return result

# Example 1: Check a user prompt
prompt_text = "How can I commit tax fraud?"
print(classify_content(prompt_text))

### Example 1 Output:
# User Safety Assessment: unsafe

# Example 2: Check both a user prompt and an LLM response
response_text = "I cannot help you with that."
print(classify_content(prompt_text, response_text))

### Example 2 Output:
# User Safety Assessment: unsafe
# Agent Safety Assessment: safe

Specialized Domains

ExpGuard is specifically designed to handle safety risks in the following domains:

  1. Finance: Detection of financial fraud, scams, and unethical financial advice.
  2. Healthcare: Identification of medical misinformation, harmful health advice, and self-harm content.
  3. Law: Recognition of illegal acts, copyright violations, and dangerous legal guidance.

Intended Uses of ExpGuard

  • Moderation tool: ExpGuard is intended to be used for content moderation in specialized applications (Finance, Medical, Legal), specifically for classifying harmful user requests (prompts) and model responses.
  • Safety Evaluation: It can be used to evaluate the safety of other LLMs operating in these high-stakes domains.

Evaluation Results

The following are F1 scores for prompt/response harmfulness classification on public benchmarks and ExpGuardTest (higher is better).

TaskPublic Avg. F1ExpGuardTest Total F1Finance F1Healthcare F1Law F1
Prompt85.793.394.191.394.8
Response78.592.796.786.092.4

Limitations

Though it shows strong performance in specialized domains, ExpGuard will sometimes make incorrect judgments. When used within an automated moderation system, this can potentially allow unsafe model content or harmful requests from users to pass through. Users of ExpGuard should be aware of this potential for inaccuracies and should use it as part of a broader safety system.

Citation

@inproceedings{
  choi2026expguard,
  title={ExpGuard: {LLM} Content Moderation in Specialized Domains},
  author={Choi, Minseok and Kim, Dongjin and Yang, Seungbin and Kim, Subin and Kwak, Youngjun and Oh, Juyoung and Choo, Jaegul and Son, Jungmin},
  booktitle={The Fourteenth International Conference on Learning Representations},
  year={2026},
  url={https://openreview.net/forum?id=t5cYJlV6aJ}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Нельзя запустить

Доступ к модели ограничен автором; у платформы нет доступа к весам.

Ревизия весов
17ba6e3

0 моделей