minimind

MiniMind is an open-source project for training a small language model from scratch and studying the LLM pipeline. It helps learners explore how models work through hands-on training and fine-tuning.

Share on XLicense: Apache-2.0

Overview

MiniMind is an open-source project for building and training small language models from scratch, intended to make LLM internals easier to study without relying on high-level training abstractions. It provides PyTorch implementations of model structures and a training path spanning pretraining, supervised fine-tuning, LoRA, preference optimization, tool use, and distillation. Users can follow the code, train on personal GPU hardware, evaluate models, and serve them through a lightweight API or chat interface. The repository also includes datasets and tokenizer training code.

Key features

  • PyTorch model structure and tokenizer training code
  • Training workflows for pretraining, fine-tuning, LoRA, preference optimization, tool use, and distillation
  • Datasets and support for model evaluation
  • Lightweight API server and Streamlit chat interface

Best for

Learners and developers who want to understand LLM internals by reproducing small-model training. It is suited to experiments on personal GPU hardware.

Upstream
jingyaogong/minimind
Fork on GitHub
Guo-astro/minimind
Upstream stars
64k
Category
AI agents and LLM tools
License
Apache-2.0
Forked
2026-10-14
Sync status
In syncLast synced 2026-10-17