CodeTed commited on
Commit
3c97636
1 Parent(s): 3fd21fe

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -3,7 +3,7 @@ from t5.t5_model import T5Model
3
  from transformers import AutoTokenizer, T5ForConditionalGeneration
4
  #tokenizer = AutoTokenizer.from_pretrained("CodeTed/traditional_CSC_t5")
5
  #model = T5ForConditionalGeneration.from_pretrained("CodeTed/traditional_CSC_t5")
6
- model = T5Model('t5', "CodeTed/traditional_CSC_t5", args={"eval_batch_size": 1}, cuda_device=-1, evaluate=True)
7
 
8
  def cged_correction(sentence = '為了降低少子化,政府可以堆動獎勵生育的政策。'):
9
  for _ in range(3):
 
3
  from transformers import AutoTokenizer, T5ForConditionalGeneration
4
  #tokenizer = AutoTokenizer.from_pretrained("CodeTed/traditional_CSC_t5")
5
  #model = T5ForConditionalGeneration.from_pretrained("CodeTed/traditional_CSC_t5")
6
+ model = T5Model('t5', "CodeTed/Chinese_Spelling_Correction_T5", args={"eval_batch_size": 1}, cuda_device=-1, evaluate=True)
7
 
8
  def cged_correction(sentence = '為了降低少子化,政府可以堆動獎勵生育的政策。'):
9
  for _ in range(3):