defog-ai / sqlcoder

SoTA LLM for converting natural language questions to SQL queries
Apache License 2.0
3.27k stars 205 forks source link

When I use the same model and the same table structure information, the same user question , runs it on the local machine and on the demo website https://defog.ai/sqlcoder-demo . The results are different. Why? #46

Closed bigmancomeon closed 6 months ago

bigmancomeon commented 10 months ago

When I use the same model and the same table structure information, the same user question , runs it on the local machine and on the demo website https://defog.ai/sqlcoder-demo . The results are different. Why?

NPap0 commented 9 months ago

Do you also run greedy encoding on your local machine? Same quantization as the web demo? (If it is even quantized?)

bigmancomeon commented 9 months ago

Do you also run greedy encoding on your local machine? Same quantization as the web demo? (If it is even quantized?)

I don't quite understand what greedy encoding and quantization mean. The configuration I run locally is the same as the configuration in the inference.py file.

NPap0 commented 9 months ago

Do you also run greedy encoding on your local machine? Same quantization as the web demo? (If it is even quantized?)

I don't quite understand what greedy encoding and quantization mean. The configuration I run locally is the same as the configuration in the inference.py file.

The decoding strategy in the inference.py file in this repo uses beam search = 5

The demo you use on the browser does not use this setting. (Uses greedy decoding instead)

IF that is the only difference then you will need to lower the beam searches to 1. @rishsriv Let me know if I made any mistakes. Also, is the web demo model in fp16?

github-actions[bot] commented 7 months ago

Stale issue message

github-actions[bot] commented 6 months ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 6 months ago

This issue was closed because it has been inactive for 14 days since being marked as stale.