teknium commited on
Commit
50c23f7
1 Parent(s): dc703c3

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +81 -0
README.md CHANGED
@@ -1,3 +1,84 @@
1
  ---
2
  license: cc-by-sa-4.0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: cc-by-sa-4.0
3
+ datasets:
4
+ - bigcode/the-stack-dedup
5
+ - sahil2801/CodeAlpaca-20k
6
+ - teknium/GPTeacher-CodeInstruct
7
+ model-base:
8
+ - replit/replit-code-v1-3b
9
+ tags:
10
+ - code
11
+ - instruct
12
+ - self instruct
13
+ language:
14
+ - code
15
+ programming_language:
16
+ - Markdown
17
+ - Java
18
+ - JavaScript
19
+ - Python
20
+ - TypeScript
21
+ - PHP
22
+ - SQL
23
+ - JSX
24
+ - reStructuredText
25
+ - Rust
26
+ - C
27
+ - CSS
28
+ - Go
29
+ - C++
30
+ - HTML
31
+ - Vue
32
+ - Ruby
33
+ - Jupyter Notebook
34
+ - R
35
+ - Shell
36
  ---
37
+
38
+ Base Model: replit/replit-code-v1-3b
39
+
40
+ This model is fine tuned on both Sahil2801's CodeAlpaca & Teknium's GPTeacher Code-Instruct to give Replit's Code model instruct capabilities.
41
+
42
+ Dataset links:
43
+ CodeAlpaca: https://huggingface.co/datasets/sahil2801/CodeAlpaca-20k
44
+ GPTeacher subset - Code Instruct: https://github.com/teknium1/GPTeacher
45
+
46
+ This model was trained on 2x a100 80gb for 1 hour on ~25,000 code instruction/response pairs in Alpaca format.
47
+
48
+ Refer to the base models HuggingFace model card for some basic requirements to run: https://huggingface.co/replit/replit-code-v1-3b
49
+
50
+ This fine tune can be prompted like any alpaca fine tune:
51
+ ```
52
+ ### Instruction:
53
+ <prompt>
54
+
55
+ ### Input:
56
+ <additional context>
57
+
58
+ ### Response:
59
+ ```
60
+
61
+ or
62
+
63
+ ```
64
+ ### Instruction:
65
+ <prompt>
66
+
67
+ ### Response:
68
+
69
+ ```
70
+
71
+ This model for me produced coherent outputs with the following sampler settings, but feel free to experiment:
72
+ ```
73
+ max_new_tokens=128, do_sample=True, use_cache=True, temperature=0.2, top_p=0.9, eos_token_id= self.tokenizer.eos_token_id
74
+ ```
75
+
76
+ In the tokenizer decode arguments, it also needs these settings:
77
+ ```
78
+ skip_special_tokens=True, clean_up_tokenization_space=False
79
+ ```
80
+
81
+ The following parameters were used with HuggingFace trainer to train the model with:
82
+ ```
83
+ --model_name_or_path replit/replit-code-v1-3b --data_path /root/stanford_alpaca/train.json --bf16 True --output_dir /root/stanford_alpaca/model_ckpts --num_train_epochs 3 --per_device_train_batch_size 4 --per_device_eval_batch_size 1 --gradient_accumulation_steps 8 --save_strategy steps --save_steps 200 --save_total_limit 3 --learning_rate 1e-5 --weight_decay 0. --warmup_ratio 0.03 --tf32 True --run_name Replit1
84
+ ```