Sign inSign up

sougur/sql-ai

By sougur

•Updated 2 days ago

Chat with MySQL in plain English: Django + Gemini text-to-SQL with schema RAG and safe queries

Image
0

120

sougur/sql-ai repository overview

⁠SQL-AI

Chat with a MySQL database in plain English. A Django app retrieves the relevant part of your schema (RAG over Redis Stack), asks Google Gemini to write a query, validates it with a real SQL parser, and runs it read-only with a timeout and row cap.

Source code: https://github.com/SOUGUR/LLM-SQL-Database⁠

⁠Tags

  • prod: production image (gunicorn)
  • local: development image

The Django dev server build is at sougur/sql-ai-web⁠.

⁠Run

docker pull sougur/sql-ai:prod
docker run -p 8000:8000 --env-file .env sougur/sql-ai:prod

It needs a MySQL database, Redis Stack and a Gemini API key. Configuration and the full docker-compose setup are in the GitHub repository.

Tag summary

Content type

Image

Digest

sha256:f0d751012…

Size

120.1 MB

Last updated

2 days ago

docker pull sougur/sql-ai:prod