Build a system that can take input question related to a database of an imaginary college called AtliQ Commerce College. Here are some sample questions you can ask to this Q&A system.
- How much peter pandey have to pay in the first semester?
- This should return "pending" fees
- How much did peter pandey paid in the first semester?
- This should return "paid" fees
- What is the purpose of a balance sheet?.
- This is not a question related to college's internal data. It is rather a general question that openai LLM can answer using its past training (similar to ChatGPT)
- Average gpa in third semester?
- This will return an average GPA of all the students in the third semester
Database: MySQL
Backend: Python + OpenAI Function Calling
Frontend: Streamlit
- Database: In db, directory you will see sql file. Just run that entire script in your MySQL workbench
- Python code: You need to install following modules,
pip install openai pip install streamlit pip install mysql-connector-python
- OpenAI setup: You need to obtain a secret key from your openai account and put it in secret_key.py file
From your command line run this command,
streamlit run main.py