teaevo commited on
Commit
2ce1434
·
1 Parent(s): 8ca77a8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -111,7 +111,7 @@ def sqlquery(input, history=[]):
111
  history = sql_model.generate(bot_input_ids, max_length=1000, pad_token_id=sql_tokenizer.eos_token_id).tolist()
112
 
113
  # convert the tokens to text, and then split the responses into the right format
114
- response = sql_tokenizer.decode(history[0]).split("<|endoftext|>")
115
  response = [(response[i], response[i + 1]) for i in range(0, len(response) - 1, 2)] # convert to tuples of list
116
 
117
  '''
 
111
  history = sql_model.generate(bot_input_ids, max_length=1000, pad_token_id=sql_tokenizer.eos_token_id).tolist()
112
 
113
  # convert the tokens to text, and then split the responses into the right format
114
+ response = sql_tokenizer.batch_decode(history[0]).split("<|endoftext|>")
115
  response = [(response[i], response[i + 1]) for i in range(0, len(response) - 1, 2)] # convert to tuples of list
116
 
117
  '''