hamzafarooq/building-llm-applications-from-scratch

Code and Slides

Jupyter Notebook

2,392

45 commits

updated May 25, 2025

See the code

README

Building LLM Applications from Scratch

๐Ÿš€ Build LLM-Powered Applications Like a Pro!

Welcome to the Open Sourced version of my course on LLMs.

This course is one of the top-rated technical courses on building Large Language Model (LLM) applications from the ground up. So far, Iโ€™ve taught this course to over 1500 professionals, at MAVEN, Stanford, UCLA and University of Minnesota, helping them gain a deep understanding of Transformer Architecture, Retrieval-Augmented Generation (RAG), and open-source LLM deployment.

Unlike most courses that focus on pre-built frameworks like LangChain, this course goes beyond by diving into the building blocks of retrieval systems, enabling you to design, build, and deploy your own custom LLM-powered solutions.

๐ŸŒŽ Also featured in Stanford's AI Leadership Series:
๐Ÿ”— Stanford AI Leadership Series - Building and Scaling AI Solutions


๐Ÿ“Œ Learning Outcomes

  • Gain a comprehensive understanding of LLM architecture
  • Construct and deploy real-world applications using LLMs
  • Learn the fundamentals of search and retrieval for AI applications
  • Understand encoder and decoder models at a deep level
  • Train, fine-tune, and deploy LLMs for enterprise use cases
  • Implement RAG-based architectures with open-source models

๐Ÿ“ข Who is This Course For?

This course is not for beginners. It requires:
โœ… Python programming skills
โœ… Basic machine learning knowledge

It is designed for:
๐Ÿ”น Machine Learning Engineers
๐Ÿ”น Data Scientists
๐Ÿ”น AI Researchers
๐Ÿ”น Software Engineers interested in LLMs


๐Ÿ“Œ What Youโ€™ll Learn

โœ” Collect and preprocess data for LLM applications
โœ” Train and fine-tune pre-trained LLMs for specific tasks
โœ” Evaluate model performance with appropriate metrics
โœ” Deploy LLM applications via APIs and Hugging Face
โœ” Address ethical concerns in AI development


๐Ÿ“š Whatโ€™s Included?

โœ… 29 in-depth lessons covering LLM architectures and RAG techniques
โœ… 6 real-world projects to apply your learnings
โœ… Interactive live sessions and direct instructor access
โœ… Guided feedback & reflection
โœ… Private community of peers
โœ… Certificate upon completion


๐Ÿ“ข Attribution & Credits

If you use my course material, content, or research in your work, please credit me and the respective contributors.

๐Ÿ”น Proper citation format:

Farooq, H. (2024). Building LLM Applications from Scratch
Stanford Continuing Studies: The AI Leadership Series

๐Ÿ“Œ Tagging & mentions are always appreciated! ๐Ÿ˜Š

๐Ÿ“… Course Syllabus

Week 1: Introduction to NLP

  • Understanding natural language processing fundamentals
  • Tokenization, embeddings, and vector representations

Week 2: Transformers & LLM System Design

  • The evolution of Transformer models
  • Understanding encoder-decoder architectures

Week 3: Semantic Search & Retrieval

  • Implementing vector search for LLM applications
  • Introduction to RAG-based architectures

Week 4: Building a Search Engine from Scratch

  • Developing a custom RAG solution
  • Optimizing search and retrieval pipelines

Week 5: The Generation Part of LLMs

  • Fine-tuning models for text generation tasks
  • Optimizing inference for real-time applications

Week 6: Prompt-Tuning, Fine-Tuning & Local LLMs

  • Techniques for efficient inference & quantization
  • Deploying custom LLMs at scale

๐ŸŽ‰ Post-Course: Demo Day โ€“ Present your final project!


โญ What Students Are Saying

"This course was amazing! I left feeling empowered and ready to build my own LLM-powered applications."
โ€“ Tiffany Teasley, Data Scientist

"Hamzaโ€™s approach to teaching is practical and engaging. The real-world projects made all the difference!"
โ€“ Victor Calderon, Senior ML Engineer

"One of the best courses for LLM applications! Highly recommended for anyone serious about the field."
โ€“ Abhinav, Security Researcher


๐Ÿ”ฅ Why Take This Course?

Unlike most AI courses that rely on pre-built frameworks, this course teaches you how to build LLM applications from scratchโ€”without LangChain or LlamaIndex.

By the end, youโ€™ll be able to:
โœ… Build highly customizable LLM applications
โœ… Optimize retrieval and search strategies
โœ… Deploy cost-efficient and scalable AI solutions


Significant stargazers

Frederick Ros

180 followers ยท starred Mar 2025

mubashir1osmani

21 followers ยท starred Mar 2025

Raunak Kumar Pandey

35 followers ยท starred Jun 2025

Himanshu Kumar

11 followers ยท starred Mar 2025

hamzafarooq/building-llm-applications-from-scratch

Code and Slides

Jupyter Notebook

2,392

45 commits

updated May 25, 2025

See the code

README

Building LLM Applications from Scratch

๐Ÿš€ Build LLM-Powered Applications Like a Pro!

Welcome to the Open Sourced version of my course on LLMs.

This course is one of the top-rated technical courses on building Large Language Model (LLM) applications from the ground up. So far, Iโ€™ve taught this course to over 1500 professionals, at MAVEN, Stanford, UCLA and University of Minnesota, helping them gain a deep understanding of Transformer Architecture, Retrieval-Augmented Generation (RAG), and open-source LLM deployment.

Unlike most courses that focus on pre-built frameworks like LangChain, this course goes beyond by diving into the building blocks of retrieval systems, enabling you to design, build, and deploy your own custom LLM-powered solutions.

๐ŸŒŽ Also featured in Stanford's AI Leadership Series:
๐Ÿ”— Stanford AI Leadership Series - Building and Scaling AI Solutions


๐Ÿ“Œ Learning Outcomes

  • Gain a comprehensive understanding of LLM architecture
  • Construct and deploy real-world applications using LLMs
  • Learn the fundamentals of search and retrieval for AI applications
  • Understand encoder and decoder models at a deep level
  • Train, fine-tune, and deploy LLMs for enterprise use cases
  • Implement RAG-based architectures with open-source models

๐Ÿ“ข Who is This Course For?

This course is not for beginners. It requires:
โœ… Python programming skills
โœ… Basic machine learning knowledge

It is designed for:
๐Ÿ”น Machine Learning Engineers
๐Ÿ”น Data Scientists
๐Ÿ”น AI Researchers
๐Ÿ”น Software Engineers interested in LLMs


๐Ÿ“Œ What Youโ€™ll Learn

โœ” Collect and preprocess data for LLM applications
โœ” Train and fine-tune pre-trained LLMs for specific tasks
โœ” Evaluate model performance with appropriate metrics
โœ” Deploy LLM applications via APIs and Hugging Face
โœ” Address ethical concerns in AI development


๐Ÿ“š Whatโ€™s Included?

โœ… 29 in-depth lessons covering LLM architectures and RAG techniques
โœ… 6 real-world projects to apply your learnings
โœ… Interactive live sessions and direct instructor access
โœ… Guided feedback & reflection
โœ… Private community of peers
โœ… Certificate upon completion


๐Ÿ“ข Attribution & Credits

If you use my course material, content, or research in your work, please credit me and the respective contributors.

๐Ÿ”น Proper citation format:

Farooq, H. (2024). Building LLM Applications from Scratch
Stanford Continuing Studies: The AI Leadership Series

๐Ÿ“Œ Tagging & mentions are always appreciated! ๐Ÿ˜Š

๐Ÿ“… Course Syllabus

Week 1: Introduction to NLP

  • Understanding natural language processing fundamentals
  • Tokenization, embeddings, and vector representations

Week 2: Transformers & LLM System Design

  • The evolution of Transformer models
  • Understanding encoder-decoder architectures

Week 3: Semantic Search & Retrieval

  • Implementing vector search for LLM applications
  • Introduction to RAG-based architectures

Week 4: Building a Search Engine from Scratch

  • Developing a custom RAG solution
  • Optimizing search and retrieval pipelines

Week 5: The Generation Part of LLMs

  • Fine-tuning models for text generation tasks
  • Optimizing inference for real-time applications

Week 6: Prompt-Tuning, Fine-Tuning & Local LLMs

  • Techniques for efficient inference & quantization
  • Deploying custom LLMs at scale

๐ŸŽ‰ Post-Course: Demo Day โ€“ Present your final project!


โญ What Students Are Saying

"This course was amazing! I left feeling empowered and ready to build my own LLM-powered applications."
โ€“ Tiffany Teasley, Data Scientist

"Hamzaโ€™s approach to teaching is practical and engaging. The real-world projects made all the difference!"
โ€“ Victor Calderon, Senior ML Engineer

"One of the best courses for LLM applications! Highly recommended for anyone serious about the field."
โ€“ Abhinav, Security Researcher


๐Ÿ”ฅ Why Take This Course?

Unlike most AI courses that rely on pre-built frameworks, this course teaches you how to build LLM applications from scratchโ€”without LangChain or LlamaIndex.

By the end, youโ€™ll be able to:
โœ… Build highly customizable LLM applications
โœ… Optimize retrieval and search strategies
โœ… Deploy cost-efficient and scalable AI solutions


Significant stargazers

Frederick Ros

180 followers ยท starred Mar 2025

mubashir1osmani

21 followers ยท starred Mar 2025

Raunak Kumar Pandey

35 followers ยท starred Jun 2025

Himanshu Kumar

11 followers ยท starred Mar 2025