You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched the EvaDB issues and found no similar bug report.
Bug
Steps that I did to enable it
Add ChatGPT to evadb/constants.py
Modify the cacheable parameter for the ChatGPT function.
Code to reproduce it (can be copied to a test file and run)
execute_query_fetch_all(self.evadb, f"CREATE TABLE fruitTable (data TEXT(100))")
data_list = [
"The color of apple is red",
"The color of banana is yellow",
]
for data in data_list:
execute_query_fetch_all(self.evadb, f"INSERT INTO fruitTable (data) VALUES ('{data}')")
import os
os.environ["OPENAI_KEY"] = "sk-..."
select_query = """SELECT ChatGPT('What is the fruit described in this sentence', data)
FROM fruitTable"""
batches, exec_times = self._reuse_experiment([select_query, select_query])
self._verify_reuse_correctness(select_query, batches[1])
print(exec_times[0], exec_times[1])
print(batches[0].frames)
self.assertTrue(exec_times[0] > exec_times[1])
I don't see the outputs being generated from the cache. Do I miss something here?
Environment
No response
Are you willing to submit a PR?
Yes I'd like to help by submitting a PR!
The text was updated successfully, but these errors were encountered:
Search before asking
Bug
Steps that I did to enable it
ChatGPT
toevadb/constants.py
cacheable
parameter for the ChatGPT function.Code to reproduce it (can be copied to a test file and run)
I don't see the outputs being generated from the cache. Do I miss something here?
Environment
No response
Are you willing to submit a PR?
The text was updated successfully, but these errors were encountered: