
Explore the fundamentals of Gen AI and large language models, and learn LangChain basics. Set up OpenAI, run llama and mistral, and build Streamlit interfaces with prompt templates.
Download lecture slides from the lecture resources, unzip the zip file to access the keynote and PowerPoint files for Mac and Windows, and share the knowledge with friends and colleagues.
Download a zip file from the lecture resources to access the completed project with all scripts and assignment solutions, provided as reference while you code from scratch during hands-on lectures.
Download a PDF of all prompts organized by section and use case, copy prompts into your code for hands-on lectures, with assignment prompts and solutions included.
Discover how generative ai differs from traditional ai, machine learning, and deep learning, and learn data collection, 80/20 splits, model training, testing, tuning, and production.
Understand OpenAI and why the API matters for integrating AI models into apps, via RESTful calls with Python or JavaScript libraries.
Explore OpenAI and Google Gemini alongside open-source models like Lama, Gemma, and Mistral using Langchain. Learn to run these locally with RAM guidelines and API key considerations via Ollama.
Explore how Lang Chain streamlines LLM powered apps by abstracting boilerplate, enabling seamless switching between models (OpenAI chat, chatollama, Google generative AI) and supporting vectors, documents, and AI agents.
Learn to create and access an OpenAI account through sign up, email, or single sign-on. Navigate the basics, manage profile and billing, and view usage and free credits.
Set up an OpenAI API key securely, create and name the secret key, and configure environment variables on Windows, macOS, or Linux to enable API calls in your program.
Learn to run open source models locally with ollama for LangChain integration. Install, pull Gemma 2b, list and run models, and access the local API at localhost:11434.
Set up a Lang Chain Python project named Lang Chain demo in PyCharm, then install the Lang Chain base package, Lang Chain OpenAI, and the community integration.
Discover how to access OpenAI models with LangChain by creating a Python file, reading the OpenAI API key from environment variables, and invoking a GPT-4o chat LLM with a prompt.
Install langchain-community and run the gemma model locally with Ollama in a PyCharm project, then invoke the llm to compare gemma's responses with the OpenAI model.
Learn to build beautiful web apps with Streamlit, a Python framework, by installing it, importing st, and using widgets like title and text input to run a local server.
Install Streamlit in your PyCharm project and build a live Q&A web app with Streamlit text_input and st.write, then run and deploy via Streamlit Community Cloud.
Turn on debugging to view LangChain's behind-the-scenes activity, including LLM run, prompts, and token usage. Import the debug method and set the flag to true to reveal the console log.
Learn to use the LangChain prompt template class to create reusable prompts with placeholders, supply dynamic input variables, and leverage a validation layer for reliable integration with the LangChain API.
See prompt template in action by turning a Streamlit demo into a cuisine info app. Define the template, pass in the country variable, and invoke format to render dynamic answers.
Learn how to extend a LangChain app by adding placeholders for the number of paragraphs and the target language, enabling user control over output length and language.
Improve prompts using a prompt engineering technique to handle fictional places, demonstrate 'I don't know' responses, and update the prompt to instruct models to avoid fictional content.
Launch the llama open source model locally with Ollama, use the 3.2 latest version, run it via command line, and prepare to convert GPT apps to llama for upcoming assignments.
Open source travel guide app built with LangChain and Ollama runs locally with a llama model, using prompt templates and Streamlit, no API key required.
Explore the lang chain expression language and chains to declaratively run prompts and LLMs, build simple and regular sequential chains, and manage multiple inputs and outputs in LangChain.
Demonstrate the simplest long chain using LCEL by replacing placeholders with a dictionary of city, month, language, and budget, yielding results like the Statue of Liberty.
Explains a speech generator use case with a simple sequential chain and a regular sequential chain, where a topic yields a title and a speech, with emotion in the chain.
Demonstrate a simple sequential chain in LangChain to generate a speech: create a title prompt, then a speech prompt, and run the two chained prompts with a topic.
Print the title to the web browser using a lambda expression with a pipe and a tuple, and return it to the next chain via the string output parser.
Learn how to integrate multiple LLMs in one app, using GPT to generate the title and Mistral to generate the speech, highlighting task specialization and cost considerations.
Explore the sequential chain in action by building a two-step speech generator that passes title and emotion between chains, powered by a lambda pass and Streamlit demo.
Explore formatting the chain output as JSON, define keys for title and speech, parse with a JSON output parser, and pass the dict between LangChain components.
Organize the project by creating folders basics, prompt templates, and chains, then move demos into their topic folders.
Learn why maintaining chat history matters and how to use the chart prompt template in LangChain, including system, human, and AI roles and history handling.
Learn to implement chat prompt template with messages in LangChain, setting a system role like agile coach and using dynamic user input. Manage chat history to support contextual conversations.
Walk through maintaining chat history in a LangChain app by injecting chat history placeholder into the prompt and using runnable with message history. Manage sessions with a unique session id.
Learn to maintain chat history in LangChain with the Streamlit chat message history, injecting the entire history into the prompt template for context.
Print and inspect the chain history to see how questions and answers accumulate, and learn how to summarize and reuse this history in a Langchain beginner workflow.
Maintain chat history without Streamlit by using print and input in a standalone Python program, and store history with LangChain's in-memory chart_message_history for continuous q&a.
Explore how text embeddings convert words and sentences into vectors that capture meaning and relationships, enabling similarity comparisons for document similarity, search engines, recommendations, and translation.
See embeddings in action with the OpenAI embeddings class, use embed_query to obtain text and sentence vectors, and inspect the resulting embeddings as vector representations of language context.
Build a similarity finder that compares embeddings of two texts to output a cosine-based similarity score between 0 and 1 using numpy dot.
Learn to use the llama model to produce embeddings with lang chain ollama, replacing openai embeddings, and run a quick test with text to obtain embeddings from llama 3.2.
Store and retrieve data with vector stores and embeddings to enable similarity search in Lang chain. Break data into chunks, compute embeddings, index them, and query to return matching chunks.
Demonstrates building a semantic, embedding-based job search app by loading a text file, chunking into 200-character pieces with overlap, and storing embeddings in an in-memory chroma vector store.
Implement a job search helper using LangChain to load a document, split it into chunks with the recursive character splitter, and query a chroma vector store via OpenAI embeddings.
See how the job search helper uses a vector store and embeddings to perform semantic search, returning documents with metadata and page content for data analysis, machine learning, and more.
Use a retriever from the vector database to submit plain text, generate embeddings, and query the vector store via the invoke method to obtain semantic search results.
Replace OpenAI embeddings with olama embeddings to run the job search helper using the llama model, with documents loaded into a vector store.
Understand retrieval augmented generation, or rag, which blends prompts with the most relevant data from a vector store to improve LLM responses using Lang Chain.
Implement a rag workflow for a product data use case using LangChain; load a product document, index it in a vector store with embeddings, and retrieve context to answer questions.
Implement RAG in this first part by setting up a rag directory, loading product data, configuring embeddings and a vector store, and wiring the retriever with a chat prompt.
Wrap up rag implementation by importing retrieval and documents chains from lang chain, wiring the qa chain, and assembling the rag chain to fetch documents and answer with the llm.
Test a rag app by loading a fake product data text, building a vector database, and querying the document to see context-driven responses from the llm.
Build a history aware rag application by creating a history aware retriever, integrating it with a rag chain, and using Streamlit chat history to manage context.
Learn to work with pdf documents in Langchain using the py pdf loader and py pdf library, replacing the text loader to run a rag on a climate change pdf.
LangChain has quickly become one of the most important frameworks for building real-world applications using large language models (LLMs). This course is designed to help you get started with LangChain and progressively master its powerful features, all through clear and simple examples.
Whether you’re a Python developer, an AI enthusiast, or someone curious about LLMs, this course will give you the tools and confidence to build intelligent applications using both OpenAI and open-source models.
What You’ll Learn
• What LangChain is and how it simplifies integrating LLMs into applications
• Use OpenAI LLMs in Python to generate and process natural language
• Use open-source LLMs like Mistral and Gemma in your own apps
• Run open-source models locally on your machine using Ollama
• Build dynamic prompts using PromptTemplates
• Understand and apply the LangChain Expression Language (LCEL)
• Create simple and regular sequential chains to control workflow logic
• Use multiple LLMs within a single chain for flexible responses
• Maintain and use chat history to create context-aware apps
• Learn about embeddings and apply them to measure text similarity
• Understand vector stores and use them to store and search embeddings
• Learn the Retrieval-Augmented Generation (RAG) workflow
• Implement RAG with your own data using LangChain in simple steps
• Analyze images using multi-modal models
• Understand what Agents are and implement agents
• Use Model Context Protocol (MCP) in your agents to access external tools
• Trace and implement observability your LLM applications using LangSmith
• Build real-world LLM-powered apps using Streamlit and LangChain
Who This Course Is For
• Python developers exploring AI and LLM integration
• Anyone looking to build chatbots, assistants, or smart tools using LLMs
• Professionals working on NLP, search, RAG, or agentic workflows
• Students, hobbyists, or beginners interested in AI application development
Prerequisites
• Basic understanding of Python
• No prior experience with LLMs or LangChain needed — everything is taught step by step
By the End of This Course, You Will Be Able To:
• Confidently use LangChain to work with OpenAI and open-source models
• Structure and build LLM workflows using chains and tools
• Implement powerful features like RAG, chat history, and image understanding
• Deploy fully functional apps using Streamlit and LangChain
• Build your own intelligent apps using both cloud and local LLMs
If you’ve been wanting to learn how to work with LLMs in your own projects — using simple steps and real examples — this is the perfect course to get started.
Enroll now and bring your LLM ideas to life using LangChain.