affan-h commited on
Commit
e2f29ff
·
verified ·
1 Parent(s): f1cd038

Upload fine-tuned encoder

Browse files
Files changed (6) hide show
  1. README.md +11 -0
  2. config.json +38 -0
  3. model.safetensors +3 -0
  4. tokenizer.json +0 -0
  5. tokenizer_config.json +24 -0
  6. training.json +14 -0
README.md ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ base_model: microsoft/deberta-v3-small
4
+ tags: [text-classification, compliance, cross-encoder]
5
+ ---
6
+
7
+ # CallGuard encoder
8
+
9
+ DeBERTa-v3-small fine-tuned as a cross-encoder: input is (rule or event description, previous turn +
10
+ current turn of a loan-collection call), output is whether the turn matches the description. Trained on
11
+ synthetic, Gemini-written calls only. Part of the CallGuard portfolio project; not for production use.
config.json ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "DebertaV2ForSequenceClassification"
4
+ ],
5
+ "attention_probs_dropout_prob": 0.1,
6
+ "bos_token_id": null,
7
+ "dtype": "float32",
8
+ "eos_token_id": null,
9
+ "hidden_act": "gelu",
10
+ "hidden_dropout_prob": 0.1,
11
+ "hidden_size": 768,
12
+ "initializer_range": 0.02,
13
+ "intermediate_size": 3072,
14
+ "layer_norm_eps": 1e-07,
15
+ "legacy": true,
16
+ "max_position_embeddings": 512,
17
+ "max_relative_positions": -1,
18
+ "model_type": "deberta-v2",
19
+ "norm_rel_ebd": "layer_norm",
20
+ "num_attention_heads": 12,
21
+ "num_hidden_layers": 6,
22
+ "pad_token_id": 0,
23
+ "pooler_dropout": 0.0,
24
+ "pooler_hidden_act": "gelu",
25
+ "pooler_hidden_size": 768,
26
+ "pos_att_type": [
27
+ "p2c",
28
+ "c2p"
29
+ ],
30
+ "position_biased_input": false,
31
+ "position_buckets": 256,
32
+ "relative_attention": true,
33
+ "share_att_key": true,
34
+ "tie_word_embeddings": true,
35
+ "transformers_version": "5.16.1",
36
+ "type_vocab_size": 0,
37
+ "vocab_size": 128100
38
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:484141b37446507a630c5fed12f7b529cb1f731b7d234fd59125469cd6b78170
3
+ size 567598552
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_prefix_space": true,
3
+ "backend": "tokenizers",
4
+ "bos_token": "[CLS]",
5
+ "cls_token": "[CLS]",
6
+ "do_lower_case": false,
7
+ "eos_token": "[SEP]",
8
+ "extra_special_tokens": [
9
+ "[PAD]",
10
+ "[CLS]",
11
+ "[SEP]"
12
+ ],
13
+ "is_local": false,
14
+ "local_files_only": false,
15
+ "mask_token": "[MASK]",
16
+ "model_max_length": 1000000000000000019884624838656,
17
+ "pad_token": "[PAD]",
18
+ "sep_token": "[SEP]",
19
+ "split_by_punct": false,
20
+ "tokenizer_class": "DebertaV2Tokenizer",
21
+ "unk_id": 3,
22
+ "unk_token": "[UNK]",
23
+ "vocab_type": "spm"
24
+ }
training.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "data": "/kaggle/working/callguard/data/synthetic.jsonl",
3
+ "out": "data/models/encoder",
4
+ "base": "microsoft/deberta-v3-small",
5
+ "epochs": 3,
6
+ "batch": 32,
7
+ "lr": 3e-05,
8
+ "neg_ratio": 4.0,
9
+ "seed": 13,
10
+ "positives": 2964,
11
+ "negatives": 11856,
12
+ "hard_negatives": 4396,
13
+ "seconds": 371.22081422805786
14
+ }