CoolFace
Modelpublic

jamon8888/french-pii-legal-ner-base

sourceHugging Facemitupdated 5mo agoView on Hugging Face
0likes
Model Card

language: fr tags:

  • —gliner
  • —ner
  • —pii
  • —gdpr
  • —legal
  • —french license: apache-2.0 ---

🇫🇷 French Legal PII NER — GLiNER2 Base (Lightweight)

Lightweight fine-tuned GLiNER2 Base for French PII detection in legal documents. Optimized for laptop/edge deployment. GDPR & EU AI Act compliant.

Evaluation Results

ModelF1PrecisionRecall
This model (GLiNER2 Base, fine-tuned)0.5300.6120.528
GLiNER2 Base (no fine-tuning)0.4950.5770.472
GPT-4o0.8360.8630.844

Why use this over the Large version?

  • —✅ 4x smaller (~680 MB vs ~2.2 GB)
  • —✅ 3x faster on CPU
  • —✅ Only 2.5% F1 gap vs Large
  • —✅ Runs on any modern laptop with 8GB RAM

Supported Entity Types (33)

nom_personne, prenom, date_naissance, lieu_naissance, adresse, numero_telephone, email, numero_securite_sociale, numero_passeport, numero_carte_identite, numero_siret, organisation, tribunal, numero_affaire, avocat, notaire, juge, date, lieu, nationalite, profession, salaire, numero_compte_bancaire, plaque_immatriculation, donnee_sante, donnee_biometrique, donnee_genetique, opinion_politique, religion, origine_ethnique, orientation_sexuelle, condamnation_penale, base_legale_traitement

Usage

\\\bash pip install gliner \\\

\\\`python from gliner import GLiNER

model = GLiNER.frompretrained( "jamon8888/french-pii-legal-ner-base", basemodel="fastino/gliner2-base-v1" )

text = "M. Jean Dupont, né le 12/03/1985 à Paris, domicilié au 15 rue de la Paix..." labels = ["nompersonne", "datenaissance", "adresse", "donnee_sante"]

entities = model.predict_entities(text, labels, threshold=0.5) for entity in entities: print(f"{entity['label']}: {entity['text']}") \\\`

Training Details

  • —Base model: fastino/gliner2-base-v1
  • —Training examples: 995
  • —Epochs: 8
  • —Learning rate: 5e-5
  • —Document types: contrats, assignations, jugements, actes notariés, rapports médico-légaux, dossiers RH
  • —Trained with: Pioneer by Fastino Labs