/ Модель

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

Контекст
7 999 токенов
Параметры
68,1 млн
Лицензия
MIT
Архитектура
modernbert · dense
Базовая модель
ettin-encoder-68m
Библиотека
transformers
Опубликована
6 мая 2026

ettin-68m-nemotron-pii

Разметка токеновТекст → label5 профессий

Компактная англоязычная модель ModernBERT для выделения более 50 типов персональных данных в тексте.

3 651скачиваний за 30 дней8лайковвеса обновлены22 мая 2026

Бенчмарки

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

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

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

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

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

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

ettin-68m-nemotron-pii — компактная модель для обнаружения и разметки персональных данных в тексте. Она основана на энкодере Ettin-68M от JHU CLSP и дообучена на наборе данных NVIDIA Nemotron-PII; архитектура — ModernBERT для классификации токенов, размер — 68,1 млн параметров, максимальная длина контекста — 7 999 токенов.

Модель выделяет более 50 типов PII в структурированном и неструктурированном английском тексте, включая номера счетов, даты рождения и API-ключи. Её можно применять для поиска чувствительных данных в документах и подготовки текстов к обезличиванию в медицинских, финансовых, юридических и других сценариях. В карточке приведён результат F1 96,27 на тестовой выборке из 10 тысяч примеров Nemotron-PII; точность и полнота составили 96,35 и 96,19 соответственно. Показатели различаются по типам сущностей: например, для профессий F1 заметно ниже.

Модель принимает текст и возвращает метки сущностей на уровне токенов. Она рассчитана на английский язык и может хуже работать на других языках; качество также зависит от типа PII. Лицензия — MIT.

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

  • поиск персональных данных в документах
  • обнаружение API-ключей и учетных данных в текстах
  • выявление чувствительной информации в медицинских записях
  • поиск PII в финансовых и юридических документах
  • разметка сущностей для последующего обезличивания текста

Ограничения

Модель хорошо работает только с английским текстом. Качество ниже для некоторых типов сущностей, например профессий.

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

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

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

Также подходит для

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

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

Открыть на Hugging Face

ettin-68m-nemotron-pii model

Light Weight PII Detection Model | Open Source | 68M Parameters | 96.27 F1 Score | Blog Post

Overview

Ettin-68m-nemotron-pii is based on the ettin-encoder-68M model and fine-tuned over the Nemotron PII dataset. This model can detect 50+ PII entities in both structured and unstructured texts across various domains like healthcare, finance, legal, cybersecurity etc. With just 68M parameters, the model achieves a strong F1-score of 96.27.

Key Features

  • Achieves strong F1-score of 96.27 with just 68M parameters.
  • Outperforms popular LLMs like DeepSeek-V4-Flash (84.89) and GPT-4o-Mini (78.69).
  • Detects 50+ PII entities in both structured and unstructured texts.
  • Handles text in various domains like healthcare, finance, legal etc.

Model Visualization

Supported PII Entity Types

This model can detect the following 55 PII entity types

EntityDescription
account_numberAccount Number
ageAge
api_keyAPI Key
bank_routing_numberBank Routing Number
biometric_identifierBiometric Identifier
blood_typeBlood Type
certificate_license_numberCertificate or License Number
cityCity
company_nameCompany Name
coordinateGeographic Coordinate
countryCountry
countyCounty
credit_debit_cardCredit or Debit Card Number
customer_idCustomer ID
cvvCard Verification Value (CVV)
dateDate
date_of_birthDate of Birth
date_timeDate and Time
device_identifierDevice Identifier
education_levelEducation Level
emailEmail Address
employee_idEmployee ID
employment_statusEmployment Status
fax_numberFax Number
first_nameFirst Name
genderGender
health_plan_beneficiary_numberHealth Plan Beneficiary Number
http_cookieHTTP Cookie
ipv4IPv4 Address
ipv6IPv6 Address
languageLanguage
last_nameLast Name
license_plateVehicle License Plate
mac_addressMAC Address
medical_record_numberMedical Record Number
national_idNational Identification Number
occupationOccupation
passwordPassword
phone_numberPhone Number
pinPersonal Identification Number (PIN)
political_viewPolitical View
postcodePostcode / Zip Code
race_ethnicityRace or Ethnicity
religious_beliefReligious Belief
sexualitySexuality / Sexual Orientation
ssnSocial Security Number
stateState
street_addressStreet Address
swift_bicSWIFT / BIC Code
tax_idTax Identification Number
timeTime
unique_idUnique Identifier
urlURL / Web Address
user_nameUsername
vehicle_identifierVehicle Identification Number (VIN)

Usage


# First install Hugging Face transformers library
!pip install transformers

# Initialize and run the PII detection pipeline to extract PII entities
from transformers import pipeline

## Initialize the PII detection pipeline
ner = pipeline("ner", model="kalyan-ks/ettin-68m-nemotron-pii", aggregation_strategy="simple")

input_text = "Kalyan KS is from India. His email id is kalyan.ks@yahoo.com"

## Run the PII detection to extract PII entities
pii_entities = ner(input_text)

## Process the extracted PII entities 
def format_pii_entities(entities, original_text):
    if not entities:
        return []

    merged_entities = []

    entities = sorted(entities, key=lambda x: x['start'])

    current_entity = {
        'start': entities[0]['start'],
        'end': entities[0]['end'],
        'label': entities[0]['entity_group'],
        'text': entities[0]['word']
    }

    for next_ent in entities[1:]:
        is_same_label = next_ent['entity_group'] == current_entity['label']
        is_adjacent = next_ent['start'] <= current_entity['end'] + 1

        if is_same_label and is_adjacent:
            current_entity['end'] = max(current_entity['end'], next_ent['end'])
            current_entity['text'] = original_text[current_entity['start']:current_entity['end']]
        else:
            merged_entities.append(clean_entity(current_entity))
            current_entity = {
                'start': next_ent['start'],
                'end': next_ent['end'],
                'label': next_ent['entity_group'],
                'text': next_ent['word']
            }

    merged_entities.append(clean_entity(current_entity))
    return merged_entities

def clean_entity(ent):

    raw_text = ent['text']
    stripped_text = raw_text.strip()
    leading_spaces = len(raw_text) - len(raw_text.lstrip())

    return {
        'start': ent['start'] + leading_spaces,
        'end': ent['start'] + leading_spaces + len(stripped_text),
        'text': stripped_text,
        'label': ent['label']
    }

# Display the extracted PII entities
formatted_entities = format_pii_entities(pii_entities, input_text)
print(formatted_entities)

# Output
[{'start': 0, 'end': 9, 'text': 'Kalyan KS', 'label': 'first_name'}, {'start': 18, 'end': 23, 'text': 'India', 'label': 'country'}, {'start': 41, 'end': 60, 'text': 'kalyan.ks@yahoo.com', 'label': 'email'}]

Evaluation

This model is evaluated on a 10k sample test set from Neomotron PII dataset and achieved the following results

MetricScore
F196.27
Precision96.35
Recall96.19
Accuracy99.26

Top Performing PII Entity Types

EntityPrecisionRecallF1
biometric_identifier0.99630.99660.9964
date_of_birth0.99520.99630.9957
api_key0.99320.99780.9955
mac_address0.99290.99650.9947
email0.99420.99420.9942
ipv40.99500.99330.9941
medical_record_number0.99520.99040.9928
health_plan_beneficiary_number0.99240.99250.9924
vehicle_identifier0.98670.99770.9922
bank_routing_number0.99670.98620.9914

Challenging PII Entity Types

EntityPrecisionRecallF1
occupation0.72000.54930.6232
time0.80940.77810.7934
age0.83330.92730.8778
political_view0.85330.92470.8876
state0.90770.87920.8932
fax_number0.90470.90130.9030
company_name0.90480.90720.9060
national_id0.89950.92240.9108
education_level0.92690.89730.9118
race_ethnicity0.90270.93880.9204

Limitations

  • Language: This model works well only for English language texts.
  • Challenging PII Entity Types: Some of the entity types like occupation has low F1 score.

Citation

@misc{ettin-68m-pii-2026,
  title = {ettin-68m-nemotron-pii-2026: PII Detection Model},
  author = {Kalyan KS},
  year = {2026},
  publisher = {Hugging Face},
  url = {https://huggingface.co/kalyan-ks/ettin-17m-nemotron-pii}
}

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

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

GPU в ailist

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

Можно запустить

Подбираем GPU…

Класс архитектуры
ModernBertForTokenClassification
Ревизия весов
500262a

0 моделей