Description
Combine the analytical power of a SQL Agent with AI-generated visualizations. This workflow allows your team to query databases in natural language and receive not just textual answers, but dynamic charts powered by OpenAI and Quickchart.io.
Ideal for analysts, product teams, and internal tools that need fast, understandable data insights.
๐ง How It Works:
โ ๐งพ A user asks a question about data via a natural language input โ ๐ง The Information Extractor identifies the question's intent and checks if it includes a visual need โ ๐พ The SQL Agent connects to the database and executes a relevant SQL query โ โจ The Text Classifier analyzes the query and determines whether a chart would improve understanding โ ๐ง If a chart is needed, OpenAI is called to define the appropriate chart type and config โ ๐งฐ The chart definition is turned into a Quickchart.io URL using a simple Set node โ ๐ The final response includes both the SQL Agent's insight and the generated chart โ ๐ฏ If no visualization is needed, the plain SQL Agent answer is returned
๐ It Automates:
โ Translating natural language into accurate SQL queries โ Intelligent detection of when to visualize data โ Dynamic chart creation based on query context โ Seamless delivery of insights as both text and image โ Integration of SQL Agent and visual feedback loop
๐ก Why Choose This Workflow:
โ Turns raw query results into easily digestible visuals โ Enables non-technical users to extract insights with no SQL knowledge โ Great for dashboards, reports, or team data chats โ Fully automatedโno chart configuration or manual generation required โ Extensible: supports PostgreSQL, MySQL, and SQLite
๐ค Who Is This For:
โ Data analysts & business intelligence teams โ Product and growth teams running ad-hoc queries โ Internal tool builders & low-code developers โ Teams using Supabase, PlanetScale, or local DBs โ Anyone wanting to bring clarity to data fast
๐ Integrations:
โ SQL Agent (native n8n agent for querying) โ OpenAI (for structured output and chart definitions) โ Quickchart.io (for on-the-fly chart rendering) โ Supabase, PostgreSQL, MySQL, or SQLite (for database access)
๐ Data Talks โ Now It Paints the Picture Too Import this n8n workflow, connect your SQL database, and experience the power of AI-driven data analysis and visualizationโhands-free.
Link : [https://lovable.dev/projects/f8a3cbd5-fa31-4bda-820c-1bf954b2210a]