Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -23,9 +23,8 @@ def transcribe_and_summarize(file_path):
|
|
23 |
segments, _ = model.transcribe(audio_file, language="he")
|
24 |
transcript = " ".join([segment.text for segment in segments])
|
25 |
|
26 |
-
# ืกืืืื ืืชืืืื ืขื
|
27 |
-
|
28 |
-
summary = summarizer(transcript)[0]["summary_text"]
|
29 |
|
30 |
# ืืืืงืช ืงืืืฅ ืืืืืื ืืืืืช ืืฆืืจื (ืื ืืื ืืืืื)
|
31 |
if audio_file != file_path:
|
@@ -56,4 +55,4 @@ interface = gr.Interface(
|
|
56 |
)
|
57 |
|
58 |
if __name__ == "__main__":
|
59 |
-
interface.launch()
|
|
|
23 |
segments, _ = model.transcribe(audio_file, language="he")
|
24 |
transcript = " ".join([segment.text for segment in segments])
|
25 |
|
26 |
+
# ืกืืืื ืืชืืืื ืขื ืฉืืืืฉ ื-max_new_tokens
|
27 |
+
summary = summarizer(transcript, max_new_tokens=100)[0]["summary_text"]
|
|
|
28 |
|
29 |
# ืืืืงืช ืงืืืฅ ืืืืืื ืืืืืช ืืฆืืจื (ืื ืืื ืืืืื)
|
30 |
if audio_file != file_path:
|
|
|
55 |
)
|
56 |
|
57 |
if __name__ == "__main__":
|
58 |
+
interface.launch()
|