Commit
·
3d3ce87
1
Parent(s):
7fb65a9
Initial commit
Browse files- README.md +40 -0
- config.json +81 -0
- merges.txt +0 -0
- pytorch_model.bin +3 -0
- special_tokens_map.json +1 -0
- tokenizer_config.json +1 -0
- vocab.json +0 -0
README.md
CHANGED
|
@@ -1,3 +1,43 @@
|
|
| 1 |
---
|
|
|
|
| 2 |
license: mit
|
| 3 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
+
language: en
|
| 3 |
license: mit
|
| 4 |
---
|
| 5 |
+
# GPT-Neo 2.7B - Janeway
|
| 6 |
+
## Model Description
|
| 7 |
+
GPT-Neo 2.7B-Janeway is a finetune created using EleutherAI's GPT-Neo 2.7B model.
|
| 8 |
+
## Training data
|
| 9 |
+
The training data contains around 2210 ebooks, mostly in the sci-fi and fantasy genres. The dataset is based on the same dataset used by GPT-Neo-2.7B-Picard, with 20% more data in various genres.
|
| 10 |
+
Some parts of the dataset have been prepended using the following text: `[Genre: <genre1>,<genre2>]`
|
| 11 |
+
### How to use
|
| 12 |
+
You can use this model directly with a pipeline for text generation. This example generates a different sequence each time it's run:
|
| 13 |
+
```py
|
| 14 |
+
>>> from transformers import pipeline
|
| 15 |
+
>>> generator = pipeline('text-generation', model='KoboldAI/GPT-Neo-2.7B-Janeway')
|
| 16 |
+
>>> generator("Welcome Captain Janeway, I apologize for the delay.", do_sample=True, min_length=50)
|
| 17 |
+
[{'generated_text': 'Welcome Captain Janeway, I apologize for the delay."\nIt's all right," Janeway said. "I'm certain that you're doing your best to keep me informed of what\'s going on."'}]
|
| 18 |
+
```
|
| 19 |
+
### Limitations and Biases
|
| 20 |
+
GPT-Neo was trained as an autoregressive language model. This means that its core functionality is taking a string of text and predicting the next token. While language models are widely used for tasks other than this, there are a lot of unknowns with this work.
|
| 21 |
+
GPT-Neo was trained on the Pile, a dataset known to contain profanity, lewd, and otherwise abrasive language. Depending on your usecase GPT-Neo may produce socially unacceptable text. See Sections 5 and 6 of the Pile paper for a more detailed analysis of the biases in the Pile.
|
| 22 |
+
As with all language models, it is hard to predict in advance how GPT-Neo will respond to particular prompts and offensive content may occur without warning. We recommend having a human curate or filter the outputs before releasing them, both to censor undesirable content and to improve the quality of the results.
|
| 23 |
+
### BibTeX entry and citation info
|
| 24 |
+
The model is made using the following software:
|
| 25 |
+
```bibtex
|
| 26 |
+
@software{gpt-neo,
|
| 27 |
+
author = {Black, Sid and
|
| 28 |
+
Leo, Gao and
|
| 29 |
+
Wang, Phil and
|
| 30 |
+
Leahy, Connor and
|
| 31 |
+
Biderman, Stella},
|
| 32 |
+
title = {{GPT-Neo: Large Scale Autoregressive Language
|
| 33 |
+
Modeling with Mesh-Tensorflow}},
|
| 34 |
+
month = mar,
|
| 35 |
+
year = 2021,
|
| 36 |
+
note = {{If you use this software, please cite it using
|
| 37 |
+
these metadata.}},
|
| 38 |
+
publisher = {Zenodo},
|
| 39 |
+
version = {1.0},
|
| 40 |
+
doi = {10.5281/zenodo.5297715},
|
| 41 |
+
url = {https://doi.org/10.5281/zenodo.5297715}
|
| 42 |
+
}
|
| 43 |
+
```
|
config.json
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_name_or_path": "EleutherAI/gpt-neo-2.7B",
|
| 3 |
+
"activation_function": "gelu_new",
|
| 4 |
+
"architectures": [
|
| 5 |
+
"GPTNeoForCausalLM"
|
| 6 |
+
],
|
| 7 |
+
"attention_dropout": 0,
|
| 8 |
+
"attention_layers": [
|
| 9 |
+
"global",
|
| 10 |
+
"local",
|
| 11 |
+
"global",
|
| 12 |
+
"local",
|
| 13 |
+
"global",
|
| 14 |
+
"local",
|
| 15 |
+
"global",
|
| 16 |
+
"local",
|
| 17 |
+
"global",
|
| 18 |
+
"local",
|
| 19 |
+
"global",
|
| 20 |
+
"local",
|
| 21 |
+
"global",
|
| 22 |
+
"local",
|
| 23 |
+
"global",
|
| 24 |
+
"local",
|
| 25 |
+
"global",
|
| 26 |
+
"local",
|
| 27 |
+
"global",
|
| 28 |
+
"local",
|
| 29 |
+
"global",
|
| 30 |
+
"local",
|
| 31 |
+
"global",
|
| 32 |
+
"local",
|
| 33 |
+
"global",
|
| 34 |
+
"local",
|
| 35 |
+
"global",
|
| 36 |
+
"local",
|
| 37 |
+
"global",
|
| 38 |
+
"local",
|
| 39 |
+
"global",
|
| 40 |
+
"local"
|
| 41 |
+
],
|
| 42 |
+
"attention_types": [
|
| 43 |
+
[
|
| 44 |
+
[
|
| 45 |
+
"global",
|
| 46 |
+
"local"
|
| 47 |
+
],
|
| 48 |
+
16
|
| 49 |
+
]
|
| 50 |
+
],
|
| 51 |
+
"bos_token_id": 50256,
|
| 52 |
+
"embed_dropout": 0,
|
| 53 |
+
"eos_token_id": 50256,
|
| 54 |
+
"hidden_size": 2560,
|
| 55 |
+
"initializer_range": 0.02,
|
| 56 |
+
"intermediate_size": null,
|
| 57 |
+
"layer_norm_epsilon": 1e-05,
|
| 58 |
+
"max_position_embeddings": 2048,
|
| 59 |
+
"model_type": "gpt_neo",
|
| 60 |
+
"num_heads": 20,
|
| 61 |
+
"num_layers": 32,
|
| 62 |
+
"resid_dropout": 0,
|
| 63 |
+
"summary_activation": null,
|
| 64 |
+
"summary_first_dropout": 0.1,
|
| 65 |
+
"summary_proj_to_labels": true,
|
| 66 |
+
"summary_type": "cls_index",
|
| 67 |
+
"summary_use_proj": true,
|
| 68 |
+
"task_specific_params": {
|
| 69 |
+
"text-generation": {
|
| 70 |
+
"do_sample": true,
|
| 71 |
+
"max_length": 50,
|
| 72 |
+
"temperature": 0.9
|
| 73 |
+
}
|
| 74 |
+
},
|
| 75 |
+
"tokenizer_class": "GPT2Tokenizer",
|
| 76 |
+
"torch_dtype": "float16",
|
| 77 |
+
"transformers_version": "4.17.0.dev0",
|
| 78 |
+
"use_cache": false,
|
| 79 |
+
"vocab_size": 50257,
|
| 80 |
+
"window_size": 256
|
| 81 |
+
}
|
merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
pytorch_model.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9ef2b8619b4df8d2a139b928926ce97c94fdb6f1612d46473d94918493df0ad0
|
| 3 |
+
size 5436936394
|
special_tokens_map.json
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"bos_token": "<|endoftext|>", "eos_token": "<|endoftext|>", "unk_token": "<|endoftext|>"}
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"errors": "replace", "unk_token": {"content": "<|endoftext|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "bos_token": {"content": "<|endoftext|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "eos_token": {"content": "<|endoftext|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": true, "__type": "AddedToken"}, "add_prefix_space": false, "model_max_length": 2048, "special_tokens_map_file": null, "name_or_path": "EleutherAI/gpt-neo-2.7B", "tokenizer_class": "GPT2Tokenizer"}
|
vocab.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|