Chat with your PostgreSQL data using an AI assistant. Team members ask plain questions and get summaries, counts, or records without writing SQL. Useful for operations, support, and sales teams that need quick answers from a Supabase or PostgreSQL database.
When a chat message arrives, the n8n chat trigger passes the text to an AI Agent powered by the OpenAI chat model. The agent uses three database tools. One lists all tables so the model knows what data exists. Another pulls the columns and types for a chosen table. The third runs SQL and returns rows. The agent builds queries from the schema, executes them, and replies with totals, lists, or short explanations.
Set your OpenAI and database credentials, then adjust the system prompt to match your rules and tone. Expect faster answers to common data questions and fewer analyst tickets. Typical uses include daily KPIs, quick record lookups, ad hoc checks on JSON or text fields, and simple trend reviews for non technical staff.