Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Peter Szemraj
commited on
Commit
•
43f2bd7
1
Parent(s):
88c9634
👽️ update api
Browse filesSigned-off-by: Peter Szemraj <[email protected]>
app.py
CHANGED
@@ -92,7 +92,7 @@ aggregator = BatchAggregator(
|
|
92 |
|
93 |
def aggregate_text(
|
94 |
summary_text: str,
|
95 |
-
text_file: gr.
|
96 |
) -> str:
|
97 |
"""
|
98 |
Aggregate the text from the batches.
|
@@ -533,7 +533,7 @@ if __name__ == "__main__":
|
|
533 |
label="File Upload",
|
534 |
file_count="single",
|
535 |
file_types=[".txt", ".md", ".pdf"],
|
536 |
-
type="
|
537 |
)
|
538 |
with gr.Row():
|
539 |
input_text = gr.Textbox(
|
@@ -564,7 +564,7 @@ if __name__ == "__main__":
|
|
564 |
text_file = gr.File(
|
565 |
label="Download as Text File",
|
566 |
file_count="single",
|
567 |
-
type="
|
568 |
interactive=False,
|
569 |
)
|
570 |
with gr.Column(variant="compact"):
|
@@ -684,4 +684,4 @@ if __name__ == "__main__":
|
|
684 |
inputs=[summary_text, text_file],
|
685 |
outputs=[aggregated_summary],
|
686 |
)
|
687 |
-
demo.launch(
|
|
|
92 |
|
93 |
def aggregate_text(
|
94 |
summary_text: str,
|
95 |
+
text_file: gr.File = None,
|
96 |
) -> str:
|
97 |
"""
|
98 |
Aggregate the text from the batches.
|
|
|
533 |
label="File Upload",
|
534 |
file_count="single",
|
535 |
file_types=[".txt", ".md", ".pdf"],
|
536 |
+
type="filepath",
|
537 |
)
|
538 |
with gr.Row():
|
539 |
input_text = gr.Textbox(
|
|
|
564 |
text_file = gr.File(
|
565 |
label="Download as Text File",
|
566 |
file_count="single",
|
567 |
+
type="filepath",
|
568 |
interactive=False,
|
569 |
)
|
570 |
with gr.Column(variant="compact"):
|
|
|
684 |
inputs=[summary_text, text_file],
|
685 |
outputs=[aggregated_summary],
|
686 |
)
|
687 |
+
demo.launch(share=args.share, debug=True)
|