Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -433,7 +433,44 @@ def whisper_main():
|
|
433 |
transcription = transcribe_audio(filename)
|
434 |
st.write(transcription)
|
435 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
436 |
|
|
|
437 |
def main():
|
438 |
|
439 |
st.title("AI Drome Llama")
|
|
|
433 |
transcription = transcribe_audio(filename)
|
434 |
st.write(transcription)
|
435 |
|
436 |
+
# Define button descriptions
|
437 |
+
descriptions = {
|
438 |
+
"Generate Limericks: π": "Write ten random adult limericks based on quotes that are tweet length and make you laugh π",
|
439 |
+
"Wise Quotes: π§": "Generate ten wise quotes that are tweet length π¦",
|
440 |
+
"Funny Rhymes: π€": "Create ten funny rhymes that are tweet length πΆ",
|
441 |
+
"Medical Jokes: π": "Create ten medical jokes that are tweet length π₯",
|
442 |
+
"Minnesota Humor: βοΈ": "Create ten jokes about Minnesota that are tweet length π¨οΈ",
|
443 |
+
"Top Funny Stories: π": "Create ten funny stories that are tweet length π",
|
444 |
+
"More Funny Rhymes: ποΈ": "Create ten more funny rhymes that are tweet length π΅"
|
445 |
+
}
|
446 |
+
|
447 |
+
# Create columns
|
448 |
+
col1, col2, col3 = st.columns([1, 1, 1], gap="small")
|
449 |
+
|
450 |
+
# Add buttons to columns
|
451 |
+
if col1.button("Generate Limericks: π"):
|
452 |
+
StreamLLMChatResponse(descriptions["Generate Limericks: π"] + ' using the context information from this transcript: ' + transcription)
|
453 |
+
# Create columns
|
454 |
+
col1, col2, col3 = st.columns([1, 1, 1], gap="small")
|
455 |
+
# Add buttons to columns
|
456 |
+
if col1.button("Generate Limericks: π"):
|
457 |
+
StreamLLMChatResponse(descriptions["Generate Limericks: π"] + ' using the context information from this transcript: ' + transcription)
|
458 |
+
if col2.button("Wise Quotes π§"):
|
459 |
+
StreamLLMChatResponse(descriptions["Wise Quotes: π§"] + ' using the context information from this transcript: ' + transcription)
|
460 |
+
if col3.button("Funny Rhymes: π€"):
|
461 |
+
StreamLLMChatResponse(descriptions["Funny Rhymes: π€"] + ' using the context information from this transcript: ' + transcription)
|
462 |
+
col4, col5, col6 = st.columns([1, 1, 1], gap="small")
|
463 |
+
if col4.button("Medical Jokes: π"):
|
464 |
+
StreamLLMChatResponse(descriptions["Medical Jokes: π"] + ' using the context information from this transcript: ' + transcription)
|
465 |
+
if col5.button("Minnesota Humor βοΈ"):
|
466 |
+
StreamLLMChatResponse(descriptions["Minnesota Humor: βοΈ"] + ' using the context information from this transcript: ' + transcription)
|
467 |
+
if col6.button("Top Funny Stories π"):
|
468 |
+
StreamLLMChatResponse(descriptions["Top Funny Stories: π"] + ' using the context information from this transcript: ' + transcription)
|
469 |
+
col7 = st.columns(1, gap="small")
|
470 |
+
if col7[0].button("More Funny Rhymes: ποΈ"):
|
471 |
+
StreamLLMChatResponse(descriptions["More Funny Rhymes: ποΈ"] + ' using the context information from this transcript: ' + transcription)
|
472 |
|
473 |
+
|
474 |
def main():
|
475 |
|
476 |
st.title("AI Drome Llama")
|