jslin09 commited on
Commit
e713002
1 Parent(s): 837275c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -2
app.py CHANGED
@@ -1,11 +1,19 @@
1
  import gradio as gr
 
 
 
 
2
 
3
  API_URL = "https://api-inference.huggingface.co/models/jslin09/bloom-560m-finetuned-fraud"
4
  headers = {"Authorization": "Bearer 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"} # Read only
5
 
 
 
 
6
  iface = gr.Interface.load("huggingface/jslin09/bloom-560m-finetuned-fraud",
7
- examples=[["闕很大明知金融帳戶之存摺、提款卡及密碼係供自己使用之重要理財工具,"]],
8
- api_key="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"
 
9
  )
10
 
11
  iface.launch()
 
1
  import gradio as gr
2
+ from transformers import pipeline
3
+
4
+ #pipe = pipeline("text-generation")
5
+ #gr.Interface.from_pipeline(pipe).launch()
6
 
7
  API_URL = "https://api-inference.huggingface.co/models/jslin09/bloom-560m-finetuned-fraud"
8
  headers = {"Authorization": "Bearer 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"} # Read only
9
 
10
+ description = "Legal Document Drafting with BLOOM"
11
+ api_key="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"
12
+
13
  iface = gr.Interface.load("huggingface/jslin09/bloom-560m-finetuned-fraud",
14
+ description=description,
15
+ examples=[["闕很大明知金融帳戶之存摺、提款卡及密碼係供自己使用之重要理財工具,"],["森上梅前明知其無資力支付酒店消費,亦無付款意願,竟意圖為自己不法之所有,"]],
16
+ api_key=api_key,
17
  )
18
 
19
  iface.launch()