craa commited on
Commit
442d639
·
verified ·
1 Parent(s): 48e1bd5

Add model card

Browse files
Files changed (1) hide show
  1. README.md +43 -0
README.md ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ language:
4
+ - en
5
+ library_name: transformers
6
+ pipeline_tag: text-generation
7
+ tags:
8
+ - gpt2
9
+ datasets:
10
+ - craa/exceptions
11
+ ---
12
+
13
+ # exceptions
14
+
15
+ GPT-2 language models trained from scratch for the exceptions project
16
+ (Leong and Linzen, [Language Models Can Learn Exceptions to Syntactic Rules](https://doi.org/10.7275/h25z-0y75), and follow-up experiments).
17
+ Code: [github.com/craaaa/exceptions](https://github.com/craaaa/exceptions).
18
+
19
+ All models are GPT-2 small (12 layers, 12 heads, 768 hidden). Each folder holds the final model of one training run
20
+ (best checkpoint by validation loss), with its tokenizer and Trainer logs (`trainer_state.json`, `all_results.json`).
21
+
22
+ ## Contents
23
+
24
+ | Folder | Runs | Naming | Seeds | Vocab |
25
+ |---|---|---|---|---|
26
+ | `exp1b/` | 5 | `100M_<seed>` | 1001, 2128, 3591, 5039, 40817 | 50,257 (GPT-2) |
27
+ | `exp2a/` | 60 | `<cond>_to_<verb>_frequency_<seed>` — cond ∈ {cost, last, resemble}, verb ∈ {carry, drop, hit, push} | 1001, 2128, 3591, 5039, 40817 | 50,257 (GPT-2) |
28
+ | `exp3/` | 170 | `{high,low}_<n>_<seed>` — n ∈ {0, 1, 2, 4, 8, 16, 32, 64, 10, 100, 128, 256, 500, 512, 1000, 1500, 2000} | 495, 634, 1208, 6910, 8397 | 52,000 (custom) |
29
+
30
+ Training corpora are in the dataset repo [`craa/exceptions`](https://huggingface.co/datasets/craa/exceptions);
31
+ the `exp2a` folder names correspond to its `frequency_<cond>_to_<verb>` configs.
32
+
33
+ ## Usage
34
+
35
+ ```python
36
+ from transformers import AutoModelForCausalLM, AutoTokenizer
37
+
38
+ repo, run = "craa/exceptions", "exp3/high_0_1208"
39
+ model = AutoModelForCausalLM.from_pretrained(repo, subfolder=run)
40
+ tokenizer = AutoTokenizer.from_pretrained(repo, subfolder=run)
41
+ ```
42
+
43
+ Intermediate checkpoints are not published here.