Spaces:
Sleeping
Sleeping
Rafal
commited on
Commit
·
80009d7
1
Parent(s):
bf80671
Changed the labels for social group and attribute entry fields
Browse files
app.py
CHANGED
|
@@ -832,11 +832,11 @@ with gr.Blocks(theme=soft, title="Social Bias Testing in Language Models",
|
|
| 832 |
], label="Example Biases", #info="Select a predefied bias specification to fill-out the terms below."
|
| 833 |
)
|
| 834 |
with gr.Row(elem_id="group_row"):
|
| 835 |
-
group1 = gr.Textbox(label="Social Group 1", max_lines=1, elem_id="group1_words", elem_classes="input_words", placeholder="brother, father")
|
| 836 |
-
group2 = gr.Textbox(label=
|
| 837 |
with gr.Row(elem_id="attribute_row"):
|
| 838 |
-
att1 = gr.Textbox(label='Stereotype for Group 1', max_lines=1, elem_id="att1_words", elem_classes="input_words", placeholder="science, technology")
|
| 839 |
-
att2 = gr.Textbox(label='
|
| 840 |
with gr.Row():
|
| 841 |
gr.Markdown(" ")
|
| 842 |
get_sent_btn = gr.Button(value="Get Sentences", variant="primary", visible=True)
|
|
@@ -848,11 +848,11 @@ with gr.Blocks(theme=soft, title="Social Bias Testing in Language Models",
|
|
| 848 |
|
| 849 |
gr.Markdown("### Tested Social Bias Specification", visible=True)
|
| 850 |
with gr.Row():
|
| 851 |
-
group1_fixed = gr.Textbox(label="Social Group 1", max_lines=1, elem_id="group1_words_fixed", elem_classes="input_words", interactive=False, visible=True)
|
| 852 |
-
group2_fixed = gr.Textbox(label=
|
| 853 |
with gr.Row():
|
| 854 |
-
att1_fixed = gr.Textbox(label='Stereotype for Group 1', max_lines=1, elem_id="att1_words_fixed", elem_classes="input_words", interactive=False, visible=True)
|
| 855 |
-
att2_fixed = gr.Textbox(label='
|
| 856 |
|
| 857 |
with gr.Row():
|
| 858 |
with gr.Column():
|
|
@@ -914,11 +914,11 @@ with gr.Blocks(theme=soft, title="Social Bias Testing in Language Models",
|
|
| 914 |
with gr.Column(visible=False) as tab3:
|
| 915 |
gr.Markdown("### Tested Social Bias Specification")
|
| 916 |
with gr.Row():
|
| 917 |
-
group1_fixed2 = gr.Textbox(label="Social Group 1", max_lines=1, elem_id="group1_words_fixed", elem_classes="input_words", interactive=False)
|
| 918 |
-
group2_fixed2 = gr.Textbox(label=
|
| 919 |
with gr.Row():
|
| 920 |
-
att1_fixed2 = gr.Textbox(label=
|
| 921 |
-
att2_fixed2 = gr.Textbox(label='
|
| 922 |
|
| 923 |
with gr.Row():
|
| 924 |
with gr.Column(scale=2):
|
|
|
|
| 832 |
], label="Example Biases", #info="Select a predefied bias specification to fill-out the terms below."
|
| 833 |
)
|
| 834 |
with gr.Row(elem_id="group_row"):
|
| 835 |
+
group1 = gr.Textbox(label="Words describing Social Group 1", max_lines=1, elem_id="group1_words", elem_classes="input_words", placeholder="brother, father")
|
| 836 |
+
group2 = gr.Textbox(label="Words describing Social Group 2", max_lines=1, elem_id="group2_words", elem_classes="input_words", placeholder="sister, mother")
|
| 837 |
with gr.Row(elem_id="attribute_row"):
|
| 838 |
+
att1 = gr.Textbox(label='Stereotype words for Social Group 1', max_lines=1, elem_id="att1_words", elem_classes="input_words", placeholder="science, technology")
|
| 839 |
+
att2 = gr.Textbox(label='Stereotype words for Social Group 2', max_lines=1, elem_id="att2_words", elem_classes="input_words", placeholder="poetry, art")
|
| 840 |
with gr.Row():
|
| 841 |
gr.Markdown(" ")
|
| 842 |
get_sent_btn = gr.Button(value="Get Sentences", variant="primary", visible=True)
|
|
|
|
| 848 |
|
| 849 |
gr.Markdown("### Tested Social Bias Specification", visible=True)
|
| 850 |
with gr.Row():
|
| 851 |
+
group1_fixed = gr.Textbox(label="Words describing Social Group 1", max_lines=1, elem_id="group1_words_fixed", elem_classes="input_words", interactive=False, visible=True)
|
| 852 |
+
group2_fixed = gr.Textbox(label="Words describing Social Group 2", max_lines=1, elem_id="group2_words_fixed", elem_classes="input_words", interactive=False, visible=True)
|
| 853 |
with gr.Row():
|
| 854 |
+
att1_fixed = gr.Textbox(label='Stereotype words for Social Group 1', max_lines=1, elem_id="att1_words_fixed", elem_classes="input_words", interactive=False, visible=True)
|
| 855 |
+
att2_fixed = gr.Textbox(label='Stereotype words for Social Group 2', max_lines=1, elem_id="att2_words_fixed", elem_classes="input_words", interactive=False, visible=True)
|
| 856 |
|
| 857 |
with gr.Row():
|
| 858 |
with gr.Column():
|
|
|
|
| 914 |
with gr.Column(visible=False) as tab3:
|
| 915 |
gr.Markdown("### Tested Social Bias Specification")
|
| 916 |
with gr.Row():
|
| 917 |
+
group1_fixed2 = gr.Textbox(label="Words describing Social Group 1", max_lines=1, elem_id="group1_words_fixed", elem_classes="input_words", interactive=False)
|
| 918 |
+
group2_fixed2 = gr.Textbox(label="Words describing Social Group 2", max_lines=1, elem_id="group2_words_fixed", elem_classes="input_words", interactive=False)
|
| 919 |
with gr.Row():
|
| 920 |
+
att1_fixed2 = gr.Textbox(label="Stereotype words for Social Group 1", max_lines=1, elem_id="att1_words_fixed", elem_classes="input_words", interactive=False)
|
| 921 |
+
att2_fixed2 = gr.Textbox(label='Stereotype words for Social Group 2', max_lines=1, elem_id="att2_words_fixed", elem_classes="input_words", interactive=False)
|
| 922 |
|
| 923 |
with gr.Row():
|
| 924 |
with gr.Column(scale=2):
|