← all repositories

cloudquery/pg_gpt

A PostgreSQL extension that uses OpenAI's GPT API to generate SQL queries from natural language input.

pg_gpt
Not currently ranked — collecting fresh signals.
star history

This experimental PostgreSQL extension integrates OpenAI’s GPT models to enable querying databases using plain English. The extension sends the database schema (without actual data) to GPT, which then generates appropriate SQL based on user queries. It provides two functions: gpt(text) for full-schema queries and gpt_tables(pattern, text) for targeted queries against specific tables. The extension requires pgx for building and is marked experimental with warnings against production use due to schema transmission to OpenAI.

Frequently asked

What is cloudquery/pg_gpt?
A PostgreSQL extension that uses OpenAI's GPT API to generate SQL queries from natural language input.
Is pg_gpt open source?
Yes — cloudquery/pg_gpt is open source, released under the Apache-2.0 license.
What language is pg_gpt written in?
cloudquery/pg_gpt is primarily written in Rust.
How popular is pg_gpt?
cloudquery/pg_gpt has 460 stars on GitHub.
Where can I find pg_gpt?
cloudquery/pg_gpt is on GitHub at https://github.com/cloudquery/pg_gpt.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.