input_masker / app.py
marcelo3macedo's picture
feat: adding options
ac0e2ca
raw
history blame contribute delete
378 Bytes
import gradio as gr
from lib.masker.masker import run_mask
def mask(text, options):
return run_mask(text, options)
demo = gr.Interface(
fn=mask,
inputs=[
"text",
gr.CheckboxGroup(
choices=["name", "email", "phone", "credit_card", "local"],
label="Select Items"
)
],
outputs="text")
demo.launch(debug=True)