uumerrr684 commited on
Commit
f25e5ae
Β·
verified Β·
1 Parent(s): f2d289d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -21
app.py CHANGED
@@ -454,11 +454,6 @@ def process_voice_input(audio_file):
454
  return "No audio received. Please try recording again."
455
 
456
  # Placeholder for speech recognition
457
- # In a real implementation, you would use libraries like:
458
- # - speech_recognition
459
- # - whisper
460
- # - Google Speech-to-Text API
461
-
462
  return "Voice input received! (Speech recognition would be implemented here with libraries like Whisper or SpeechRecognition)"
463
 
464
  def reset_conversation():
@@ -620,8 +615,7 @@ def create_gradio_interface():
620
 
621
  with gr.Blocks(
622
  css=custom_css,
623
- title="πŸ₯ Hybrid AI Assistant - Healthcare Billing Expert",
624
- theme=gr.themes.Soft()
625
  ) as demo:
626
 
627
  # Header Section
@@ -666,9 +660,8 @@ def create_gradio_interface():
666
  examples=examples,
667
  title="",
668
  description="πŸ’¬ Start chatting! I can help with healthcare billing codes, general questions, and adapt to your emotional tone.",
669
- submit_btn="Send πŸ“€",
670
- retry_btn="πŸ”„ Retry",
671
- undo_btn="↩️ Undo",
672
  clear_btn="πŸ—‘οΈ Clear"
673
  )
674
 
@@ -785,14 +778,4 @@ demo = create_gradio_interface()
785
  # No need for manual demo.launch() in Hugging Face Spaces
786
  if __name__ == "__main__":
787
  # This block will be executed when running locally
788
- # For Hugging Face Spaces, remove this and just export the demo
789
- demo.launch(
790
- server_name="0.0.0.0",
791
- server_port=7860,
792
- share=True,
793
- debug=True
794
- )
795
-
796
- # For Hugging Face Spaces deployment, export the demo
797
- # Uncomment the line below when deploying to Hugging Face Spaces
798
- # demo.queue().launch()
 
454
  return "No audio received. Please try recording again."
455
 
456
  # Placeholder for speech recognition
 
 
 
 
 
457
  return "Voice input received! (Speech recognition would be implemented here with libraries like Whisper or SpeechRecognition)"
458
 
459
  def reset_conversation():
 
615
 
616
  with gr.Blocks(
617
  css=custom_css,
618
+ title="πŸ₯ Hybrid AI Assistant - Healthcare Billing Expert"
 
619
  ) as demo:
620
 
621
  # Header Section
 
660
  examples=examples,
661
  title="",
662
  description="πŸ’¬ Start chatting! I can help with healthcare billing codes, general questions, and adapt to your emotional tone.",
663
+ retry_btn="↻ Retry",
664
+ undo_btn="β†Ί Undo",
 
665
  clear_btn="πŸ—‘οΈ Clear"
666
  )
667
 
 
778
  # No need for manual demo.launch() in Hugging Face Spaces
779
  if __name__ == "__main__":
780
  # This block will be executed when running locally
781
+ demo.launch(debug=True)