rodrigomasini commited on
Commit
332c722
·
verified ·
1 Parent(s): 4a9a367

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -14
app.py CHANGED
@@ -22,13 +22,12 @@ checkpoint = "intfloat/multilingual-e5-large"
22
  tokenizer = AutoTokenizer.from_pretrained(checkpoint)
23
  model = AutoModel.from_pretrained(checkpoint)
24
 
25
- demo = gr.Blocks(theme="freddyaboulton/dracula_revamped")
26
  with demo:
27
 
28
- gr.Markdown("# Sentence Similarity")
29
  gr.Markdown("### How to use:")
30
  gr.Markdown("- Enter Passage 1 and Passage 2, then press Submit")
31
- gr.Markdown("- Select an example, then press Submit")
32
  gr.Markdown("Model: https://huggingface.co/intfloat/multilingual-e5-large (Multilingual: 94 languages)")
33
 
34
  with gr.Row():
@@ -39,17 +38,6 @@ with demo:
39
 
40
  submit = gr.Button("Submit")
41
 
42
- gr.Examples(
43
- [
44
- ["A big bus is running on the road in the city.", "There is a big bus running on the road."],
45
- ["A big bus is running on the road in the city.", "Two children in costumes are standing on the bed."],
46
- ["街中の道路を大きなバスが走っています。", "道路を大きなバスが走っています。"],
47
- ["街中の道路を大きなバスが走っています。", "ベッドの上で衣装を着た二人の子供が立っています。"],
48
- ["A big bus is running on the road in the city.", "道路を大きなバスが走っています。"]
49
- ],
50
- inputs=[p_txt1, p_txt2]
51
- )
52
-
53
  submit.click(
54
  get_similarity,
55
  [p_txt1, p_txt2],
 
22
  tokenizer = AutoTokenizer.from_pretrained(checkpoint)
23
  model = AutoModel.from_pretrained(checkpoint)
24
 
25
+ demo = gr.Blocks(theme=theme='sudeepshouche/minimalist')
26
  with demo:
27
 
28
+ gr.Markdown("# MAGIC Sentence Similarity")
29
  gr.Markdown("### How to use:")
30
  gr.Markdown("- Enter Passage 1 and Passage 2, then press Submit")
 
31
  gr.Markdown("Model: https://huggingface.co/intfloat/multilingual-e5-large (Multilingual: 94 languages)")
32
 
33
  with gr.Row():
 
38
 
39
  submit = gr.Button("Submit")
40
 
 
 
 
 
 
 
 
 
 
 
 
41
  submit.click(
42
  get_similarity,
43
  [p_txt1, p_txt2],