SQLBot: Open-Source ChatBI for Zero-Code Natural Language Data Analysis

SQLBot is an open-source ChatBI tool that uses LLMs and RAG to convert natural language questions into SQL queries, generate visualizations, and provide AI-driven insights, enabling non-technical users to perform data analysis without writing code.

Smart Sea Tide
Smart Sea Tide
Smart Sea Tide
SQLBot: Open-Source ChatBI for Zero-Code Natural Language Data Analysis

Overview

SQLBot is an open-source ChatBI (Conversational Business Intelligence) tool developed by the DataEase team at Feizhiyun. It enables users to perform data analysis through natural language conversations without writing SQL or relying on data engineers. The system combines large language models (LLMs) with Retrieval-Augmented Generation (RAG) to build a complete Text-to-SQL pipeline: users ask business questions, the system leverages database schemas and business terminology to generate accurate SQL, executes queries, and automatically returns charts, data details, and AI-generated analytical conclusions.

Architecture

SQLBot adopts an LLM + RAG architecture. When a user submits a natural language query, the system retrieves relevant table structures and business term definitions, feeds them to the LLM, and produces a precise SQL statement. The generated SQL is executed against the connected database, and results are rendered as visualizations (bar, line, pie charts) alongside raw data and an AI-powered analysis that summarizes trends, flags anomalies, and offers business interpretations.

Deployment

Deployment requires a Linux server with Docker. A single script launches the entire stack, and the tool also supports installation via the 1Panel app store or offline packages for air-gapped environments.

docker run -d \
  --name sqlbot \
  --restart unless-stopped \
  -p 8000:8000 \
  -p 8001:8001 \
  -v ./data/sqlbot/excel:/opt/sqlbot/data/excel \
  -v ./data/sqlbot/file:/opt/sqlbot/data/file \
  -v ./data/sqlbot/images:/opt/sqlbot/images \
  -v ./data/sqlbot/logs:/opt/sqlbot/app/logs \
  -v ./data/postgresql:/var/lib/postgresql/data \
  --privileged=true \
  dataease/sqlbot

After startup, access the web UI at http://<server-ip>:8000 with default credentials admin / SQLBot@123456. Two configuration steps enable the service: (1) connect an LLM provider compatible with the OpenAI API format (e.g., DeepSeek, Qianfan, Alibaba Cloud Bailian, and over ten others), and (2) bind data sources such as MySQL, ClickHouse, or Excel/CSV files. No secondary development is required.

Conversational Analysis Features

Natural Language to SQL & Visualization

Users type questions like "Query the total sales volume by region." SQLBot automatically selects the most suitable chart type (bar, line, pie) and allows instant switching between them.

Export & Transparency

Generated charts can be exported as PNG images or Excel detail sheets. The underlying SQL is fully visible and copyable, enabling technical reviewers to verify query logic.

AI Deep Analysis

The system includes an AI analysis module that automatically summarizes data trends, annotates outliers, provides business interpretations, and can perform metric forecasting without additional scripting.

Dashboard Integration

Frequently used query charts can be pinned to a personal dashboard with one click, creating a persistent monitoring board that eliminates repetitive questioning.

Enterprise-Grade Capabilities

Fine-Grained Data Permissions

SQLBot uses a workspace isolation model with role-based member management and table-level access controls. Administrators can hide irrelevant tables to prevent the LLM from querying them, mitigating data leakage risks and meeting compliance requirements.

Full-Scenario Embedding

The tool supports web popup embedding and MCP (Model Context Protocol) calls, allowing seamless integration with platforms such as DataEase, Dify, MaxKB, and n8n. It can be embedded into CRM systems, business back-ends, or intelligent customer service applications, giving those applications native conversational analytics capabilities.

Continuous Improvement

Accuracy improves over time through customizable business terminology libraries and SQL example calibration. The system learns from user conversation logs, iteratively refining model matching logic so that SQL generation accuracy steadily increases, adapting to industry-specific business definitions.

Reference

GitHub repository:

https://github.com/dataease/SQLBot
Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

DockerLLMRAGOpen SourceText-to-SQLData VisualizationChatBISQLBot
Smart Sea Tide
Written by

Smart Sea Tide

Sharing cutting‑edge big data and AI technologies, with occasional lifestyle insights.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.