/ Модель

Характеристики

Контекст
1 024 токена
Лицензия
MIT
Архитектура
gpt2 · dense
Библиотека
transformers
Опубликована
24 окт 2026

gpt2-small-fineweb-edu

Генерация текстаТекст → текст3 профессии

Базовая модель GPT-2 small для продолжения англоязычных текстов образовательного характера, обученная с нуля на FineWeb-Edu.

1 574скачиваний за 30 дней0лайковвеса обновлены1 ноя 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Тесты пользователейпока нет

Никто ещё не опубликовал тест этой модели. Соберите бенчмарк из своих задач — результат появится здесь.

  1. Добавьте модель в бенчмарк

    Вместе с другими моделями категории «Текст» — сравнение идёт внутри одной категории.

  2. Опишите свои задачи

    Напишите запросы, при необходимости приложите файлы и эталонные ответы.

  3. Запустите и опубликуйте

    Модели ответят на каждую задачу, судья оценит ответы. Опубликованный результат появится на этой странице.

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

John-Machado/gpt2-small-fineweb-edu — авторская модель GPT-2 small, обученная John Machado с нуля на случайно инициализированных весах. Модель содержит около 124 млн параметров и обучалась на 9,85 млрд токенов набора FineWeb-Edu; архитектура включает 12 слоёв, скрытую размерность 768 и 12 голов внимания. Для работы доступны веса Safetensors и библиотека Transformers. Контекст — 1024 токена.

Модель предназначена для продолжения англоязычного текста в стиле образовательных веб-страниц, например для генерации учебных фрагментов по заданной начальной строке. На отложенной части FineWeb-Edu она показала меньшую ошибку валидации, чем исходная GPT-2 small, но сравнение относится именно к этому набору данных. Это базовая языковая модель без настройки на выполнение инструкций: она ненадёжно отвечает на вопросы, может уверенно выдумывать факты и наследует смещения и ошибки веб-текстов. Лицензия — MIT.

Сценарии применения

  • продолжение англоязычных учебных текстов по начальной фразе
  • генерация фрагментов в стиле образовательных веб-страниц
  • эксперименты с небольшой GPT-2-моделью на FineWeb-Edu
  • изучение обучения языковой модели с нуля на примере GPT-2

Ограничения

Модель не настроена на выполнение инструкций и ненадёжно отвечает на вопросы; она может уверенно выдумывать факты. Она ориентирована на английские тексты, имеет контекст 1024 токена и может воспроизводить смещения и ошибки обучающих веб-данных.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

GPT-2 small, trained from scratch on FineWeb-Edu

A 124M-parameter GPT-2 small, trained from random weights on 9.85 billion tokens of FineWeb-Edu, with a readable GPT-2 written from scratch in PyTorch.

Code: github.com/JohnMachado11/GPT-2 -- the model, the training loop and the scripts that trained this one, all hand-written, with every weight and step named.

The whole story of this run, from the data to the overnight training and what it cost, is in the blog post How I trained GPT-2 small from scratch.

On the same 99.6M held-out FineWeb-Edu tokens it reaches a lower validation loss than OpenAI's original GPT-2 small from 2019:

modelvalidation loss (lower is better)perplexity
this model3.054821.2
OpenAI's GPT-2 small (gpt2)3.297527.0

Both models were scored on exactly the same 99,631,104 tokens: FineWeb-Edu's held-out 1% (every 100th web page), never seen in training. FineWeb-Edu is home turf for this model -- OpenAI's was trained on WebText -- so this compares the two on modern educational web text, not on every kind of text.

Use it

from transformers import AutoModelForCausalLM, AutoTokenizer

model = AutoModelForCausalLM.from_pretrained("John-Machado/gpt2-small-fineweb-edu")
tokenizer = AutoTokenizer.from_pretrained("John-Machado/gpt2-small-fineweb-edu")

ids = tokenizer("The water cycle is", return_tensors="pt").input_ids
out = model.generate(ids, max_new_tokens=40, do_sample=True, top_k=50, pad_token_id=tokenizer.eos_token_id)
print(tokenizer.decode(out[0]))

Or load it into the readable model from the GitHub repo, where every weight has a plain name:

from gpt2.from_hf import load_gpt2
model = load_gpt2("John-Machado/gpt2-small-fineweb-edu")

Samples

Sampled with top_k=50 (seed 0); the prompt is in bold:

The water cycle is a fundamental system of our planet that is crucial for life on the planet. The Water Cycle, while essential for life in general, can't be changed. Water is essential for life on Earth

The French Revolution began in 1789, with the establishment of the "New State of the People" at Versailles. Napoleon III and Napoleon Bonaparte, a French Revolutionary party led by Giacomo Meyerbeer,

Fluent, on-topic, textbook-style English -- and, like any 124M model, confident inventions (1789 and Versailles are right; Napoleon III and the composer Meyerbeer are not).

Reproduce it

Every step of this run -- preparing the data, a smoke test, training, and the comparison with OpenAI's model -- is written out in the repo: Train GPT-2 small from scratch.

Training

ArchitectureGPT-2 small: 12 layers, 768 wide, 12 heads, context 1024, tied embeddings -- 124,439,808 parameters
DataFineWeb-Edu sample-10BT (revision 87f09149ef4734204d70ed1d046ddc9ca3f2b8f9), GPT-2 tokenizer; 9,854,302,149 training tokens, read once, in order
Steps18,794 steps of 524,288 tokens (micro-batch 16 × 32 accumulation × 1024)
OptimizerAdamW, betas (0.9, 0.95), weight decay 0.1 on the 2-D weights, gradient norm capped at 1.0
Learning ratelinear warmup over 715 steps to 6e-4, then cosine down to 6e-5
Dropout0.0
Precision and speedbf16 autocast, TF32, fused attention (FlashAttention via PyTorch SDPA), torch.compile
Hardwareone NVIDIA A100 40GB on Google Colab Pro+: 15.6 hours at ~176,000 tokens/s
Final losstrain ~3.0; validation 3.0113 on the in-training check (the first 327,680 held-out tokens)

The learning rates and batch size follow the GPT-3 paper's settings for its 125M model.

Limitations

  • A base model. It continues text; it isn't instruction-tuned and doesn't answer questions reliably.
  • Not a source of facts. It invents details, and often names a country's most famous city as its capital (Montreal for Canada, Sydney for Australia) -- as OpenAI's GPT-2 small does.
  • English, in the style of educational web pages, with a 1024-token context.
  • Trained on web text, so it can reflect the biases and errors of that text.

License and credits

The weights are released under the MIT license, like the code. The training data is FineWeb-Edu by Hugging Face (ODC-By 1.0; its use is also subject to Common Crawl's terms of use). The tokenizer is OpenAI's GPT-2 tokenizer. Architecture: OpenAI's GPT-2 (Radford et al., 2019).

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Можно запустить

Подбираем GPU…

Класс архитектуры
GPT2LMHeadModel
Ревизия весов
d41e9cc

0 моделей