LLM Course – Build a Semantic Book Recommender (Python, OpenAI, LangChain, Gradio)
Discover how to build an intelligent book recommendation system using the power of large language models and Python. Learn to transform book descriptions into mathematical representations that enable precise content-based matching. By the end of this course, you'll have built a recommendation engine that helps readers discover their next favorite book.
💻 Code from this tutorial: https://github.com/t-redactyl/llm-semantic-book-recommender/tree/main
🏗 ️ JetBrains provided a grant to make this course possible.
⭐ ️ Resources ⭐ ️
Free 3-Month PyCharm Professional Subscription
Code: PyCharm4FreeCodeCamp
Download PyChhttps://jb.gg/pycharm-fccm-fcc
Redeem PyCharm 3-month free license: jetbrains.com/store/redeem
Download PyChhttps://jb.gg/pycharm-fccm-fcc
Kaggle datashttps://kaggle.com/datasetsasets
7K books dataset by Dylan Castihttps://kaggle.com/datasets/dylanjcastillo/7k-books-with-metadataas...
Hugging Face free NLP couhttps://huggingface.co/learn/nlp-course/en/ur...
Explanation of transformer encoder-decoder models (from Hugging Face NLP courhttps://huggingface.co/learn/nlp-course/en/chapter1/7ur...
Explanation of transformer decoder-only models (from Hugging Face NLP courhttps://huggingface.co/learn/nlp-course/en/chapter1/6ur...
Explanation of transformer encoder-only models (from Hugging Face NLP courhttps://huggingface.co/learn/nlp-course/en/chapter1/5ur...
Hugging Face Hub models phttps://huggingface.co/modelsodels
OpenAI modhttps://platform.openai.com/docs/modelsodels
Explanation of vector index (from Weaviahttps://weaviate.io/developers/weaviate/concepts/vector-indexia...
LangChain Python dhttps://python.langchain.com/docs/introductionnt...
LangChain chat model integratihttps://python.langchain.com/docs/integrations/chatnt...
OpenAI billing phttps://platform.openai.com/settings/organization/billing/overviews/...
OpenAI API keys phttps://platform.openai.com/settings/organization/api-keyss/...
Explanation of zero-shot classification (from Hugging Fahttps://huggingface.co/tasks/zero-shot-classificationho...
Information about fine-tuned emotion classification mohttps://dataloop.ai/library/model/j-hartmann_emotion-english-distilroberta-base-h...
Getting started with Grahttps://gradio.app/guides/quickstartstart
Gradio playgrohttps://gradio.app/playgroundround
Gradio thehttps://gradio.app/guides/theming-guideguide
Further work by Jodie about LLMs
Talk from GOTO Amsterdam giving an overview of LLMs: • Beyond the Hype: A Realistic Look at ...
Talk from NDC Oslo about whether LLMs are showing signs of humanity: • Mirror, mirror: LLMs and the illusion...
Talk from PyCon US about hallucinations in LLMs: • Talks - Jodie Burchell: Lies, damned ...
Tutorial on doing sentiment analysis with Lhttps://blog.jetbrains.com/pycharm/2024/12/how-to-do-sentiment-analysis-with-large-language-models/20...
Article on LLM’s understanding of languhttps://t-redactyl.io/blog/2024/06/can-llms-use-language-at-a-human-like-level.htmlca...
Article on sentience in Lhttps://t-redactyl.io/blog/2024/07/could-llms-be-sentient.htmlco...
Article on intelligence in Lhttps://t-redactyl.io/blog/2024/07/are-llms-on-the-path-to-agi.htmlar...
12:25
⭐ ️ Chapters ⭐ ️
0:00:00 Intro
0:03:05 Introduction to getting and preparing text data
0:05:51 Starting a new PyCharm project
0:16:59 Patterns of missing data
0:25:21 Checking the number of categories
0:28:27 Remove short descriptions
0:34:36 Final cleaning steps
0:38:11 Introduction to LLMs and vector search
0:54:43 LangChain
0:58:46 Splitting the books using CharacterTextSplitter
1:02:57 Building the vector database
1:05:50 Getting book recommendations using vector search
1:11:07 Introduction to zero-shot text classification using LLMs
1:15:34 Finding LLMs for zero-shot classification on Hugging Face
1:22:21 Classifying book descriptions
1:26:24 Checking classifier accuracy
1:35:19 Introduction to using LLMs for sentiment analysis
1:39:25 Finding fine-tuned LLMs for sentiment analysis
1:42:07 Extracting emotions from book descriptions
1:54:25 Introduction to Gradio
1:56:51 Building a Gradio dashboard to recommend books
2:12:49 Outro