mskov commited on
Commit
4b8269d
·
1 Parent(s): 34ff8a4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -62,13 +62,13 @@ def inference(audio, state=""):
62
  A few examples are provided below and then the current transcript is provided.
63
  Examples:
64
  Transcript: Tomorrow night we're going out to
65
- Next: The Movies to watch a blockbuster, A Restaurant for dinner, A Baseball Game, The Theater, A Party for a friend
66
  Transcript: I would like to order a cheeseburger with a side of
67
- Next: Frnech fries, Milkshake, Apple slices, Side salad, Extra katsup
68
  Transcript: My friend Savanah is
69
- Next: An elecrical engineer, A marine biologist, A classical musician
70
  Transcript: I need to buy a birthday
71
- Next: Present, Gift, Cake, Card
72
  """
73
  text = PROMPT + result.text
74
 
@@ -89,13 +89,13 @@ def inference(audio, state=""):
89
  print("print2: infers ", infers)
90
  print("print3: Responses ", response)
91
  print("Object type of response: ", type(response))
92
- infers = list(map(lambda x: x.split(',')[0], infers))
93
 
94
 
95
 
96
  # result.text
97
  #return getText, gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
98
- return result.text, state, infers
99
 
100
 
101
 
 
62
  A few examples are provided below and then the current transcript is provided.
63
  Examples:
64
  Transcript: Tomorrow night we're going out to
65
+ Prediction: The Movies to watch a blockbuster, A Restaurant for dinner, A Baseball Game, The Theater, A Party for a friend
66
  Transcript: I would like to order a cheeseburger with a side of
67
+ Prediction: Frnech fries, Milkshake, Apple slices, Side salad, Extra katsup
68
  Transcript: My friend Savanah is
69
+ Prediction: An elecrical engineer, A marine biologist, A classical musician
70
  Transcript: I need to buy a birthday
71
+ Prediction: Present, Gift, Cake, Card
72
  """
73
  text = PROMPT + result.text
74
 
 
89
  print("print2: infers ", infers)
90
  print("print3: Responses ", response)
91
  print("Object type of response: ", type(response))
92
+ infered = list(map(lambda x: x.split(',')[0], infers))
93
 
94
 
95
 
96
  # result.text
97
  #return getText, gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
98
+ return result.text, state, infered
99
 
100
 
101