mskov commited on
Commit
8f42210
1 Parent(s): dea79d3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -85,7 +85,7 @@ def inference(audio, state=""):
85
 
86
  infers = []
87
  temp = []
88
- infer=""
89
  for i in range(5):
90
  print("print1 ", response['choices'][i]['text'])
91
  temp.append(response['choices'][i]['text'])
@@ -95,6 +95,7 @@ def inference(audio, state=""):
95
  #infered = list(map(lambda x: x.split(',')[0], infers))
96
  #print("Infered type is: ", type(infered))
97
  infers = list(map(lambda x: x.replace("\n", ""), temp))
 
98
 
99
 
100
 
@@ -104,7 +105,7 @@ def inference(audio, state=""):
104
 
105
  # result.text
106
  #return getText, gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
107
- return result.text, state, infers
108
 
109
 
110
 
 
85
 
86
  infers = []
87
  temp = []
88
+ infered=[]
89
  for i in range(5):
90
  print("print1 ", response['choices'][i]['text'])
91
  temp.append(response['choices'][i]['text'])
 
95
  #infered = list(map(lambda x: x.split(',')[0], infers))
96
  #print("Infered type is: ", type(infered))
97
  infers = list(map(lambda x: x.replace("\n", ""), temp))
98
+ infered = list(map(lambda x: x.split(','), infers))
99
 
100
 
101
 
 
105
 
106
  # result.text
107
  #return getText, gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
108
+ return result.text, state, infered
109
 
110
 
111