Skip to content

Latest commit

 

History

History

Code-Documentation-QA-Bot

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Code documentation Q&A bot example with LangChain

imgonline-com-ua-twotoone-RaRlTe66ft3RUvK

This Q&A bot will allow you to query your own documentation easily using questions. We'll also demonstrate the use of LangChain and LanceDB using the OpenAI API. In this example we'll use Numpy 1.26 documentation, but, this could be replaced for your own docs as well. Colab walkthrough - Open In Colab

Python

Run the script

OPENAI_API_KEY=... python main.py --query "what is a vectordb?"

default query = What are the major differences in pandas 2.0?

Argument Default Value Description
query "What are the major ..." query to search
openai-key OpenAI API Key, not required if OPENAI_API_KEY env var is set

Javascript

Run the script

OPENAI_API_KEY=... node index.js