File size: 2,033 Bytes
0f4159f
 
 
 
 
 
 
 
f5e5c85
 
 
 
7505f3d
0f4159f
 
 
 
68470dc
 
0f4159f
68470dc
 
0f4159f
 
 
68470dc
0f4159f
 
 
68470dc
0f4159f
 
 
68470dc
 
 
 
 
0f4159f
 
 
68470dc
 
0f4159f
 
 
 
 
 
 
 
68470dc
0f4159f
 
 
 
 
 
 
f5e5c85
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
---
license: apache-2.0
base_model: bert-base-uncased
tags:
- generated_from_keras_callback
model-index:
- name: EconoBert
  results: []
datasets:
- samchain/BIS_Speeches_97_23
language:
- en
pipeline_tag: fill-mask
---

# EconoBert

This model is a fine-tuned version of [bert-base-uncased](https://huggingface.co./bert-base-uncased) on this dataset: (https://huggingface.co./datasets/samchain/BIS_Speeches_97_23)
It achieves the following results on the test set:

- Accuracy for MLM task: 73%
- Accuracy for NSP task: 95%

## Model description

The model is a simple fine-tuning of a base bert on a dataset specific to the domain of economics. It follows the same architecture and no resize_token_embeddings were required.

## Intended uses & limitations

This model should be used as a backbone for NLP tasks applied to the domain of economics, politics and finance.

## Training and evaluation data

The dataset used as a fine-tuning domain is : https://huggingface.co./datasets/samchain/BIS_Speeches_97_23

The dataset is made of 773k pairs of sentences, an half being negative pairs (meaning sequence A and B are not related) and the other half positive (sequence B follows sequence A).

The test set is made of 136k pairs.

## Training procedure

The model has been fine tuned on 2 epochs, with a batch size of 64 and a sequence length of 128. I used Adam learning-rate with a value of 1e-5, 

### Training hyperparameters

The following hyperparameters were used during training:
- optimizer: {'name': 'Adam', 'weight_decay': None, 'clipnorm': None, 'global_clipnorm': None, 'clipvalue': None, 'use_ema': False, 'ema_momentum': 0.99, 'ema_overwrite_frequency': None, 'jit_compile': True, 'is_legacy_optimizer': False, 'learning_rate': 1e-05, 'beta_1': 0.9, 'beta_2': 0.999, 'epsilon': 1e-07, 'amsgrad': False}
- training_precision: float32

### Training results

Training loss is 1.6046 on train set and 1.47 on test set.


### Framework versions

- Transformers 4.31.0
- TensorFlow 2.12.0
- Datasets 2.13.1
- Tokenizers 0.13.3