yvann-ba / Robby-chatbot

AI chatbot 🤖 for chat with CSV, PDF, TXT files 📄 and YTB videos 🎥 | using Langchain🦜 | OpenAI | Streamlit ⚡
MIT License
766 stars 287 forks source link

openai_api_key is missing when calling embeddings #54

Closed gleb-roma closed 9 months ago

gleb-roma commented 1 year ago

https://github.com/yvann-hub/Robby-chatbot/blob/15392010c0f39b247c271533d561d7cc6b3acb2d/tuto_chatbot_csv.py#L28C34-L28C34

You need to pass OPENAI key to the embeddings, too, eg:

embeddings = OpenAIEmbeddings(openai_api_key=user_api_key)

CakKhoiron commented 10 months ago

@yvann-hub please review and merge my changes. Thanks