Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -12,7 +12,8 @@ from dotenv import load_dotenv
|
|
| 12 |
from datetime import datetime
|
| 13 |
import requests
|
| 14 |
from requests.exceptions import RequestException
|
| 15 |
-
from
|
|
|
|
| 16 |
from download import download_video_audio, delete_download
|
| 17 |
from st_audiorec import st_audiorec # Import the audio recorder component
|
| 18 |
|
|
@@ -42,7 +43,7 @@ if 'transcription_error' not in st.session_state:
|
|
| 42 |
|
| 43 |
# Set page configuration
|
| 44 |
st.set_page_config(
|
| 45 |
-
page_title="
|
| 46 |
page_icon
|
| 47 |
="π§ββοΈ",
|
| 48 |
layout="wide",
|
|
@@ -328,12 +329,12 @@ def process_transcript(transcript):
|
|
| 328 |
|
| 329 |
prompt = f"""
|
| 330 |
You are an expert meeting notes organizer with exceptional skills in creating structured, clear, and comprehensive notes.
|
| 331 |
-
Please analyze the following transcript and transform it into
|
| 332 |
|
| 333 |
```
|
| 334 |
{transcript}
|
| 335 |
```
|
| 336 |
-
|
| 337 |
Create a professional meeting notes document with the following specific sections:
|
| 338 |
|
| 339 |
# Executive Summary
|
|
@@ -494,8 +495,8 @@ def export_notes(notes, format="markdown"):
|
|
| 494 |
)
|
| 495 |
|
| 496 |
def main():
|
| 497 |
-
st.title("π§ββοΈ
|
| 498 |
-
st.markdown("Transform speech into
|
| 499 |
|
| 500 |
# Initialize API key from environment (Hugging Face secrets)
|
| 501 |
if st.session_state.api_key and not st.session_state.groq_client:
|
|
@@ -545,7 +546,7 @@ def main():
|
|
| 545 |
st.markdown(transcript)
|
| 546 |
|
| 547 |
if st.button("Generate Structured Notes", key="generate_live"):
|
| 548 |
-
with st.spinner("Creating
|
| 549 |
notes = process_transcript(transcript)
|
| 550 |
|
| 551 |
if notes:
|
|
@@ -596,7 +597,7 @@ def main():
|
|
| 596 |
with st.expander("View Transcript", expanded=True):
|
| 597 |
st.markdown(transcript)
|
| 598 |
|
| 599 |
-
with st.spinner("Creating
|
| 600 |
notes = process_transcript(transcript)
|
| 601 |
|
| 602 |
if notes:
|
|
@@ -651,7 +652,7 @@ def main():
|
|
| 651 |
with st.expander("View Transcript", expanded=True):
|
| 652 |
st.markdown(transcript)
|
| 653 |
|
| 654 |
-
with st.spinner("Creating
|
| 655 |
notes = process_transcript(transcript)
|
| 656 |
|
| 657 |
if notes:
|
|
@@ -690,7 +691,7 @@ def main():
|
|
| 690 |
st.session_state.transcript = transcript
|
| 691 |
|
| 692 |
if st.button("Generate Structured Notes", key="process_text"):
|
| 693 |
-
with st.spinner("Creating
|
| 694 |
notes = process_transcript(transcript)
|
| 695 |
|
| 696 |
if notes:
|
|
|
|
| 12 |
from datetime import datetime
|
| 13 |
import requests
|
| 14 |
from requests.exceptions import RequestException
|
| 15 |
+
from
|
| 16 |
+
typing import Optional, Dict, Any
|
| 17 |
from download import download_video_audio, delete_download
|
| 18 |
from st_audiorec import st_audiorec # Import the audio recorder component
|
| 19 |
|
|
|
|
| 43 |
|
| 44 |
# Set page configuration
|
| 45 |
st.set_page_config(
|
| 46 |
+
page_title="NoteME",
|
| 47 |
page_icon
|
| 48 |
="π§ββοΈ",
|
| 49 |
layout="wide",
|
|
|
|
| 329 |
|
| 330 |
prompt = f"""
|
| 331 |
You are an expert meeting notes organizer with exceptional skills in creating structured, clear, and comprehensive notes.
|
| 332 |
+
Please analyze the following transcript and transform it into organized meeting notes in the same language as the Transcript ensuring Clarity:
|
| 333 |
|
| 334 |
```
|
| 335 |
{transcript}
|
| 336 |
```
|
| 337 |
+
|
| 338 |
Create a professional meeting notes document with the following specific sections:
|
| 339 |
|
| 340 |
# Executive Summary
|
|
|
|
| 495 |
)
|
| 496 |
|
| 497 |
def main():
|
| 498 |
+
st.title("π§ββοΈ Note")
|
| 499 |
+
st.markdown("Transform speech into structured notes")
|
| 500 |
|
| 501 |
# Initialize API key from environment (Hugging Face secrets)
|
| 502 |
if st.session_state.api_key and not st.session_state.groq_client:
|
|
|
|
| 546 |
st.markdown(transcript)
|
| 547 |
|
| 548 |
if st.button("Generate Structured Notes", key="generate_live"):
|
| 549 |
+
with st.spinner("Creating structured notes..."):
|
| 550 |
notes = process_transcript(transcript)
|
| 551 |
|
| 552 |
if notes:
|
|
|
|
| 597 |
with st.expander("View Transcript", expanded=True):
|
| 598 |
st.markdown(transcript)
|
| 599 |
|
| 600 |
+
with st.spinner("Creating structured notes..."):
|
| 601 |
notes = process_transcript(transcript)
|
| 602 |
|
| 603 |
if notes:
|
|
|
|
| 652 |
with st.expander("View Transcript", expanded=True):
|
| 653 |
st.markdown(transcript)
|
| 654 |
|
| 655 |
+
with st.spinner("Creating structured notes..."):
|
| 656 |
notes = process_transcript(transcript)
|
| 657 |
|
| 658 |
if notes:
|
|
|
|
| 691 |
st.session_state.transcript = transcript
|
| 692 |
|
| 693 |
if st.button("Generate Structured Notes", key="process_text"):
|
| 694 |
+
with st.spinner("Creating structured notes..."):
|
| 695 |
notes = process_transcript(transcript)
|
| 696 |
|
| 697 |
if notes:
|