Ankur Goyal commited on
Commit ·
27d0a44
1
Parent(s): 84cfd64
Small styling tweaks
Browse files135 unmodified lines1361371381391401411422 unmodified lines1451461471481491501518 unmodified lines160161162163164165135 unmodified linesreturn document, question, preview, answerwith gr.Blocks() as demo:gr.Markdown("# DocQuery: Query Documents w/ NLP")document = gr.Variable()example_question = gr.Textbox(visible=False)2 unmodified linesgr.Markdown("## 1. Upload a file or select an example")with gr.Row(equal_height=True):with gr.Column():upload = gr.File(label="Upload a file", interactive=True)url = gr.Textbox(label="... or a URL", interactive=True)gr.Examples(examples=examples,8 unmodified linesplaceholder="e.g. What is the invoice number?",lines=1,max_lines=1,)model = gr.Radio(choices=list(CHECKPOINTS.keys()),135 unmodified lines1361371381391401411421431441451461471481491501512 unmodified lines1541551561571581591601611628 unmodified lines171172173174175176177135 unmodified linesreturn document, question, preview, answerCSS = """#short-upload-box .w-full {min-height: 10rem !important;}#question input {font-size: 16px;}"""with gr.Blocks(css=CSS) as demo:gr.Markdown("# DocQuery: Query Documents w/ NLP")document = gr.Variable()example_question = gr.Textbox(visible=False)2 unmodified linesgr.Markdown("## 1. Upload a file or select an example")with gr.Row(equal_height=True):with gr.Column():upload = gr.File(label="Upload a file", interactive=True, elem_id="short-upload-box")url = gr.Textbox(label="... or a URL", interactive=True)gr.Examples(examples=examples,8 unmodified linesplaceholder="e.g. What is the invoice number?",lines=1,max_lines=1,elem_id="question",)model = gr.Radio(choices=list(CHECKPOINTS.keys()),
app.py+14-2