Building an end-to-end Language Model (LLM) project integrating Google Palm and Langchain for interaction with a MySQL database, specifically focused on CO2 emissions data, is an exciting endeavor. This project aims to enhance user experience by allowing natural language queries, which are then translated into SQL queries for execution on the underlying MySQL database.
-
User Interaction: Users can interact with the system using natural language queries about CO2 emissions. For example:
- "Which country emitted the most CO2 in 2002?"
- "How many countries emitted between 4.25 and 20 CO2 units in 2010?"
-
Language Understanding: Utilize the language model (Google Palm) to parse and understand the user's input. Extract key information such as the target year, emission range, and specific requirements.
1.Clone this repository to your local machine using:
git clone https://github.com/Vampaxx/Co2_emission.git
2.Navigate to the project directory:
cd 'project directory'
- Install the required dependencies using pip:
pip install -r requirements.txt
4.Acquire an api key through makersuite.google.com and put it in .env file
GOOGLE_API_KEY="your_api_key_here"
co2_emission_working.mp4
- Run the Streamlit app by executing:
streamlit run main.py
2.The web app will open in your browser where you can ask questions. It in the localHost
- which country has maximum co2 emission in the year of 2002?
- Which country had the maximum CO2 emissions in the year 2002, and to which income group category do they belong?
- how many countries emit co2 in the range of 4.25 to 20 in the year of 2010?
- No of countries emit co2 in the range of 1.25 to 15 in the year of 2010 AND 1990?
- Identify the number of countries that exceeded 2 standard deviations in 2013?
- Identify the countries that exceeded 2 standard deviations in 2013?
- Identify the total countries that exceeded 2 standard deviations in 2013 and 2015?
- Which country recorded the highest CO2 emissions in 2020,and what its emission value?