Live data from Hacker News

Show HN: Dataherald AI – Natural Language to SQL Engine

github.com

101–108 of 108 posts

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#101
post #72

When I look at all the LLM SQL tools, I think: what a cheap and accessible way to get the wrong answers. SQL is easy. Knowledge management is hard. Does the LLM know that there was a bug in June that changed the data? Does it know that this one column is improperly named and confusing? Does it know that you recently released a mobile app the data from which is in a different table? No, of course not, those things are…

SQL is easy, the problem is that some enterprise database schemas have gotten incredibly complex over time. I think LLMs might help the maintainers navigate such a complex landscape. Especially if comments are added to each table with clarifications. The only serious limit here is the LLM's context length...

Hit the nail on the head! Not only is the context length a limitation, but the speed of response gets impacted as well.

With a human in the loop, even providing a "mostly" correct SQL that takes a swing at the correct joins between relevant tables reduces the data practitioner's work significantly. Of course, as more questions are asked, the tool gets better at writing the SQL better. Almost like a human in a Database Management and SQL class...

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#102
post #81

Hey ! This is awesome. I have been playing around with the dirty DIN-SQL repo for a couple of weeks, so this is a delight. A couple of questions: * How easy is it to swap out the LLM ? (to Azure GPT4) * Do you have 1 end2end custom user scenario ? It would really help to have 1 golden workflow (the fastest way to get things up and running) and 1 custom workflow (how to maximally configure the package to make it work…

Hello, and thank you for your positive feedback on our work with Dataherald.

I'm currently in the process of tidying up the DIN-SQL repository, and I apologize for any inconvenience this may cause :).

Regarding the usage of other Large Language Models (LLMs), we offer support for OpenAI, Anthropic, Google, and Cohere models. However, it's important to note that our testing and optimization efforts have primarily been concentrated on OpenAI models. If you intend to utilize other models, it's advisable to proceed with caution and be mindful of potential variations in performance and behavior.

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#103

Earlier quoted context omitted.

Yeah, I hope this is paired with something that actually stops those statements from running otherwise this is a pretty naive way to do this.

SQL injection meets prompt-injection…

NEVER CREATE CARTESIAN PRODUCTS

For example:

SELECT clicks.session_id, clicks.page_url, sessions.user_id FROM clicks, sessions;

(This context is guaranteed to generate lots of cartesian products.)

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#104
post #90
post #52

Very nice! I added a similar feature to https://sitespeak.ai recently that allows my users to connect their virtual assistant to a Sqlite database to retrieve data to answer visitor questions. Initially this was just a way around the difficulty of "chatting to a CSV" so the solution was to convert any CSV to a Sqlite database and using that, but it's proved very useful. Will definitely look at using Dataherald for ad…

Very cool! is this mostly for unstructured data search? Any interest in adding tabular / structured data NL search?

Yes, most customers are using it for unstructured data, but a few do use it with structured data. For those I currently use Langchain's API and SQL chains.

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#105
post #55

From the prompt context: DO NOT make any DML statements (INSERT, UPDATE, DELETE, DROP etc.) to the database. I've found that spelling out exactly what I don't want an LLM to do dramatically increases the probability that it will do exactly that.

Yeah, I hope this is paired with something that actually stops those statements from running otherwise this is a pretty naive way to do this.

Yes, opening the connection to the DB read-only would also work. That's what we're planning on doing.

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#106
post #80

This looks very interesting and timely for me, thanks for sharing! I was looking at the project to spin it up with a BigQuery connection, but I couldn't find an example in the docs (expected it on this page: https://dataherald.readthedocs.io/en/latest/api.database.htm... ), nor can I find it in the repo. Any hints on this? Otherwise I'm fine going source code diving. :)

Hi, you can find updated documentation on connecting to BigQuery here: https://dataherald.readthedocs.io/en/latest/api.database.htm.... We have also updated the ReadMe.

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#107
post #97

Congrats for your launch ! I also built NL2SQL solution (relying on OpenAI). My first version was a direct NL2SQL version, named Olympe - https://github.com/BenderV/olympe I used it quite a while but trying to plug it to real database (100+ tables, unprepared) was unsuccesful. I switched to chat version, named Ada - https://github.com/BenderV/ada IMHO, it's the way to go. The AI explore the database, it's connection,…

Nice! how's the switch to Ada been? Any unexpected hurdles?

Great since GPT4. However, I need to add some optimization because it's take time for the AI to explore databases / tables schema / structures.

Re: Show HN: Dataherald AI – Natural Language to SQL Engine

#108
post #80

This looks very interesting and timely for me, thanks for sharing! I was looking at the project to spin it up with a BigQuery connection, but I couldn't find an example in the docs (expected it on this page: https://dataherald.readthedocs.io/en/latest/api.database.htm... ), nor can I find it in the repo. Any hints on this? Otherwise I'm fine going source code diving. :)

Hi, you can find updated documentation on connecting to BigQuery here: https://dataherald.readthedocs.io/en/latest/api.database.htm... . We have also updated the ReadMe.

Thanks for the update, yeah that makes sense!

I think it's useful to add as a note how to add credentials when running inside Docker since that mode is included right there in the readme (ie. adding a volume with the credentials).

As an idea, for the "Adding string descriptions" section, having stuff like dbt docs (or even just the manifest that generates) could supercharge the context.

Very interesting in general, definitely trying it out for our database!

Post reply on HN