File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
modelcache/manager/scalar_data Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -168,13 +168,19 @@ def mark_deleted(self, keys):
168168 def model_deleted (self , model_name ):
169169 table_name = "modelcache_llm_answer"
170170 delete_sql = "Delete from {} WHERE model=?" .format (table_name )
171+
172+ table_log_name = "modelcache_query_log"
173+ delete_log_sql = "Delete from {} WHERE model=?" .format (table_log_name )
171174 conn = sqlite3 .connect (self ._url )
172175 try :
173176 cursor = conn .cursor ()
174177 cursor .execute (delete_sql , (model_name ,))
175178 conn .commit ()
176179 # get delete rows
177180 deleted_rows_count = cursor .rowcount
181+
182+ cursor .execute (delete_log_sql , (model_name ,))
183+ conn .commit ()
178184 cursor .close ()
179185 except sqlite3 .Error as e :
180186 print (f"SQLite error: { e } " )
You can’t perform that action at this time.
0 commit comments