Kartik Basavaraj commited on
Commit
5c0ff4f
·
1 Parent(s): 8cfb2f1

Modified errors in sample transcription and SSL error

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -1,7 +1,10 @@
1
  import gradio as gr
2
  import requests
 
3
  import os
4
 
 
 
5
  VM_ENDPOINT = os.environ.get("VM_ENDPOINT", "https://sltts.slingo.ai/tts")
6
 
7
  SAMPLES = [
@@ -115,7 +118,7 @@ def run_tts(text):
115
  if not VM_ENDPOINT:
116
  return None, "⚠️ Live inference endpoint not configured yet."
117
  try:
118
- response = requests.post(VM_ENDPOINT, json={"text": text}, timeout=30)
119
  if response.status_code == 200:
120
  tmp_path = "/tmp/tts_output.wav"
121
  with open(tmp_path, "wb") as f:
 
1
  import gradio as gr
2
  import requests
3
+ import urllib3
4
  import os
5
 
6
+ urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
7
+
8
  VM_ENDPOINT = os.environ.get("VM_ENDPOINT", "https://sltts.slingo.ai/tts")
9
 
10
  SAMPLES = [
 
118
  if not VM_ENDPOINT:
119
  return None, "⚠️ Live inference endpoint not configured yet."
120
  try:
121
+ response = requests.post(VM_ENDPOINT, json={"text": text}, timeout=30, verify=False)
122
  if response.status_code == 200:
123
  tmp_path = "/tmp/tts_output.wav"
124
  with open(tmp_path, "wb") as f: