ArmelR commited on
Commit
5d43404
1 Parent(s): dea9107

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +29 -0
README.md ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ # Model Card for Starcoder-conala
3
+
4
+ <!-- Provide a quick summary of what the model is/does. -->
5
+
6
+ This model is an instruction-tuned version of ⭐️ StarCoder. The instruction dataset involved is [Conala-mined-curated](https://huggingface.co/datasets/codeparrot/conala-mined-curated)
7
+ which was built by boostrapping by predicting the column *rewritten_intent* of the mined subset of the [CoNaLa corpus](https://huggingface.co/datasets/neulab/conala).
8
+ ## Uses
9
+
10
+ <!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
11
+ The model was fine-tuned with the following template
12
+ ```
13
+ Question: <instruction>
14
+
15
+ Answer: <output>
16
+ ```
17
+ If you have your model and tokenizer loaded, you can use the following code to make the model generate the right output to a given instruction
18
+
19
+ ```python
20
+ instruction = "Write a function to compute the GCD between two integers a and b"
21
+ prompt = f"Question:{instruction}\n\nAnswer:"
22
+ input_ids = tokenizer(prompt, return_tensors="pt")["input_ids"]
23
+ completion = model.generate(input_ids, max_length=200)
24
+ print(tokenizer.batch_decode(completion[:,input_ids.shape[1]:])[0])
25
+ ```
26
+ ## More information
27
+ For additional information, check
28
+ - [Conala-mined-curated](https://huggingface.co/datasets/codeparrot/conala-mined-curated)
29
+ - [starcoder](https://huggingface.co/bigcode/starcoder)