awesome-repositories.com
Blog
MCP
awesome-repositories.com

Entdecke die besten Open-Source-Repositories mit KI-gestützter Suche.

EntdeckenKuratierte SuchenOpen-Source-AlternativenSelf-hosted SoftwareBlogSitemap
ProjektÜber unsRanking-MethodikPresseMCP-Server
RechtlichesDatenschutzAGB
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
datawhalechina avatar

datawhalechina/llms-from-scratch-cn

0
View on GitHub↗
4,211 Stars·581 Forks·Jupyter Notebook·6 Aufrufe

Llms From Scratch Cn

Dieses Projekt ist ein Bildungskurs mit Lehrmaterialien, um Large Language Models von Grund auf mit Python zu entwickeln. Es bietet eine Schritt-für-Schritt-Anleitung und praktische Tutorials, die sich auf die internen Mechanismen von Transformer-Architekturen und Pre-Training-Workflows konzentrieren.

Das Repository enthält ein Framework zur Implementierung und zum Vergleich verschiedener Modellfamilien, darunter Llama, GLM und RWKV. Es nutzt einen konfigurationsgesteuerten Ansatz, um die strukturellen Unterschiede und internen Mechanismen dieser Architekturen zu analysieren.

Die Codebasis deckt die komplette Entwicklungspipeline ab, einschließlich Text-Preprocessing, Byte-Pair-Encoding und der Implementierung von Multi-Head-Attention mit kausaler Maskierung. Zudem sind Trainings-Utilities wie Gradient Clipping, Learning Rate Scheduling und Hyperparameter-Optimierung für das Pre-Training auf ungelabelten Korpora enthalten.

Das Projekt ist in Jupyter Notebooks umgesetzt.

Features

  • Generative Models - Implements a complete pipeline for building generative language models from scratch, including tokenization and pre-training.
  • Large Language Model Curricula - Offers a structured educational program for learning the internal mechanics of transformer-based language models.
  • Causal - Implements causal masking to prevent the model from attending to future tokens during autoregressive generation.
  • Attention Mechanisms - Implements scaled dot-product and multi-head attention to demonstrate how models weight token importance.
  • Foundation Model Pre-training - Implements the process of training base language models from scratch on large unlabeled corpora.
  • Language Model Pre-training - Implements the full pre-training process, including data preprocessing and training loops on raw text corpora.
  • Large Language Models - Provides a comprehensive implementation of modern large-scale language model architectural components.
  • Llama Architectures - Implements the structural configurations and transformer blocks specific to the Llama model family.
  • LLM Implementations - Provides concrete software implementations of diverse LLM architectures like Llama and GLM.
  • Byte Pair Encodings - Implements subword tokenization using the byte-pair encoding algorithm to handle text corpora.
  • Multi-Head Attention Mechanisms - Implements multi-head attention mechanisms to capture diverse linguistic relationships in parallel subspaces.
  • Transformer Blocks - Stacks attention mechanisms and feed-forward networks into repetitive transformer blocks for hierarchical representation.
  • Pre-training Tutorials - Provides practical instructions for cleaning text and training models on unlabeled corpora.
  • LLM Education - Serves as an educational resource for implementing large language models from the ground up.
  • Transformer Implementations - Provides pedagogical, from-scratch implementations of transformer architectures using basic Python frameworks.
  • Generative AI Prototyping - Provides a complete pipeline for prototyping functional text generation systems from scratch.
  • Gradient Clipping - Provides training utilities that combine learning rate scheduling with gradient clipping for stable convergence.
  • Model Architecture Analysis - Provides a framework to inspect model definitions and configurations to analyze the structural mechanisms of different model families.
  • Model Architecture Comparisons - Implements and compares diverse model families like Llama, GLM, and RWKV to analyze structural differences.
  • Sliding-Window Data Segmentation - Generates overlapping input and target sequence pairs from continuous text using a sliding window.
  • Text Preprocessing Pipelines - Implements an automated pipeline for cleaning and formatting raw text data before model consumption.
  • Training Dataset Preparation - Provides a process for tokenizing raw text and preparing overlapping sequences for model training.
  • Mathematical Equivalence Analysis - Demonstrates the mathematical equivalence between embedding layers and fully connected layers using one-hot encoded vectors.
  • Configuration-Driven Assembly - Uses external configuration files to instantiate and assemble different model architectures from shared components.
  • Courses and Tutorials - Chinese course on building LLMs from scratch.
  • Learning Resources - Chinese-language guide to building LLMs.

Star-Verlauf

Star-Verlauf für datawhalechina/llms-from-scratch-cnStar-Verlauf für datawhalechina/llms-from-scratch-cn

KI-Suche

Entdecke weitere awesome Repositories

Beschreibe in einfachen Worten, was du brauchst — die KI bewertet tausende kuratierte Open-Source-Projekte nach Relevanz.

Start searching with AI

Open-Source-Alternativen zu Llms From Scratch Cn

Ähnliche Open-Source-Projekte, sortiert nach der Anzahl der gemeinsamen Funktionen mit Llms From Scratch Cn.
  • datawhalechina/so-large-lmAvatar von datawhalechina

    datawhalechina/so-large-lm

    7,400Auf GitHub ansehen↗

    This project is a comprehensive educational curriculum and structured learning path covering the full lifecycle of large language models. It provides a guided progression through the theory, architecture, training, and deployment of these models. The curriculum includes specialized guides on transformer architecture, model training tutorials, and frameworks for designing autonomous agents. It also provides dedicated resources for studying model safety and ethics. The material covers a wide range of technical capabilities, including distributed training strategies, parameter-efficient fine-tu

    Auf GitHub ansehen↗7,400
  • naklecha/llama3-from-scratchAvatar von naklecha

    naklecha/llama3-from-scratch

    15,230Auf GitHub ansehen↗

    This project is a manual reconstruction of the Llama 3 transformer architecture implemented as a PyTorch neural network. It serves as a reference for the internal mathematical structure and tensor flow of a transformer-based language model designed for next token prediction. The implementation focuses on building the model from scratch using basic matrix operations and tensor manipulations. It demonstrates the manual construction of core components, including rotary positional embeddings, multi-head self-attention, and root mean square normalization. The codebase covers the full inference pi

    Jupyter Notebook
    Auf GitHub ansehen↗15,230
  • nndl/llm-beginnerAvatar von nndl

    nndl/llm-beginner

    6,421Auf GitHub ansehen↗

    This project is a collection of educational resources and technical guides focused on the development and implementation of large language models. It provides a comprehensive curriculum covering transformer architectures, training methods, and deployment strategies. The materials provide detailed instructions for building autonomous agents using reasoning loops and tool integration, as well as guides for fine-tuning models through supervised learning and preference optimization. It also includes tutorials for constructing retrieval augmented generation pipelines and implementing transformer m

    Pythonagentfudannlpllm
    Auf GitHub ansehen↗6,421
  • jadore801120/attention-is-all-you-need-pytorchAvatar von jadore801120

    jadore801120/attention-is-all-you-need-pytorch

    9,742Auf GitHub ansehen↗

    This project is a Transformer machine translation model and attention-based neural network implemented using the PyTorch deep learning framework. It functions as a text-to-text translation tool designed to convert source sequences into target language text. The implementation focuses on neural machine translation, covering the development of sequence-to-sequence architectures. It includes the full pipeline for translation, from text sequence preprocessing and vocabulary creation to model training and text generation inference. The system incorporates standard transformer components such as a

    Pythonattentionattention-is-all-you-needdeep-learning
    Auf GitHub ansehen↗9,742
Alle 30 Alternativen zu Llms From Scratch Cn anzeigen→

Häufig gestellte Fragen

Was macht datawhalechina/llms-from-scratch-cn?

Dieses Projekt ist ein Bildungskurs mit Lehrmaterialien, um Large Language Models von Grund auf mit Python zu entwickeln. Es bietet eine Schritt-für-Schritt-Anleitung und praktische Tutorials, die sich auf die internen Mechanismen von Transformer-Architekturen und Pre-Training-Workflows konzentrieren.

Was sind die Hauptfunktionen von datawhalechina/llms-from-scratch-cn?

Die Hauptfunktionen von datawhalechina/llms-from-scratch-cn sind: Generative Models, Large Language Model Curricula, Causal, Attention Mechanisms, Foundation Model Pre-training, Language Model Pre-training, Large Language Models, Llama Architectures.

Welche Open-Source-Alternativen gibt es zu datawhalechina/llms-from-scratch-cn?

Open-Source-Alternativen zu datawhalechina/llms-from-scratch-cn sind unter anderem: datawhalechina/so-large-lm — This project is a comprehensive educational curriculum and structured learning path covering the full lifecycle of… naklecha/llama3-from-scratch — This project is a manual reconstruction of the Llama 3 transformer architecture implemented as a PyTorch neural… nndl/llm-beginner — This project is a collection of educational resources and technical guides focused on the development and… jadore801120/attention-is-all-you-need-pytorch — This project is a Transformer machine translation model and attention-based neural network implemented using the… pageman/sutskever-30-implementations — This project is a collection of deep learning research implementations and a reproduction kit designed to translate… d2l-ai/d2l-en — This project is an educational platform and research toolkit designed to teach deep learning through a combination of…