Spaces:
Build error
Build error
import combine_modules | |
import gradio as gr | |
with gr.Blocks() as demo: | |
gr.Markdown("Welcome to Bias Checking Demo !") | |
with gr.Tab("Text"): | |
text_input = gr.Textbox() | |
text_output = gr.Textbox() | |
text_output_interpret = gr.TextArea() | |
text_button = gr.Button("Check Bias in your Text") | |
with gr.Tab("Video"): | |
vid_input = gr.Video() | |
vid_output = gr.Textbox() | |
vid_output_interpret = gr.TextArea() | |
vid_button = gr.Button("Check Bias in your Video") | |
with gr.Tab("Image"): | |
img_input = gr.Image() | |
img_output = gr.Textbox() | |
img_output_interpret = gr.TextArea() | |
img_button = gr.Button("Check Bias in your Image") | |
text_button.click(combine_modules.app_nlp_start, inputs=text_input, outputs=[text_output, text_output_interpret]) | |
vid_button.click(combine_modules.app_video_start, inputs=vid_input, outputs=[vid_output, vid_output_interpret]) | |
img_button.click(combine_modules.app_image_start, inputs=img_input, outputs=[img_output, img_output_interpret]) | |
if __name__=="__main__": | |
demo.launch() | |