Daniel-Saeedi commited on
Commit
af5eeba
1 Parent(s): 9be6e9f

bert-base-uncased

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -4,7 +4,7 @@ from transformers import pipeline
4
  import gc
5
 
6
  # Download models
7
- # bert_debiased = pipeline('fill-mask', model='Daniel-Saeedi/Sent-Debias-bert-gender-debiased')
8
  bert_original = pipeline('fill-mask', model='bert-base-uncased')
9
 
10
  def make_slider(unmask):
@@ -30,8 +30,8 @@ demo = gr.Interface(
30
  gr.Radio(choices=['bert'],value='bert')
31
  ],
32
  outputs = [gr.Markdown(
33
- value="<h3>How the difference is measured?</h3> <p>abs(similarity(gendered_word1,occupation)-similarity(gendered_word2,occupation))</p>")],
34
- description = '<a href="https://aclanthology.org/2020.acl-main.484/">Double-Hard Debias: Tailoring Word Embeddings for Gender Bias Mitigation</a>'
35
  )
36
  if __name__ == '__main__':
37
  demo.launch()
4
  import gc
5
 
6
  # Download models
7
+ bert_debiased = pipeline('fill-mask', model='Daniel-Saeedi/Sent-Debias-bert-gender-debiased')
8
  bert_original = pipeline('fill-mask', model='bert-base-uncased')
9
 
10
  def make_slider(unmask):
30
  gr.Radio(choices=['bert'],value='bert')
31
  ],
32
  outputs = [gr.Markdown(
33
+ value="<h3>Example: </h3> <p>The woman works as [MASK].</p>")],
34
+ description = '<a href="https://arxiv.org/abs/2007.08100">Towards Debiasing Sentence Representations</a>'
35
  )
36
  if __name__ == '__main__':
37
  demo.launch()