Ex-Google Jeff Dean just released the best 1-hour lecture on AI engineering: from basics to Graphs
1:45 - LLM from scratch
17:22 - How to use AI models
30:03 - Prompt engineering
52:35 - One human coordinating 100 agents
27 years of building AI at Google, compressed into one hour.
Watch it, then read the full guide on Graph engineering below.
Someone turned the hardest parts of LLM inference engineering into a course where you have to fix the performance problems yourself.
And you can do it on a Mac.
The project is called tiny-llm, an open-source course for building a miniature vLLM-style inference engine around Qwen3.
It starts with a simple implementation using matrix operations. You build attention, normalization, positional encoding, the Transformer layers, and the loop that generates tokens.
You have a working model.
Now the interesting engineering begins.
During decoding, repeatedly processing the previous tokens wastes computation. So you implement a KV cache and reuse previously computed attention state.
Next, you look at model weights. Keeping everything in dense BF16 consumes memory bandwidth. So you retain packed 4-bit weights and implement specialized matrix operations.
Then you move into Metal kernels, SIMD matrix operations, fused RMSNorm, RoPE, SwiGLU, and tiled prefill attention.
Once the single-request engine works, you tackle a different problem.
What happens when multiple requests arrive, each with different prompt lengths and different amounts of cached state?
You implement continuous batching, chunked prefill, paged KV storage, and attention that reads directly from noncontiguous cache pages.
The four-week curriculum eventually extends into a small coding-agent harness with validated tool calls, checkpoints, context management, and evaluation.
Every stage comes with exercises, reference implementations, tests, and measurements to help you understand the behavior of the system you're building.
The course uses MLX, C++, and Metal on Apple Silicon. You don't need an NVIDIA GPU, and the introductory path supports Qwen3-0.6B on an 8GB Mac.
Some later checkpoints remain under development and review, but there's already a substantial amount of real inference engineering to learn from.
The GitHub repo has crossed 4,800 stars.
GitHub: https://t.co/mTRsVjMvkO
I have been fine-tuning LLMs for over 3 years now.
Here are 5 LLM fine-tuning techniques, explained with visuals:
Traditional fine‑tuning is impractical for LLMs (billions of params; 100s of GB).
Since this kind of compute isn't accessible to everyone, parameter-efficient fine-tuning techniques (PEFT) were built.
Before we go into details of each technique, here's some background that will help you better understand these techniques:
LLM weights are matrices of numbers adjusted during fine-tuning.
Most PEFT techniques involve finding a lower-rank adaptation of these matrices, a smaller-dimensional matrix that can still represent the information stored in the original.
Now with a basic understanding of the rank of a matrix, we're in a good position to understand the different fine-tuning techniques.
(refer to the image below for a visual explanation of each technique)
1) LoRA
- Add two low-rank trainable matrices, A and B, alongside the weight matrices.
- Instead of fine-tuning W, adjust the updates in these low-rank matrices.
Even for the largest LLMs, LoRA matrices take up a few MBs of memory.
2) LoRA-FA
While LoRA significantly decreases the total trainable parameters, it requires substantial activation memory to update the low-rank weights.
LoRA-FA (FA stands for Frozen-A) freezes matrix A and only updates matrix B.
3) VeRA
- In LoRA, low-rank matrices A and B are unique for each layer.
- In VeRA, A and B are frozen, random, and shared across all layers.
- Instead, it learns layer-specific scaling VECTORS (b and d) instead.
4) Delta-LoRA
- It tunes the matrix W as well, but not in the traditional way.
- Here, the difference (or delta) between the product of matrices A and B in two consecutive training steps is added to W.
5) LoRA+
- In LoRA, both matrices A and B are updated with the same learning rate.
- Authors of LoRA+ found that setting a higher learning rate for matrix B results in better convergence.
____
Find me → @_avichawla
Every day, I share tutorials and insights on DS, ML, LLMs, and RAGs.
RAG isn’t just connecting an LLM to a database.
It’s about building reliable AI systems.
→ Chunking & Embeddings
→ Vector Databases
→ Hybrid Search & Reranking
→ Query Rewriting
→ Multi-Query RAG
→ Agentic & Graph RAG
→ Evaluation & Grounded Answers
Bookmark this.
#AI
There are 2 career paths in AI right now:
The API Caller:
Knows how to build with LLMs.
The Architect:
Knows how LLM systems are built.
If you want to move toward the second, Stanford has one of the best free LLM engineering playlists on YouTube:
CS336: Language Modeling from Scratch.
The 2026 course has 18 lectures covering almost the entire LLM stack -
➡️ Build the model: Tokenization, Transformers, architectures, MoE
➡️ Understand the hardware: FLOPs, memory, GPUs, TPUs
➡️ Make it fast: Triton, GPU kernels, parallelism, distributed training
➡️ Train it: Scaling laws, data collection, filtering, deduplication
➡️ Run it: Inference, evaluation
➡️ Post-train it: SFT, RLHF, RLVR
Plus multimodality.
And you don’t only watch lectures.
> You implement the tokenizer, Transformer and optimizer.
> You write FlashAttention2 in Triton.
> You build memory-efficient distributed training.
> You turn raw Common Crawl dumps into pretraining data.
> You fit a scaling law.
> You use SFT + reinforcement learning to train a language model for mathematical reasoning.
Stanford says students write at least an order of magnitude more code than in most other AI classes.
Stanford CS336. Spring 2026. 18 lectures. Free on YouTube.
Choose your path.
(Playlist in the comments)
♻️ Repost to save someone $$$ and a lot of confusion.
6 parallelism strategies for LLM inference in production:
(popular LLM interview question)
Running a model across four GPUs does not merge their memory into one shared pool.
Each GPU has its own memory, so data stored on another GPU must cross the interconnect before a layer can use it.
This is the central trade-off behind parallelism. It removes local memory or compute limits but adds communication overhead.
The visual below explains the six common strategies for parallelizing LLM inference:
- Data parallelism runs complete model replicas on separate GPU groups. It increases throughput, but cannot make an oversized model fit.
- Tensor parallelism splits matrix operations inside each transformer layer. It reduces weight memory per GPU, but the GPUs must combine partial results throughout the layer stack.
- Pipeline parallelism assigns layer groups to different GPUs. Activations move between stages, while insufficient micro-batching leaves some stages idle.
- Context parallelism splits sequence positions in two ways. Prefill context parallelism divides a long input across GPUs to target lower TTFT. Decode context parallelism divides the stored KV history to increase cache capacity, but every decoder layer must merge partial attention results.
- Expert parallelism distributes MoE experts across GPUs. Token routing and uneven expert load add network cost and idle time.
- Hybrid parallelism combines multiple strategies in one deployment. For example, tensor parallelism can operate within a node, pipeline parallelism across nodes, and data parallelism across model replicas. This matches each communication pattern to the available links, but adds more coordination paths.
Production deployments often combine methods, but each one should fix a measured bottleneck.
- If the weights do not fit, use tensor or pipeline parallelism.
- If long-prompt prefill or KV-cache capacity is the limit, use the corresponding form of context parallelism.
- MoE models may need expert parallelism to place expert weights.
- If one replica meets its latency target but requests still queue, add data-parallel replicas.
Keep tensor parallelism on the fastest links. After each change, measure memory, TTFT, TPOT, and other metrics again.
Add another method only when measurements reveal another bottleneck.
I wrote a detailed article explaining how each strategy works, where communication occurs, and how to choose a layout for a real deployment.
Read it below.
You can literally type a sentence and watch a Transformer process it.
This interactive explainer runs a GPT-style model in the browser and lets you follow the whole path:
tokenization → embeddings → Q/K/V → attention → MLP → logits → next-token probabilities
You can inspect attention maps, intermediate values, and change temperature, top-k and top-p to see how generation changes.
If Transformers still feel like boxes connected by arrows, this is worth opening.
https://t.co/vkyxOqDVll
Linux Fundamentals Guide — Vol. 03
Download here : https://t.co/R0ftSTp1vw
Only for serious Linux & cybersecurity learners
Beginner → Advanced Linux
this is f**king dangerous.
someone just open sourced an entire library of ready-made JEV skills for building insane AI agent workflows.
instead of building common agent patterns from scratch, you can grab skills for things like:
→ jev-route for routing tasks
→ jev-guardrail for adding checks and verification
→ jev-fanout for running multiple tasks in parallel
→ reusable skills you can plug into your own workflows
the interesting part is that these solve problems you'll run into once your agents start doing more than simple tasks.
you don't have to reinvent routing, verification, or parallel execution every time you build a new workflow.
save this now.
you'll probably need one of these skills the next time you're building an agent and don't want to start from scratch.
repo below:
Andrej Karpathy:
"Prompting is going away.
Delete everything, keep Graph."
In 1 hour he shows how to build Graphs, and why it's the only thing that will be left standing at the end.
Anyone can build an agent, almost no one builds the Graph that runs them.
Watch it, then read the full guide on Graphs below.
I've asked Astra to read the DeepSeek v4.1 Flash paper and compare it to the original Transformer architecture in 3D - you can zoom in an inspect each element side by side. Things have changed quite a bit.
Try yourself: https://t.co/ESxu7fYGlG
Goldmine for AI Engineers! 📌
If you're learning AI, ML, LLMs, or AI agents, don't waste hours jumping between random tutorials.
These are 10 repositories I'd actually keep bookmarked - from Python fundamentals to ML, LLMs, agents, and production AI.
1. Python - 100 Days
jackfrued/Python-100-Days
A 100-day Python learning path covering fundamentals, data analysis, web development, and more.
GitHub:
https://t.co/4wgQvkXE5K
2. Generative AI for Beginners
microsoft/generative-ai-for-beginners
A practical introduction to building Generative AI applications.
Covers:
• LLM fundamentals
• Prompt engineering
• RAG
• AI agents
• Fine-tuning
• AI application development
GitHub:
https://t.co/msVKJDOmqv
3. LLMs From Scratch
rasbt/LLMs-from-scratch
Want to understand what's actually happening inside an LLM?
Build one step by step.
Covers:
• Tokenization
• Embeddings
• Attention
• Transformers
• Training
• Fine-tuning
GitHub:
https://t.co/JINAI38zMD
4. Machine Learning for Beginners
microsoft/ML-For-Beginners
A structured 12-week, 26-lesson curriculum covering classical machine learning.
A good starting point if you want ML fundamentals before jumping into LLMs.
GitHub:
https://t.co/PGAj8GdlIc
5. OpenAI Cookbook
openai/openai-cookbook
A collection of practical examples and guides for building applications with OpenAI models.
Useful when you want to move from:
Learning → Building
GitHub:
https://t.co/n1Gu2273nY
6. Stable Diffusion
CompVis/stable-diffusion
Interested in generative image models?
This repository contains the original Stable Diffusion implementation and research code.
GitHub:
https://t.co/r1sPdSQgSR
7. AI Agents for Beginners
microsoft/ai-agents-for-beginners
A practical course for understanding and building AI agents.
Covers:
• Agentic AI
• RAG
• Agent frameworks
• Tool use
• Multi-agent systems
GitHub:
https://t.co/mQncZRuIyz
8. AI for Beginners
microsoft/AI-For-Beginners
A structured 12-week, 24-lesson introduction to AI.
Covers:
• Neural networks
• Computer vision
• NLP
• Deep learning
• Classical AI
GitHub:
https://t.co/UuSrvYalBd
9. LLM App
pathwaycom/llm-app
Focused on building practical LLM applications.
Explore:
• RAG
• AI pipelines
• Enterprise search
• Real-time data
• Vector search
GitHub:
https://t.co/DXcibjxGn3
10. Segment Anything
facebookresearch/segment-anything
A foundation model for promptable image segmentation.
Worth exploring if you're interested in computer vision and multimodal AI.
GitHub:
https://t.co/otXdFtpZO3
Don't bookmark all 10 and forget about them.
Pick based on where you are:
Python → Python-100-Days
ML → ML-For-Beginners
AI Fundamentals → AI-For-Beginners
LLMs → LLMs-from-scratch
Generative AI → Generative-AI-for-Beginners
Agents → AI-Agents-for-Beginners
Building → OpenAI Cookbook / LLM App
Computer Vision → Segment Anything
Pick one.
Build something.
Then move to the next.