CoolFace
Modelpublic

AntoineBourgois/propp-fr_NER_camembert-large_FAC_GPE_LOC_PER_TIME_VEH

sourceHugging Faceapache-2.0updated 4mo agoView on Hugging Face
2likes
Model Card

language: fr tags:

  • —NER
  • —camembert
  • —literary-texts
  • —nested-entities
  • —BookNLP-fr license: apache-2.0 metrics:
  • —f1
  • —precision
  • —recall base_model:
  • —almanach/camembert-large pipeline_tag: token-classification ---

INTRODUCTION:

This model, developed as part of the propp-fr project, is a NER model built on top of camembert-large embeddings, trained to predict nested entities in french, specifically for literary texts.

The predicted entities are:

  • —mentions of characters (PER): pronouns (je, tu, il, ...), possessive pronouns (mon, ton, son, ...), common nouns (le capitaine, la princesse, ...) and proper nouns (Indiana Delmare, Honoré de Pardaillan, ...)
  • —facilities (FAC): chatêau, sentier, chambre, couloir, ...
  • —time (TIME): le règne de Louis XIV, ce matin, en juillet, ...
  • —geo-political entities (GPE): Montrouge, France, le petit hameau, ...
  • —locations (LOC): le sud, Mars, l'océan, le bois, ...
  • —vehicles (VEH): avion, voitures, calèche, vélos, ...

MODEL PERFORMANCES (LOOCV):

NER_tagprecisionrecallf1_scoresupportsupport %
PER92.46%93.71%93.08%32,20484.13%
FAC70.63%70.94%70.78%2,2956.00%
TIME58.66%57.75%58.20%1,6714.37%
GPE77.64%77.37%77.50%8662.26%
LOC62.96%45.71%52.97%7812.04%
VEH63.43%47.95%54.61%4631.21%
micro_avg88.39%88.87%88.58%38,280100.00%
macro_avg70.96%65.57%67.86%38,280100.00%

TRAINING PARAMETERS:

  • —Entities types: ['PER', 'LOC', 'FAC', 'TIME', 'VEH', 'GPE']
  • —Tagging scheme: BIOES
  • —Nested entities levels: [0, 1]
  • —Split strategy: Leave-one-out cross-validation (28 files)
  • —Train/Validation split: 0.85 / 0.15
  • —Batch size: 16
  • —Initial learning rate: 0.00014

MODEL ARCHITECTURE:

Model Input: Maximum context camembert-large embeddings (1024 dimensions)

  • —Locked Dropout: 0.5
  • —Projection layer:
  • —layer type: highway layer
  • —input: 1024 dimensions
  • —output: 2048 dimensions
  • —BiLSTM layer:
  • —input: 2048 dimensions
  • —output: 256 dimensions (hidden state)
  • —Linear layer:
  • —input: 256 dimensions
  • —output: 25 dimensions (predicted labels with BIOES tagging scheme)
  • —CRF layer

Model Output: BIOES labels sequence

HOW TO USE:

Propp Documentation

TRAINING CORPUS:

DocumentTokens CountIs included in model eval
01830Balzac-Honoré-deLa-maison-du-chat-qui-pelote24,776 tokensTrue
11830Balzac-Honoré-deSarrasine15,408 tokensTrue
21836Gautier-ThéophileLa-morte-amoureuse14,293 tokensTrue
31837Balzac-Honoré-deLa-maison-Nucingen30,034 tokensTrue
41841Sand-GeorgePauline12,398 tokensTrue
51856Cousin-VictorMadame-de-Hautefort11,768 tokensTrue
61863Gautier-ThéophileLe-capitaine-Fracasse11,848 tokensTrue
71873Zola-ÉmileLe-ventre-de-Paris12,613 tokensTrue
81881Flaubert-GustaveBouvard-et-Pécuchet12,308 tokensTrue
91882-1883Maupassant-Guy-deMademoiselle-Fifi-La-buche2,267 tokensTrue
101882-1883Maupassant-Guy-deMademoiselle-Fifi-La-relique2,041 tokensTrue
111882-1883Maupassant-Guy-deMademoiselle-Fifi-La-rouille2,949 tokensTrue
121882-1883Maupassant-Guy-deMademoiselle-Fifi-Madame-Baptiste2,578 tokensTrue
131882-1883Maupassant-Guy-deMademoiselle-Fifi-Marocca4,078 tokensTrue
141882-1883Maupassant-Guy-deMademoiselle-Fifi-Nouveaux-contes-A-cheval2,878 tokensTrue
151882-1883Maupassant-Guy-deMademoiselle-Fifi-Nouveaux-contes-Fou1,905 tokensTrue
161882-1883Maupassant-Guy-deMademoiselle-Fifi-Nouveaux-contes-Mademoiselle-Fifi5,439 tokensTrue
171882-1883Maupassant-Guy-deMademoiselle-Fifi-Nouveaux-contes-Reveil2,159 tokensTrue
181882-1883Maupassant-Guy-deMademoiselle-Fifi-Nouveaux-contes-Un-reveillon2,364 tokensTrue
191882-1883Maupassant-Guy-deMademoiselle-Fifi-Nouveaux-contes-Une-ruse2,469 tokensTrue
201901Achard-LucieRosalie-de-Constant-sa-famille-et-ses-amis12,775 tokensTrue
211903Conan-LaureÉlisabeth-Seton13,046 tokensTrue
221904-1912Rolland-RomainJean-Christophe(1)10,982 tokensTrue
231904-1912Rolland-RomainJean-Christophe(2)10,305 tokensTrue
241917Bourgeois-AdèleNémoville12,468 tokensTrue
251923Radiguet-RaymondLe-diable-au-corps14,850 tokensTrue
261926Audoux-MargueriteDe-la-ville-au-moulin12,144 tokensTrue
271937Audoux-MargueriteDouce-Lumière12,346 tokensTrue
28TOTAL275,489 tokens28 files used for cross-validation

PREDICTIONS CONFUSION MATRIX:

Gold LabelsPERFACTIMEGPELOCVEHOsupport
PER30,177281477311,94032,204
FAC421,6281221715842,295
TIME819651106951,671
GPE13312670310119866
LOC8641563570295781
VEH548000222179463
O2,2855246611001509603,816

CONTACT:

mail: antoine [dot] bourgois [at] protonmail [dot] com