TablesSQLDatabaseTool does not use similarity criterion on selecting the tables from few_shot_examples #474
rafaelpadilla
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
First of all, congratulations for such project and keeping it opensource 🙌
I see that the tool TablesSQLDatabaseTool uses examples provided by the user to retrieve the most similar tables.
The tool uses the few-shot examples to complete the final answer, which includes:
few_shot_examplesHowever, IMHO, this approach is strange, since it does not use any criterion on selecting the tables from the
few_shot_examples.In a case where the few_shot_examples contains a query:
"SELECT BRANDS FROM TABLE_WATCHES"
The table
TABLE_WATCHESwould be included (with the highest similarity score) for any input question. Even if the input question is totally unrelated to the TB_WATCHES. For instance: "How many liquid products are the in the warehouse?"I'm pretty sure you guys have baseline datasets to evaluate the precision of the output SQL queries. And I believe that including a similarity criterion in the few_shot_examples, the results will be improved.
Beta Was this translation helpful? Give feedback.
All reactions