/ Модель

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

Лицензия
MIT
Базовая модель
deberta-v3-base-zeroshot-v2.0
Опубликована
11 ноя 2026

deberta-v3-news-scope-nli

Классификация без дообученияТекст → label3 профессии

Англоязычная модель DeBERTa-v3 для определения тематики новостных текстов и разделения новостей о компаниях на материалы об одной или нескольких компаниях.

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

Бенчмарки

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

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

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

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

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

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

gamug разработал эту англоязычную модель для первого шага новостного конвейера проекта gamug/portfolio-nlp. Это дообученная на базе MoritzLaurer/deberta-v3-base-zeroshot-v2.0 модель DeBERTa-v3 для классификации по заданным категориям без отдельного набора обучающих примеров при каждом запуске. В репозитории находятся две стадии: первая различает новости о компании, секторе и нерелевантные материалы; вторая делит новости о компании на материалы об одной или нескольких компаниях. Для классификации используются заголовок и первые 800 символов текста.

Модель обучена на 365 размеченных новостных текстах. На отложенной выборке из 200 текстов согласие с разметкой составило 83,6%; полнота для класса single — 92,2%, а для out_of_scope — 53,0%. Модель предназначена для англоязычных новостей за 2022–2026 годы и не проверялась на других источниках или языках. Около половины материалов класса out_of_scope на проверке ошибочно продолжали конвейер; порог качества проекта в 90% не достигнут. Веса доступны в формате safetensors, лицензия — MIT.

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

  • отбор англоязычных новостей о компаниях из новостного потока
  • разделение новостей о компании и отрасли
  • определение нерелевантных новостных материалов
  • разметка новостей как относящихся к одной или нескольким компаниям

Ограничения

Слабее всего распознаётся класс out_of_scope: полнота на отложенной выборке составила 53%, а порог качества проекта в 90% не достигнут. Проверена только на англоязычных новостях за 2022–2026 годы; результаты ограничены одной обучающей выборкой и могут быть оптимистичны из-за решений, принятых при анализе той же отложенной выборки.

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

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

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

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

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

Открыть на Hugging Face

deberta-v3-news-scope-nli

What it is for. Step 1 of the news pipeline of gamug/portfolio-nlp (PLAN D39/D40): the scope of a news body from its title and its first 800 characters, in four classes: single (one company is the subject), multi (several companies are cut apart later), sector (about a sector, not a company) and out_of_scope (neither; the pipeline stops there).

Two models, one repository. Both are MoritzLaurer/deberta-v3-base-zeroshot-v2.0@8e7e5af5983a0ddb1a5b45a38b129ab69e2258e8 fine-tuned as an NLI (entailment margin of a hypothesis):

  • stage_a/: company / sector / not_related, for every body.
  • stage_b/: single / multi, asked only of the bodies stage A calls company. The hypotheses, the recipe and the data counts are in training_record.json. The step revision stored with every result (body_scope.classifier_revision) is scope-nli-8ff21e50796b: the hash of that record and of the weight files.

How it was trained

365 bodies tagged and reviewed by the project owner (284 + 51 chosen for the rare scopes + 30 whose title names a company but whose body is not about it): stage A on all, stage B on the 210 company bodies. Title + first 800 characters, 3 epochs, learning rate 2e-5, batch 16, float32 weights with bf16 autocast, seed 1. The texts are in the project repository (gold/), not here. Recipe and the story of the choices: docs/scope_training.md.

Figures

Held-out 200 bodies the model never trained on, weighted to the corpus by the draw's strata, scored from these weights through the step's own classifier (scripts/score_scope_heldout_2026_11_11.py): agreement 83.6% [78.1, 88.9] (rules triage 67.2%; paired gain +16.5 [+9.6, +23.4] points); single recall 92.2%, out_of_scope recall 53.0% [32.3, 73.8]. Three fits of this recipe (seed 1) scored 83.0%, 83.6% and 83.6%; this is one seed and not a noise estimate.

Limits (read before use)

  • out_of_scope is the weak class. In the held-out 200, about half of the out-of-scope bodies are read as single or multi and continue in the pipeline; the owner accepted this on purpose (a body wrongly kept costs a review, a body wrongly stopped is lost). How many bodies continue in the corpus is not known. An estimate from a 1,000-body sample said about 6.7% of all bodies, but over the 309,972 unique bodies of the corpus the model calls 49% out_of_scope: 11% of the ok bodies and 59% of the quarantined ones (those pairs are 79% of the corpus). A read of 50 of the latter found most not about a company, a few with a company hook and two clear errors. The held-out gold may not represent the quarantined bodies.
  • The 90% bar of the project (D20/D33) is not met; the owner accepted the model below it (PLAN D40 amendment).
  • sector has 7 gold bodies in the held-out 200: its recall is reported, not gated.
  • The figure is optimistic: several design choices were made while looking at the same 200 bodies (docs, section 6). One seed.
  • English news, 2022 to 2026, title plus 800 characters; bodies without a title are read from the text alone. Not tested on other sources or on bodies written in other languages.

Use

No token is needed. The function below is the whole classifier.

import json, torch
from huggingface_hub import snapshot_download
from transformers import AutoModelForSequenceClassification, AutoTokenizer

root = snapshot_download("gamug/deberta-v3-news-scope-nli")
rec = json.load(open(f"{root}/training_record.json"))
tok = AutoTokenizer.from_pretrained(f"{root}/stage_a")
A = AutoModelForSequenceClassification.from_pretrained(f"{root}/stage_a").eval()
B = AutoModelForSequenceClassification.from_pretrained(f"{root}/stage_b").eval()

def margins(model, text, stage):
    out = {}
    for name, hypothesis in rec[stage]["hypotheses"].items():
        x = tok(text, hypothesis, truncation="only_first", max_length=rec[stage]["recipe"]["max_length"], return_tensors="pt")
        with torch.no_grad():
            logits = model(**x).logits[0].float()
        out[name] = (logits[0] - logits[1]).item()   # entailment minus not-entailment
    return out

def scope(title, body):
    text = f"{title}. {body[:rec['fragment_chars']]}"
    a = margins(A, text, "stage_a")
    topic = max(rec["stage_a"]["topics"], key=a.get)
    if topic != "company":
        return "sector" if topic == "sector" else "out_of_scope"
    b = margins(B, text, "stage_b")
    return max(rec["stage_b"]["classes"], key=b.get)   # "single" or "multi"

print(scope("Apple shares fall", "Apple Inc. said on Tuesday that iPhone sales were weaker than expected."))

The same logic, batched and on the GPU, is src/scope_stage.py of the project repository (gamug/portfolio-nlp); the example above does not need it.

History

The first upload (commit 5f5b2c27) did not contain the weights because of a script error; use the latest commit, the one the project's config/scope_model.json names.

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

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

GPU в ailist

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

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

Не удалось определить, чем загружать веса модели (нет library_name и architectures).

Ревизия весов
58e4af4

0 моделей