cahya commited on
Commit
dd813fc
1 Parent(s): 030f8db

fixed the tokenizer

Browse files
Files changed (1) hide show
  1. app/api.py +1 -1
app/api.py CHANGED
@@ -127,7 +127,7 @@ async def text_generate(
127
  num_return_sequences=1,
128
  max_time=max_time
129
  )
130
- result = tokenizer.decode(sample_outputs[0], skip_special_tokens=True)
131
  time_end = time.time()
132
  time_diff = time_end - time_start
133
  print(f"result:\n{result}")
 
127
  num_return_sequences=1,
128
  max_time=max_time
129
  )
130
+ result = text_generator[model_name]["tokenizer"].decode(sample_outputs[0], skip_special_tokens=True)
131
  time_end = time.time()
132
  time_diff = time_end - time_start
133
  print(f"result:\n{result}")