/SQL.AI-Text-To-SQL-Code

SQL.AI is an interactive web application built with Streamlit and powered by Google's GenerativeAI. It allows users to interactively retrieve SQL data through natural language queries and predefined SQL commands. The application connects to a SQLite database, executes SQL queries, and provides visualizations of the retrieved data.

Primary LanguagePython

SQL.AI-Text-To-SQL-Code

SQL.AI is an interactive web application built with Streamlit and powered by Google's GenerativeAI. It allows users to interactively retrieve SQL data through natural language queries and predefined SQL commands. The application connects to a SQLite database, executes SQL queries, and provides visualizations of the retrieved data.

image image image image image

Features

  • Natural Language Processing: Utilizes Google's GenerativeAI to convert natural language questions into SQL queries.
  • Predefined SQL Commands: Offers a set of predefined SQL commands for quick data retrieval.
  • Interactive Data Visualization: Provides visualizations such as bar charts and pie charts based on the retrieved data.
  • Custom Search Options: Allows users to select specific columns for visualization and choose date ranges.
  • CSV Download: Enables users to download the retrieved data as a CSV file.

How to Use

  • Ask a Question: Input your SQL-related question in natural language and click "Ask SQL.AI."
  • Execute Predefined Commands: Select a predefined SQL command from the dropdown and click "Execute Command."
  • Visualize Data: Explore interactive visualizations based on the retrieved data.
  • Download Data: Download the retrieved data as a CSV file.

Getting Started

  • Clone the repository.
  • Install dependencies using pip install -r requirements.txt.
  • Run the application with streamlit run app.py.

License This project is licensed under the MIT License.