Тёмный

OpenAI RAG Chatbot | Chat with PDF locally 

Joy Maitra
Подписаться 475
Просмотров 6 тыс.
50% 1

🌐 Ready to elevate your chatbot game? Join us on a coding adventure as we show you how to build a Responsive and Adaptive Chatbot using the power of Python, Streamlit, Langchain, an open-source vector store database, and the incredible OpenAI API!
🚀 In this hands-on tutorial, we'll guide you through the process of creating a chatbot that not only understands natural language but adapts its responses based on the context of the conversation. Python will be our language of choice, while Streamlit will provide a sleek and interactive web interface for our chatbot.
🔍 Discover the capabilities of Langchain, a dynamic natural language processing library designed to make your chatbot smarter and more context-aware. Learn how to implement an open-source vector store database, ensuring efficient storage and retrieval of conversation data for seamless interactions.
🌈 What sets this chatbot apart is its adaptability, thanks to OpenAI. We'll integrate OpenAI's state-of-the-art models to enable the chatbot to understand and respond to user queries with a level of nuance and intelligence that will leave users impressed.
Code from the video is available in the below github link :
github.com/JYTDemo/chat_w_pdf...

Наука

Опубликовано:

 

12 янв 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 32   
@deepak_kori
@deepak_kori 3 месяца назад
THIS IS amazing...
@joymaitra5414
@joymaitra5414 3 месяца назад
Thank you!!
@minimal2224
@minimal2224 5 месяцев назад
Sir, what type of computer do you recommend for running local GPT’s? I have PrivateGPT, but it’s painfully slow on replies.
@joymaitra5414
@joymaitra5414 5 месяцев назад
On local system with 16GB RAM and i5 processor I find the response slow bt ok, anything less than that, I hear you, it's pathetic !
@NehaKothari-iz3hy
@NehaKothari-iz3hy 2 месяца назад
Hey Joy, Can you plz help how can we use input as book cover image and find similar book search with the same code , also provide the code for the same , dataset??
@joymaitra5414
@joymaitra5414 2 месяца назад
Hi Neha, thanks for commenting, but this approach will definitely not work for your requirement, this implementation is for textual inputs, you would need a multi modal LLM to interpret the image input. I will try to cover that in one of my future videos.
@VP_SOTWMC
@VP_SOTWMC 4 месяца назад
I have two queries. It would be helpful if you can assist in that. 1. Template which you are using for prompt , in the first line you have provided f string. But however in the next lines you are not giving where you have {context}, {question}. So wouldn't that make it a string rather taking context and questions as variable? Or the model will understand that? 2. My second question is that I have tested the code. It is working for most part except Chat history. Even in the same session, it is not able to remember the previous questions. It is getting updated in the chat history though. But when u explicitly ask what is my previous question or ask like explain more on previous question, it is not taking the chat history rather giving halucinated questions or says it doesnt know previous question. Kindly clarify on the above two questions
@joymaitra5414
@joymaitra5414 4 месяца назад
Hi, Thanks for sharing the queries, for the 1st query, you are right, need to fix that. But for the 2nd question, this demo I have shown only the chatbot, while in the other view I have demonstrated how to utilize the memory in llm. Let me know, if you have further queries. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE--TtE7otMHCc.html
@Alkotas25
@Alkotas25 5 месяцев назад
thx the video! sorry my question but im a beginner in this code. What files I see github I tried to run on Codespace with no success. Is there any other file, enviroment info I should have to try and run your RAG app? Could you pls help me regarding this as a beginner?
@joymaitra5414
@joymaitra5414 5 месяцев назад
You need to add the openAI api key as environment variable.
@ganesh_kumar
@ganesh_kumar 3 месяца назад
Thanks for the video, does this work for multiple documents as well with good accuracy?
@joymaitra5414
@joymaitra5414 3 месяца назад
Yes it works with multiple documents, accuracy is quite good
@yashakirad2996
@yashakirad2996 2 месяца назад
Hi, I am getting error ModuleNotFoundError: No module named 'langchain.chat_models' please help
@joymaitra5414
@joymaitra5414 2 месяца назад
Try uploading langchain by pip install --upgrade langchain
@user-fj4ic9sq8e
@user-fj4ic9sq8e 4 месяца назад
Hello, thank you so much for this video. i have a question related of summarize questions in LLM documents. For example in vector database with thousands documents with date property, and i want ask the model how much document i received in the last week?
@joymaitra5414
@joymaitra5414 4 месяца назад
I guess we don't need LLM for such a query, we can query the vector DB, and for how to do that ? You can watch my video on Vector DB.
@user-fj4ic9sq8e
@user-fj4ic9sq8e 4 месяца назад
@@joymaitra5414 , thank you for the beedback, but the questions are illimited, the user can ask direct questions like "what is the latest document i have?" or he can ask "how many documents i didn't read ?", i don't know how can convert this question to vectorDB query.
@joymaitra5414
@joymaitra5414 3 месяца назад
may be you can add the file properties as metadata attributes in the vectorDB and then make use of that information to answer the query.
@sabareeswaranbagavathi1230
@sabareeswaranbagavathi1230 День назад
Please provide pre-requisite installation otherwise as a beginner no one can recreate.
@C__MehrabEvan
@C__MehrabEvan 2 месяца назад
does it work with image based pdf? and if doesn't how can i make one? please suggest
@joymaitra5414
@joymaitra5414 2 месяца назад
Thanks for reaching out!! It does not work for image based pdf, for that chatGPT vision is required. And have to pass the pages of the pdf as image in the prompt. I am making a video on that will share soon. Request you to stay connected!!
@allantauro3606
@allantauro3606 4 месяца назад
Hey good video. I am trying to recreate this, created the .env all of that is situated, however when I run ui.py using streamlit, getting error AttributeError: module 'openai' has no attribute 'error'. Can you help??
@joymaitra5414
@joymaitra5414 4 месяца назад
Thanks for reaching out. If you are not using azure OpenAI, there can be some errors due to libraries.
@azmathahmed268
@azmathahmed268 3 месяца назад
@allantauro3606 hey bro have you recreated it?
@wah866sky7
@wah866sky7 2 месяца назад
@@joymaitra5414 Thanks, Joy. But if I just have API key from normal OpenAI, how can I adjust the program to fix the module problem?
@NehaKothari-iz3hy
@NehaKothari-iz3hy 2 месяца назад
Can you plz provide the pdf of document that you used
@NehaKothari-iz3hy
@NehaKothari-iz3hy 2 месяца назад
Not able to get that point, from where i can get the pdf for book recommendation chat bot
@joymaitra5414
@joymaitra5414 2 месяца назад
You can use any pdf document, with text in it, I have used a blog post, saved as pdf.
@azmathahmed268
@azmathahmed268 3 месяца назад
Hello I am having few queries how can I reach you out please help me
@joymaitra5414
@joymaitra5414 3 месяца назад
You can email me
@somnath2775
@somnath2775 6 месяцев назад
Guru Bhalo Likhechish, I hope you know who I am. Don't disclose 😜. Ami Finally toke subscribe korlam. Keep going.
@joymaitra5414
@joymaitra5414 6 месяцев назад
Thank you !!
Далее
DAD LEFT HIS OLD SOCKS ON THE COUCH…😱😂
00:24
▼ЕГО БОЯЛИСЬ МОНГОЛЫ 🍣
32:51
Просмотров 485 тыс.
Stream LLMs with LangChain + Streamlit | Tutorial
18:26
Python RAG Tutorial (with Local LLMs): AI For Your PDFs
21:33
5 Things I Wish I Knew Before Learning Streamlit
21:34
Colorful Vulcan w rtx 4070ti Super
13:30
Просмотров 60 тыс.
Choose a phone for your mom
0:20
Просмотров 7 млн
Треш ПК за 420 000 рублей
0:59
Просмотров 256 тыс.