skf15963 commited on
Commit
f329bf4
1 Parent(s): dce7154

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -9,8 +9,6 @@ def summary(text):
9
  # Generate Summary
10
  summary_ids = model.generate(inputs["input_ids"])
11
  return tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]
12
- examples = [
13
- ["电力数据是反映经济运行的“晴雨表”和“风向标”。今年以来,随着消费信心逐步回暖、企业复工开足马力生产,多地用电量整体呈现出积极信号。一起透过各地的用电量,来看看中国经济的发展态势。"]
14
- ]
15
- iface = gr.Interface(fn=summary, inputs="text", outputs="text")
16
  iface.launch()
 
9
  # Generate Summary
10
  summary_ids = model.generate(inputs["input_ids"])
11
  return tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]
12
+ examples = ["电力数据是反映经济运行的“晴雨表”和“风向标”。今年以来,随着消费信心逐步回暖、企业复工开足马力生产,多地用电量整体呈现出积极信号。一起透过各地的用电量,来看看中国经济的发展态势。"]
13
+ iface = gr.Interface(fn=summary, inputs="text", outputs="text",examples=examples)
 
 
14
  iface.launch()