Model reference · open weights
gpt-neox-japanese is an open-weight language model from abeja. gpt-neox-japanese-2.7b (BF16) weighs 5.4 GB; the smallest configuration that runs it is RTX 3060 12 GB.
For self-hosting, compare this build's requirements below with the GPU you plan to rent.
Summary of the abeja/gpt-neox-japanese-2.7b model card, 2026-10-01
What it is
| Released by | abeja |
|---|---|
| Released | 2022-08-29 |
| VRAM | 5.4 GB for the weights |
What it runs on
| Card | Requests at once | Context max | Memory |
|---|---|---|---|
| 2K each | |||
| RTX 3060 12 GB | 8 | all 2K | 11.6 GB |
| RTX 4060 Ti 16 GB | 14 | all 2K | 15.4 GB |
| RTX 3090 24 GB | 26 | all 2K | 23.4 GB |
| RTX 4090 24 GB | 25 | all 2K | 23.4 GB |
| RTX 5090 32 GB | 37 | all 2K | 31.0 GB |
| L40S 48 GB | 56 | all 2K | 44.0 GB |
| A100 80 GB | 107 | all 2K | 78.2 GB |
| H100 80 GB | 103 | all 2K | 78.1 GB |
| RTX PRO 6000 Blackwell 96 GB | 126 | all 2K | 93.8 GB |
| DGX Spark (GB10) 128 GB unified | 146 | all 2K | 107 GB |
| H200 141 GB | 192 | all 2K | 138 GB |
| B200 180 GB | 248 | all 2K | 176 GB |
| Requests at once | 2K tokens each |
|---|---|
| 1 | 6.6 GB |
| 5 | 9.3 GB |
| 8 | 11.3 GB |
| 16 | 16.7 GB |
| 32 | 27.4 GB |
| 64 | 48.9 GB |
One card, with vLLM's small-card settings.
From the model card
The open PR is merged on 2022/9/14. You can use this model with v4.23 and higher versions of transformers as follows,
pip install transformers
This repository provides a 2.7B-parameter Japanese GPT-NeoX-based model. The model was trained by ABEJA, Inc
When using pipeline for text generation.
from transformers import pipeline
generator = pipeline("text-generation", model="abeja/gpt-neox-japanese-2.7b")
generated = generator(
"人とAIが協調するためには、",
max_length=300,
do_sample=True,
num_return_sequences=3,
top_p=0.95,
top_k=50
)
print(*generated, sep="\n")
"""
[out]
{"generated_text": "人とAIが協調するためには、「人が持っている優れた能力とAIの得意とする分野を掛け合わせる」ことが不可欠になります。"}
{"generated_text": "人とAIが協調するためには、双方の長所を活かしていくことが不可欠だと考えています。"}
{"generated_text": "人とAIが協調するためには、人間がAIを理解する、ということが重要です。人間には「AIに対してAIが何をするべきか」ということを明確に教えないと、AIはある程度の知識はあっても何をすべきかがわかりません。だから、コンピューターが考えたり、決めたりすることはAIではなく、人間が解釈して理解できるようにしなくて"}
"""
When using PyTorch.
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("abeja/gpt-neox-japanese-2.7b")
model = AutoModelForCausalLM.from_pretrained("abeja/gpt-neox-japanese-2.7b")
input_text = "人とAIが協調するためには、"
input_ids = tokenizer.encode(input_text, return_tensors="pt")
gen_tokens = model.generate(
input_ids,
max_length=100,
do_sample=True,
num_return_sequences=3,
top_p=0.95,
top_k=50,
)
for gen_text in tokenizer.batch_decode(gen_tokens, skip_special_tokens=True):
print(gen_text)
The model was trained on Japanese CC-100, Japanese Wikipedia, and Japanese OSCAR.
The model uses a special sub-word tokenizer. Please refer the original repository or GPT-NeoX-Japanese in detail.
Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.