Update default.yaml

This commit is contained in:
Nacim
2025-06-23 12:02:57 +02:00
committed by GitHub
parent 77fbaa230d
commit 9e534b2b46

View File

@@ -1,61 +1,181 @@
# Configuration NLP unifiée # =====================================================================
nlp_configuration: # CONFIGURATION PRESIDIO POUR DOCUMENTS FRANÇAIS/BELGES
nlp_engine_name: spacy # =====================================================================
models:
- lang_code: en
model_name: en_core_web_lg
- lang_code: fr
model_name: fr_core_news_sm
ner_model_configuration: # Configuration du moteur de langage (NLP)
model_to_presidio_entity_mapping: nlp_engine_name: spacy
PER: PERSON supported_languages: [en, fr]
PERSON: PERSON models:
ORG: ORGANIZATION - lang_code: en
ORGANIZATION: ORGANIZATION model_name: en_core_web_lg
LOC: LOCATION - lang_code: fr
LOCATION: LOCATION model_name: fr_core_news_sm
GPE: LOCATION
MISC: ORGANIZATION
confidence_threshold: # Configuration du comportement du moteur NLP
default: 0.35 ner_model_configuration:
EMAIL_ADDRESS: 0.4 labels_to_ignore:
PHONE_NUMBER: 0.5 - MISC
PERSON: 0.6
labels_to_ignore: confidence_threshold:
- MISC default: 0.6
- CARDINAL EMAIL_ADDRESS: 0.8
- EVENT PHONE_NUMBER: 0.8
- LANGUAGE PERSON: 0.85
- LAW LOCATION: 0.75
- MONEY MONEY: 0.85
- ORDINAL
- PERCENT
- PRODUCT
- QUANTITY
- WORK_OF_ART
# Configuration des langues supportées # Configuration des détecteurs (Recognizers)
supported_languages: # Ici, nous pointons directement vers le module Python que nous venons de créer.
- en # Presidio chargera tous les recognizers définis dans ce module.
- fr
# Configuration du registre
recognizer_registry: recognizer_registry:
- default - default # Charger les détecteurs par défaut de Presidio
- custom_recognizers # Référence au dossier/module Python 'custom_recognizers'
# Liste d'exclusion pour éviter les faux positifs # Liste des mots à ignorer (faux positifs courants)
allow_list: allow_list:
- Contrat # Termes contractuels/juridiques/financiers génériques souvent mal labellisés
- Document - text: Contrat
- Société type: LOCATION
- Montant - text: contrat
- Partie type: LOCATION
- Annexe - text: Contrats
- Euro type: LOCATION
- EUR - text: Document
- Taux type: LOCATION
- Valeur - text: document
- Prix type: LOCATION
- text: Société
type: PERSON
- text: Investisseur
type: PERSON
- text: Montant
type: LOCATION
- text: Prêt
type: LOCATION
- text: Intérêt
type: LOCATION
- text: Intérêts
type: LOCATION
- text: Partie
type: LOCATION
- text: Parties
type: PERSON
- text: Annexe
type: LOCATION
- text: Remboursement
type: LOCATION
- text: Conversion
type: LOCATION
- text: Financement
type: LOCATION
- text: Sortie
type: LOCATION
- text: "Juste Valeur Marchande"
type: PERSON
- text: Échéance
type: LOCATION
- text: Clause
type: LOCATION
- text: Clauses
type: LOCATION
- text: Principe
type: LOCATION
- text: Coûts
type: PERSON
- text: Notifications
type: LOCATION
- text: Article
type: LOCATION
- text: Paragraphe
type: LOCATION
- text: Directeur
type: LOCATION
- text: Gérant
type: LOCATION
- text: Président
type: LOCATION
- text: DocuSign
type: PERSON
- text: SPRL
type: ORG
# Termes financiers courants
- text: Euro
type: LOCATION
- text: EUR
type: LOCATION
- text: Euros
type: LOCATION
- text: Pourcentage
type: LOCATION
- text: Taux
type: LOCATION
- text: Valeur
type: LOCATION
- text: Prix
type: LOCATION
# Termes juridiques
- text: Loi
type: LOCATION
- text: Code
type: LOCATION
- text: Règlement
type: LOCATION
- text: Décret
type: LOCATION
- text: Arrêté
type: LOCATION
# Mois et dates génériques
- text: Janvier
type: LOCATION
- text: Février
type: LOCATION
- text: Mars
type: LOCATION
- text: Avril
type: LOCATION
- text: Mai
type: LOCATION
- text: Juin
type: LOCATION
- text: Juillet
type: LOCATION
- text: Août
type: LOCATION
- text: Septembre
type: LOCATION
- text: Octobre
type: LOCATION
- text: Novembre
type: LOCATION
- text: Décembre
# Configuration des transformations d'anonymisation
anonymizer_config:
default_anonymizers:
PERSON: replace
EMAIL_ADDRESS: replace
PHONE_NUMBER: replace
BE_NATIONAL_REGISTER_NUMBER: replace
BE_ENTERPRISE_NUMBER: replace
FR_SOCIAL_SECURITY_NUMBER: replace
IBAN: replace
BE_BANK_ACCOUNT: replace
MONEY: replace
LOCATION: replace
ORG: replace
replacements:
PERSON: "<PERSON>"
EMAIL_ADDRESS: "<EMAIL_ADDRESS>"
PHONE_NUMBER: "<PHONE_NUMBER>"
BE_NATIONAL_REGISTER_NUMBER: "<BE_NATIONAL_REGISTER_NUMBER>"
BE_ENTERPRISE_NUMBER: "<BE_ENTERPRISE_NUMBER>"
FR_SOCIAL_SECURITY_NUMBER: "<FR_SOCIAL_SECURITY_NUMBER>"
IBAN: "<IBAN>"
BE_BANK_ACCOUNT: "<COMPTE_BANCAIRE_BE>"
MONEY: "<MONEY>"
LOCATION: "<LOCATION>"
ORG: "<ORGANIZATION>"