Nimendra's Notes 🪴
Search
Search
Dark mode
Light mode
Reader mode
Explorer
Home
❯
00.Fleeting Notes
❯
AI-LLM
❯
AI Agents
❯
2. LLMs and AI Agents
2. LLMs and AI Agents
Note title and URL
Table of Contents
What You Should Know About Large Language Models
LLMs inside agents
Input and Output Tokens
From Language Modeling to Powering Agents
System Prompt
Multi-turn Conversations
Tool Use
Thought → Action → Observation loop
Training a Large Language Model
Pre-training — Language Modeling
Post-training
Supervised Fine-Tuning
Mental model
The one thing to remember
Reinforcement Learning
Group Relative Policy Optimization — GRPO
Transformer Architecture
Tokenizer
Transformer blocks
LM Head
Decoding and Temperature
Higher temperature
Processing Through Transformer Blocks
Context Length
KV / Prompt Caching
Inside a Transformer Block
Feed-Forward Neural Network
Dense Models vs Mixture-of-Experts
Self-Attention — High-Level Intuition
A Deeper Dive Into Large Language Models
How Self-Attention Works
Relevance Scoring
Combining Information
KV-Caching
KV cache trade-off
More Efficient Self-Attention
DeepSeek Sparse Attention — DSA
Mixture of Experts
Experts
Router / Gate Network
Expert Load Balancing
Sparse Parameters vs Active Parameters
DeepSeek-R1 MoE Example
Graph View