Building an LLM from Scratch
In this work, the development of a basic large language model (LLM) has been presented, with a primary focus on the pre-training process and model architecture. A simplified transformer-based design has been implemented to demonstrate core LLM principles with the incorporation of reinforcement learning techniques. Key components such as tokenization, and training objectives have been discussed to provide a foundational understanding of LLM construction. Additionally, an overview of several established models—including GPT-2, LLaMA 3.1, and DeepSeek—has been provided to contextualize current advancements in the field. Through this comparative and explanatory approach, the essential building blocks of large-scale language models have been explored in a clear and accessible manner.
Authors
- Sajan Jiv Singh Nagpal (ORCID: https://orcid.org/0000-0003-3724-2081)
- Sunil Kumar (ORCID: https://orcid.org/0000-0001-6738-6815)
- Anurag Ranjan Lila (ORCID: https://orcid.org/0000-0001-7097-2831)
- R. N. Yadav (ORCID: https://orcid.org/0000-0001-5436-0851)
- V. K. Mishra (ORCID: https://orcid.org/0000-0003-3247-3235)
- Monika Sharma (ORCID: https://orcid.org/0000-0002-2630-8535)
- S.B. Rai (ORCID: https://orcid.org/0000-0002-1028-6255)
- A. P. Gandhi
- Akshat Jain
- R. Mittal
Publication Details
- Journal
- International Journal of Science and Research Archive
- Published
- 2025-04-29
- DOI
- https://doi.org/10.30574/ijsra.2025.15.1.1140
- Primary Topic
- Artificial Intelligence in Law
- Type
- article
- Field-Weighted Citation Impact
- 0.00