In today's era of rapid development of large language model (LLM) technology, most developers use these models as "black boxes"—inputting prompts and getting outputs, but knowing little about their internal working mechanisms. This state of "knowing the what but not the why" limits our ability to truly understand and optimize these powerful tools.
The miniature-llms project was created to address this issue. It is an educational open-source project that implements all core components of modern large language models from scratch using two mainstream deep learning frameworks: PyTorch and JAX. The core philosophy of the project is: "Build models at a 1/1000 scale—structures are real, losses will decrease, but don't expect inference results."