File size: 4,912 Bytes
ff94b14
 
32bab43
 
 
 
19e4696
da0d85c
 
b068411
9215450
b068411
01e99a8
ff94b14
 
e47bb94
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9215450
 
 
 
e47bb94
9215450
 
 
e47bb94
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9215450
 
e47bb94
 
 
9215450
e47bb94
9215450
 
 
 
 
01e99a8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
---
library_name: transformers
language:
- en
base_model:
- EleutherAI/gpt-neo-1.3B
license: apache-2.0
datasets:
- legacy-datasets/wikipedia
metrics:
- perplexity
- accuracy
new_version: Kimargin/GPT-NEO-1.3B-wiki
---

# Model Card for GPT-NEO-1.3B-wiki

## Model Details

### Model Description

This model is based on [EleutherAI/gpt-neo-1.3B](https://huggingface.co/EleutherAI/gpt-neo-1.3B) and has been fine-tuned on the Wikipedia dataset. It is designed for text generation tasks such as summarization, question answering, and text completion in English. The model is fine-tuned to improve the fluency and factual accuracy of the generated content.

- **Developed by:** Kimargin
- **Model type:** Fine-tuned model
- **Language(s):** English
- **License:** Apache 2.0
- **Finetuned from model:** EleutherAI/gpt-neo-1.3B

### Model Sources

- **Repository:** [Kimargin/GPT-NEO-1.3B-wiki](https://huggingface.co/Kimargin/GPT-NEO-1.3B-wiki)

## Uses

### Direct Use

This model can be used for tasks like text generation, summarization, and question-answering. It is useful for generating coherent and factual text based on English-language prompts.

### Downstream Use

The model can be fine-tuned further for domain-specific applications such as legal or medical text generation, creating specialized question-answering systems, or generating structured content from prompts.

### Out-of-Scope Use

The model should not be used in critical applications (e.g., legal, medical, or financial advice) as it may generate biased, inaccurate, or misleading information. It is also not suited for real-time decision-making.

## Bias, Risks, and Limitations

Since the model was trained on Wikipedia data, it may inherit biases present in the dataset. Users should be cautious when using the model for generating sensitive or potentially biased content. The model may produce inaccurate or misleading text if given ambiguous or misleading prompts.

### Recommendations

Users should verify the outputs of the model, especially in critical use cases, and should not rely solely on the model for factual accuracy without human verification.

## How to Get Started with the Model

To use the model, you can load it as follows:


tokenizer = AutoTokenizer.from_pretrained("Kimargin/GPT-NEO-1.3B-wiki")
model = AutoModelForCausalLM.from_pretrained("Kimargin/GPT-NEO-1.3B-wiki")

input_text = "What happened during World War II?"
inputs = tokenizer(input_text, return_tensors="pt")
outputs = model.generate(inputs["input_ids"], max_length=100)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))


## Training Details

### Training Data
The model was fine-tuned on a subset of the Wikipedia dataset, which contains a broad range of general knowledge topics. This dataset was chosen to improve the model's capability to generate accurate, general-domain knowledge.

### Training Procedure
The model was fine-tuned using mixed precision (float16) on multiple GPUs for three epochs. The training was done to minimize perplexity and improve fluency in generated text.

### Training Hyperparameters
- **Learning rate:** 5e-5
- **Batch size:** 16
- **Epochs:** 3
- **Precision:** float16 (mixed precision)

## Evaluation

### Testing Data
The model was evaluated using a validation subset of the Wikipedia dataset to measure its performance on general text generation tasks.

### Metrics
- **Perplexity:** The model achieved a perplexity of 25.3 on the validation set.
- **Accuracy:** The accuracy of the model in generating factual answers was evaluated qualitatively.

### Results
The model demonstrates good performance in generating coherent and contextually relevant text, but it may still struggle with niche or specialized topics that are underrepresented in its training data.

## Environmental Impact
Training large models like GPT-Neo has a significant carbon footprint due to the computational resources required. The estimated environmental impact of fine-tuning this model is as follows:

- **Hardware Type:** NVIDIA A100 GPUs
- **Hours used:** 20 hours
- **Cloud Provider:** Google Cloud
- **Compute Region:** US-Central
- **Carbon Emitted:** ~50 kg CO2 (estimated using the [ML Impact calculator](https://mlco2.github.io/impact#compute))

## Technical Specifications

### Model Architecture and Objective
The model is a causal language model with 1.3 billion parameters, based on the GPT-Neo architecture. It generates text by predicting the next word in a sequence, making it suitable for text completion and generation tasks.

### Compute Infrastructure
The model was trained on NVIDIA A100 GPUs using Google Cloud infrastructure.

## Citation

If you use this model, please cite the original GPT-Neo model as follows:

```bibtex
@article{gpt-neo,
  author = {EleutherAI},
  title = {GPT-Neo: Large Scale Autoregressive Language Model},
  year = {2021},
  url = {https://github.com/EleutherAI/gpt-neo}
}