Update README.md
Browse files
README.md
CHANGED
@@ -11,7 +11,7 @@ metrics:
|
|
11 |
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
12 |
should probably proofread and complete it, then remove this comment. -->
|
13 |
|
14 |
-
#
|
15 |
|
16 |
This model is a fine-tuned version of [EleutherAI/pythia-6.9b-deduped](https://huggingface.co/EleutherAI/pythia-6.9b-deduped) on the pszemraj/HC3-textgen-qa dataset.
|
17 |
It achieves the following results on the evaluation set:
|
@@ -22,10 +22,41 @@ It achieves the following results on the evaluation set:
|
|
22 |
|
23 |
Text generation model trained on the HC3 text data of human questions + chatGPT answers.
|
24 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
|
26 |
## Intended uses & limitations
|
27 |
|
28 |
-
|
|
|
29 |
|
30 |
## Training and evaluation data
|
31 |
|
|
|
11 |
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
12 |
should probably proofread and complete it, then remove this comment. -->
|
13 |
|
14 |
+
# pythia-6.9b-deduped for general QA
|
15 |
|
16 |
This model is a fine-tuned version of [EleutherAI/pythia-6.9b-deduped](https://huggingface.co/EleutherAI/pythia-6.9b-deduped) on the pszemraj/HC3-textgen-qa dataset.
|
17 |
It achieves the following results on the evaluation set:
|
|
|
22 |
|
23 |
Text generation model trained on the HC3 text data of human questions + chatGPT answers.
|
24 |
|
25 |
+
### Usage
|
26 |
+
|
27 |
+
Install necessary packages for inference (_unless you have a big boi GPU_)
|
28 |
+
```bash
|
29 |
+
pip install -U -q transformers bitsandbytes accelerate
|
30 |
+
```
|
31 |
+
|
32 |
+
Basic inference example:
|
33 |
+
|
34 |
+
```python
|
35 |
+
from transformers import AutoTokenizer, AutoModelForCausalLM
|
36 |
+
|
37 |
+
tokenizer = AutoTokenizer.from_pretrained("pszemraj/pythia-6.9b-HC3")
|
38 |
+
|
39 |
+
model = AutoModelForCausalLM.from_pretrained(
|
40 |
+
"pszemraj/pythia-6.9b-HC3", load_in_8bit=True, device_map="auto"
|
41 |
+
)
|
42 |
+
|
43 |
+
prompt = "I was wondering how much wood a woodchuck could chuck? <answer>"
|
44 |
+
inputs = tokenizer(prompt, return_tensors="pt")
|
45 |
+
inputs = inputs.to("cuda")
|
46 |
+
outputs = model.generate(**inputs, max_new_tokens=300)
|
47 |
+
result = tokenizer.batch_decode(outputs, skip_special_tokens=True)
|
48 |
+
|
49 |
+
import pprint as pp
|
50 |
+
|
51 |
+
pp.pprint(result[0])
|
52 |
+
```
|
53 |
+
|
54 |
+
The defautl `GenerationConfig` uses contrastive search with `top_k=4` and `penalty_alpha=0.6`. For more information on inference and parameters to use, see [the transformers docs](https://huggingface.co/docs/transformers/generation_strategies#decoding-strategies).
|
55 |
|
56 |
## Intended uses & limitations
|
57 |
|
58 |
+
- **Intended use:** research/exploration into comparing RLHF tuning vs. "guided"/specific tuning on "quality" datasets/responses of _"what the human would want as answer anyway"_
|
59 |
+
- This is not trained/fine-tuned with RLHF and therefore will not be as helpful/generalizable/safe as chatGPT.
|
60 |
|
61 |
## Training and evaluation data
|
62 |
|