Go the the extension's settings, enter your API key, and select a model.
Use the NLQ-to-SQL: Add Database command to add a database to the extension
Use the NLQ-to-SQL: Generate SQL w/ AI command to generate SQL from a question
This extension contributes a new view container called NLQ-to-SQL to the Activity Bar with the following views:
Database Explorer: Shows the databases you've added to the extension. You can add a database by clicking the + button in the view's title bar. In this view you can manage and enable table contexts to use for NLQ-to-SQL queries.
Active Table Context: Shows the tables included in the active table context. Any NLQ-to-SQL queries will use these tables only to generate SQL, instead of sending the entire database schema to OpenAI's API.
Generated SQL: Shows a history of all NLQ-to-SQL queries you've generated. From here you can copy the SQL to your clipboard or insert it into the editor.