brutusxu commited on
Commit
3c38b04
·
verified ·
1 Parent(s): 80cc660

Upload Tevatron-Elastic checkpoint (final model)

Browse files
Files changed (6) hide show
  1. README.md +29 -0
  2. config.json +30 -0
  3. granularities.json +36 -0
  4. model.safetensors +3 -0
  5. tokenizer.json +0 -0
  6. tokenizer_config.json +15 -0
README.md ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: google-bert/bert-base-uncased
4
+ library_name: transformers
5
+ tags:
6
+ - tevatron
7
+ - tevatron-elastic
8
+ - information-retrieval
9
+ - retriever
10
+ - elastic
11
+ ---
12
+
13
+ # tevatron-elastic-bert-retriever-depth
14
+
15
+ A **retriever** trained with [Tevatron-Elastic](https://github.com/zhichaoxu-shufe/tevatron-elastic),
16
+ which trains one checkpoint to serve many operating points along the depth / width / token
17
+ compression axes. This checkpoint is an elastic **depth** axis (early exit): one checkpoint serves several layer counts.
18
+
19
+ - **Base model:** `google-bert/bert-base-uncased`
20
+ - **Task:** retriever
21
+ - **Elastic axis:** depth
22
+ - **Training data:** [rlhn/rlhn-680K](https://huggingface.co/datasets/rlhn/rlhn-680K), max length 512, `query:`/`passage:` prefixes.
23
+
24
+ Full-point BEIR-15 nDCG@10: **0.453**.
25
+
26
+ Load with the Tevatron-Elastic framework and select an operating point with `prune_to` /
27
+ `encode_at`; see the repository for usage. Part of a release of 20 checkpoints (3 backbones,
28
+ retrieval and reranking, all compression axes) accompanying the Tevatron-Elastic paper. Reported as
29
+ a reproducibility resource, not a state-of-the-art claim.
config.json ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_cross_attention": false,
3
+ "architectures": [
4
+ "BertModel"
5
+ ],
6
+ "attention_probs_dropout_prob": 0.1,
7
+ "bos_token_id": null,
8
+ "classifier_dropout": null,
9
+ "dtype": "bfloat16",
10
+ "eos_token_id": null,
11
+ "gradient_checkpointing": false,
12
+ "hidden_act": "gelu",
13
+ "hidden_dropout_prob": 0.1,
14
+ "hidden_size": 768,
15
+ "initializer_range": 0.02,
16
+ "intermediate_size": 3072,
17
+ "is_decoder": false,
18
+ "layer_norm_eps": 1e-12,
19
+ "max_position_embeddings": 512,
20
+ "model_type": "bert",
21
+ "num_attention_heads": 12,
22
+ "num_hidden_layers": 12,
23
+ "pad_token_id": 0,
24
+ "position_embedding_type": "absolute",
25
+ "tie_word_embeddings": true,
26
+ "transformers_version": "5.12.1",
27
+ "type_vocab_size": 2,
28
+ "use_cache": false,
29
+ "vocab_size": 30522
30
+ }
granularities.json ADDED
@@ -0,0 +1,36 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "pooling": "cls",
3
+ "normalize": true,
4
+ "points": [
5
+ {
6
+ "layer": 2,
7
+ "dim": 768,
8
+ "name": null
9
+ },
10
+ {
11
+ "layer": 4,
12
+ "dim": 768,
13
+ "name": null
14
+ },
15
+ {
16
+ "layer": 6,
17
+ "dim": 768,
18
+ "name": null
19
+ },
20
+ {
21
+ "layer": 8,
22
+ "dim": 768,
23
+ "name": null
24
+ },
25
+ {
26
+ "layer": 10,
27
+ "dim": 768,
28
+ "name": null
29
+ },
30
+ {
31
+ "layer": 12,
32
+ "dim": 768,
33
+ "name": null
34
+ }
35
+ ]
36
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1721649bfc11530ed1e09b35dc3c45310ec98b182a28499e29f134cc3c654d8c
3
+ size 218986904
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "backend": "tokenizers",
3
+ "cls_token": "[CLS]",
4
+ "do_lower_case": true,
5
+ "is_local": true,
6
+ "local_files_only": false,
7
+ "mask_token": "[MASK]",
8
+ "model_max_length": 512,
9
+ "pad_token": "[PAD]",
10
+ "sep_token": "[SEP]",
11
+ "strip_accents": null,
12
+ "tokenize_chinese_chars": true,
13
+ "tokenizer_class": "BertTokenizer",
14
+ "unk_token": "[UNK]"
15
+ }