arampacha commited on
Commit
abc6e4f
1 Parent(s): d984a0c

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +61 -0
README.md ADDED
@@ -0,0 +1,61 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # GPT-Code-Clippy-125M-APPS
2
+
3
+ ## Model Description
4
+
5
+ GPT-CC-125M-APPS is a GPT-Neo-1.3B finetuned on APPS dataset. This model is specialized to solve programming tasks.
6
+
7
+ ## Training data
8
+
9
+ [APPS dataset](https://github.com/hendrycks/apps).
10
+
11
+ ## Training procedure
12
+
13
+ The training script used to train this model can be found [here](https://github.com/ncoop57/gpt-code-clippy/blob/camera-ready/training/run_clm_apps.py).
14
+
15
+ ## Intended Use and Limitations
16
+
17
+ The model is finetuned to solve programming problems given a text description and optional starter code.
18
+
19
+ ### How to use
20
+
21
+ You can use this model directly with a pipeline for text generation. This example generates a different sequence each time it's run:
22
+
23
+ ```py
24
+
25
+ from transformers import AutoModelForCausalLM, AutoTokenizer, FlaxAutoModelForCausalLM
26
+
27
+ model = AutoModelForCausalLM.from_pretrained("flax-community/gpt-code-clippy-1.3B-apps-alldata")
28
+
29
+ tokenizer = AutoTokenizer.from_pretrained("flax-community/gpt-code-clippy-1.3B-apps-alldata")
30
+
31
+ prompt = """
32
+
33
+ A function to greet user. Given a user name it should say hello
34
+
35
+ def greet(name):
36
+
37
+ ANSWER:
38
+
39
+ """
40
+
41
+ input_ids = tokenizer(prompt, return_tensors='pt').input_ids.to(device)
42
+
43
+ start = input_ids.size(1)
44
+
45
+ out = model.generate(input_ids, do_sample=True, max_length=50, num_beams=2,
46
+
47
+ early_stopping=True, eos_token_id=tokenizer.eos_token_id, )
48
+
49
+ print(tokenizer.decode(out[0][start:]))
50
+
51
+ ```
52
+
53
+ ### Limitations and Biases
54
+
55
+ The model is intended to be used for research purposes and comes with no guarantees of quality of generated code.
56
+
57
+ GPT-CC is finetuned GPT-Neo and might have inhereted biases and limitations from it. See [GPT-Neo model card](https://huggingface.co/EleutherAI/gpt-neo-1.3B#limitations-and-biases) for details.
58
+
59
+ ## Eval results
60
+
61
+ Coming soon...