Building a RAG application from scratch using Python, LangChain, and the OpenAI API