CoolFace
Modelpublic

redewiedergabe/bert-base-historical-german-rw-cased

sourceHugging Faceupdated 5y agoView on Hugging Face
3likes121downloads
Model Card

Model description

Dataset

Trained on fictional and non-fictional German texts written between 1840 and 1920:

  • —Narrative texts from Digitale Bibliothek (https://textgrid.de/digitale-bibliothek)
  • —Fairy tales and sagas from Grimm Korpus (https://www1.ids-mannheim.de/kl/projekte/korpora/archiv/gri.html)
  • —Newspaper and magazine article from Mannheimer Korpus Historischer Zeitungen und Zeitschriften (https://repos.ids-mannheim.de/mkhz-beschreibung.html)
  • —Magazine article from the journal „Die Grenzboten“ (http://www.deutschestextarchiv.de/doku/textquellen#grenzboten)
  • —Fictional and non-fictional texts from Projekt Gutenberg (https://www.projekt-gutenberg.org)

Hardware used

1 Tesla P4 GPU

Hyperparameters

ParameterValue
Epochs3
Gradientaccumulationsteps1
Trainbatchsize32
Learning_rate0.00003
Maxseqlen128

Evaluation results: Automatic tagging of four forms of speech/thought/writing representation in historical fictional and non-fictional German texts

The language model was used in the task to tag direct, indirect, reported and free indirect speech/thought/writing representation in fictional and non-fictional German texts. The tagger is available and described in detail at https://github.com/redewiedergabe/tagger.

The tagging model was trained using the SequenceTagger Class of the Flair framework (Akbik et al., 2019) which implements a BiLSTM-CRF architecture on top of a language embedding (as proposed by Huang et al. (2015)).

Hyperparameters

ParameterValue
Hidden_size256
Learning_rate0.1
Minibatchsize8
Max_epochs150

Results are reported below in comparison to a custom trained flair embedding, which was stacked onto a custom trained fastText-model. Both models were trained on the same dataset.

BERTFastText+FlairTest data
F1PrecisionRecallF1PrecisionRecall
Direct0.800.860.740.840.900.79historical German, fictional & non-fictional
Indirect0.760.790.730.730.780.68historical German, fictional & non-fictional
Reported0.580.690.510.560.680.48historical German, fictional & non-fictional
Free indirect0.570.800.440.470.780.34modern German, fictional

Intended use:

Historical German Texts (1840 to 1920)

(Showed good performance with modern German fictional texts as well)