Large Language Model (LLM) Tutorial
Large Language Models (LLMs) are machine learning models trained on vast amount of textual data to generate and understand human-like language. These models can perform a wide range of natural language processing tasks from text generation to sentiment analysis and summarization.
Whether you're a beginner or experienced practitioner this guide will provide you fundamental knowledge needed to understand and utilize LLMs in real-world scenarios.
Transformers
Transformers are the foundational architecture behind most modern large language models that rely on attention mechanisms to process the entire sequence of the data simultaneously.
- Attention Mechanism
- Self-Attention Mechanism
- Multi-Head Attention Mechanism
- Positional Encoding
- Feed-Forward Neural Network
- Layer Normalization
- Encoder-Decoder Model
- Masked Attention
- Cross-Attention Mechanism
- Embedding Layers
- Transformers from Scratch using TensorFlow
- Transformers from Scratch using PyTorch
Large Language Models Basics
Large Language Models (LLMs) are advanced AI systems trained on massive datasets to understand and generate human-like text, powered by deep learning techniques.
- Language Models
- Foundation Models
- Seq2Seq Models
- History and Evolution of LLMs
- Multimodal LLMs
- LLM Parameters
- Tokens and Context Windows
- Chinchilla's Law
- Prompts
- Prompt Engineering
- LLM Hallucinations
- Transformers vs LLMs
- Difference between BERT and GPT
- LLM Model Evaluation
- Word Embedding
- Tokenization
- Byte Pair Encoding
- Data sampling using Sliding Window Attention
Training and Fine-Tuning LLMs
It involves using vast amount of datasets so that LLMs learn language patterns, grammar, trends, etc and fine-tune pre-trained LLM for specific tasks or domain.
Language Modeling Techniques
Fine-tuning Large Language Models
- Reinforcement Learning from Human Feedback (RLHF)
- Fine-Tune an LLM from Hugging Face
- Parameter-Efficient Fine-Tuning (PEFT)
- Fine Tuning LLMs using PEFT
- LoRA (Low-Rank Adaptation)
- QLoRA (Quantized Low-Rank Adaptation)
- Fine Tuning LLMs using QLoRA
- Prompt Tuning
- How Prompt Tuning works?
- Prompt Tuning Techniques
- Instruction Tuning
- Supervised Fine-Tuning (SFT)
- LLM Distillation
Retrieval-Augmented Generation (RAG)
- What is Retrieval-Augmented Generation (RAG)?
- RAG vs Traditional QA
- Fine tuning vs RAG
- Dense Passage Retrieval (DPR)
- Vector Database
- Chunking in RAG
- Agentic RAG
- Mutlimodal RAG
- How to build RAG Pipeline for LLMs?
- Evaluation Metric for RAG
Prompting Techniques
- Zero-Shot Prompting
- Few-Shot Prompting
- Chain-of-Thought (CoT) Prompting
- Self-Consistency Prompting
- Zero-Shot Chain-of-Thought Prompting
- ReAct (Reasoning + Acting) Prompting
- Retrieval-Augmented Prompting
Popular Large Language Models
Popular LLMs such as GPT, BERT and T5 have revolutionized NLP tasks with their ability to generate, understand and manipulate text across various applications.
- GPT (Generative Pre-trained Transformer)
- BERT (Bidirectional Encoder Representations from Transformers)
- T5 (Text-to-Text Transfer Transformer)
- LLaMA
- Claude
- LCM (Large Concept Models)
- Falcon
Evaluation of LLMs
Applications of LLMs
LLMs are used in various real-world applications including:
1. Chatbots/ Conversational AI
2. Sentiment Analysis
3. Text Generation
4. Language Translation
Large Language Models (LLM) and Generative AI are becoming essential skills for anyone aspiring to work in AI, natural language processing or creative industries. Learn these cutting-edge technologies with Mastering Generative AI and ChatGPT, designed and curated by industry experts with years of experience in LLMs, deep learning and real-world AI applications.