Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -14,7 +14,7 @@ from langchain_huggingface import ChatHuggingFace, HuggingFaceEndpoint
|
|
14 |
llm = HuggingFaceEndpoint(
|
15 |
repo_id="mistralai/Mistral-7B-Instruct-v0.3",
|
16 |
task="text-generation",
|
17 |
-
max_new_tokens=
|
18 |
do_sample=False,
|
19 |
)
|
20 |
llm_engine_hf = ChatHuggingFace(llm=llm)
|
@@ -87,7 +87,7 @@ with gr.Blocks() as demo:
|
|
87 |
file = gr.File(label="Submit a file")
|
88 |
|
89 |
with gr.Column():
|
90 |
-
output_text = gr.
|
91 |
|
92 |
submit_button = gr.Button("Summarize")
|
93 |
submit_button.click(summarize, inputs=[file, n_words], outputs=output_text)
|
|
|
14 |
llm = HuggingFaceEndpoint(
|
15 |
repo_id="mistralai/Mistral-7B-Instruct-v0.3",
|
16 |
task="text-generation",
|
17 |
+
max_new_tokens=4096,
|
18 |
do_sample=False,
|
19 |
)
|
20 |
llm_engine_hf = ChatHuggingFace(llm=llm)
|
|
|
87 |
file = gr.File(label="Submit a file")
|
88 |
|
89 |
with gr.Column():
|
90 |
+
output_text = gr.Textbox(label="Summary", lines=20)
|
91 |
|
92 |
submit_button = gr.Button("Summarize")
|
93 |
submit_button.click(summarize, inputs=[file, n_words], outputs=output_text)
|