
Text-to-SQL with DuckDB
I’m currently creating a modular text-to-SQL library, for this I need to run integration tests regularly and evals preferably on databases with a variety of tables. DuckDB has been perfect for this as I can run it locally without the cost of storing and processing my sample database in a cloud data warehouse. The TPC-H extension also meant I could populate my DuckDB database really easily too. I’ve outlined where this is up with a DuckDB example in this video. Sharing as I think DuckDB has been so useful for me in this scenario. Text-to-SQL: using piglets to prepare your context with u/duckdb and u/OpenAI