Actualiser conf/default.yaml
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
# =====================================================================
|
# =====================================================================
|
||||||
# CONFIGURATION PRESIDIO - Minimal Full Working
|
# CONFIGURATION PRESIDIO - v.1
|
||||||
# =====================================================================
|
# =====================================================================
|
||||||
supported_languages: [en, fr]
|
supported_languages: [en, fr]
|
||||||
|
|
||||||
@@ -31,6 +31,7 @@ nlp_configuration:
|
|||||||
recognizer_registry:
|
recognizer_registry:
|
||||||
load_predefined_recognizers: true
|
load_predefined_recognizers: true
|
||||||
recognizers:
|
recognizers:
|
||||||
|
# --- Reconnaisseurs existants ---
|
||||||
- name: FlexibleDateRecognizer
|
- name: FlexibleDateRecognizer
|
||||||
supported_language: fr
|
supported_language: fr
|
||||||
supported_entity: FLEXIBLE_DATE
|
supported_entity: FLEXIBLE_DATE
|
||||||
@@ -139,6 +140,38 @@ recognizer_registry:
|
|||||||
score: 0.9
|
score: 0.9
|
||||||
# contexte volontairement omis pour meilleure détection
|
# contexte volontairement omis pour meilleure détection
|
||||||
|
|
||||||
|
# --- NOUVEAUX RECONNAISSEURS AJOUTÉS ---
|
||||||
|
- name: CreditCardRecognizer
|
||||||
|
supported_language: fr
|
||||||
|
supported_entity: CREDIT_CARD_NUMBER
|
||||||
|
patterns:
|
||||||
|
- name: Numéro de carte de crédit (15-16 chiffres)
|
||||||
|
# Gère les formats avec ou sans espaces/tirets
|
||||||
|
regex: "\\b(?:\\d{4}[-\\s]?\\d{4}[-\\s]?\\d{4}[-\\s]?\\d{3,4})\\b"
|
||||||
|
score: 1.0
|
||||||
|
context: ["carte bancaire", "carte de crédit", "numéro de carte", "CB", "visa", "mastercard"]
|
||||||
|
|
||||||
|
- name: PasswordRecognizer
|
||||||
|
supported_language: fr
|
||||||
|
supported_entity: PASSWORD
|
||||||
|
patterns:
|
||||||
|
- name: Mot de passe potentiel (contexte requis)
|
||||||
|
# Détecte une chaîne de 8 à 32 caractères avec des lettres, chiffres et symboles courants.
|
||||||
|
# La détection repose fortement sur les mots-clés du contexte.
|
||||||
|
regex: "\\b[a-zA-Z0-9!@#$%^&*()\\-_=+]{8,32}\\b"
|
||||||
|
score: 0.4 # Score faible car le pattern est générique, le contexte est clé.
|
||||||
|
context: ["mot de passe", "password", "mdp", "code secret"]
|
||||||
|
|
||||||
|
- name: FrenchPostalCodeRecognizer
|
||||||
|
supported_language: fr
|
||||||
|
supported_entity: FR_POSTAL_CODE
|
||||||
|
patterns:
|
||||||
|
- name: Code Postal Français (5 chiffres)
|
||||||
|
regex: "\\b(?!00000)\\d{5}\\b"
|
||||||
|
score: 0.7
|
||||||
|
context: ["code postal", "cedex", "CP"]
|
||||||
|
|
||||||
|
|
||||||
allow_list:
|
allow_list:
|
||||||
- Adresse
|
- Adresse
|
||||||
- ADRESSE
|
- ADRESSE
|
||||||
@@ -208,6 +241,9 @@ anonymizer_config:
|
|||||||
BE_ADDRESS: replace
|
BE_ADDRESS: replace
|
||||||
BE_PRO_ID: replace
|
BE_PRO_ID: replace
|
||||||
IP_ADDRESS: replace
|
IP_ADDRESS: replace
|
||||||
|
CREDIT_CARD_NUMBER: replace
|
||||||
|
PASSWORD: replace
|
||||||
|
FR_POSTAL_CODE: replace
|
||||||
|
|
||||||
replacements:
|
replacements:
|
||||||
PERSON: "<PERSONNE>"
|
PERSON: "<PERSONNE>"
|
||||||
@@ -225,3 +261,6 @@ anonymizer_config:
|
|||||||
BE_ADDRESS: "<ADRESSE_BELGE>"
|
BE_ADDRESS: "<ADRESSE_BELGE>"
|
||||||
BE_PRO_ID: "<ID_PROFESSIONNEL>"
|
BE_PRO_ID: "<ID_PROFESSIONNEL>"
|
||||||
IP_ADDRESS: "<ADRESSE_IP>"
|
IP_ADDRESS: "<ADRESSE_IP>"
|
||||||
|
CREDIT_CARD_NUMBER: "<CARTE_BANCAIRE>"
|
||||||
|
PASSWORD: "<MOT_DE_PASSE>"
|
||||||
|
FR_POSTAL_CODE: "<CODE_POSTAL_FR>"
|
||||||
Reference in New Issue
Block a user