mskov commited on
Commit
7198351
·
1 Parent(s): a00c189

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +13 -18
app.py CHANGED
@@ -59,24 +59,19 @@ def inference(audio, state=""):
59
  print("result pre gp model from whisper: ", result, ".text ", result.text, "and the data type: ", type(result.text))
60
 
61
  PROMPT = """The following is an incomplete transcript of a brief conversation.
62
- Predict the next few words in the transcript to complete the sentence.
63
- A few examples of transcripts and predictions are provided below:
64
-
65
-
66
- Example Transcript1: Tomorrow night we're going out to
67
- Example Prediction1: The Movies, A Restaurant, A Baseball Game, The Theater, A Party for a friend
68
-
69
- Example Transcript2: I would like to order a cheeseburger with a side of
70
- Example Prediction2: French fries, Milkshake, Apple slices, Side salad, Extra katsup
71
-
72
- Example Transcript3: My friend Savanah is
73
- Example Prediction3: An elecrical engineer, A marine biologist, A classical musician
74
-
75
- Example Transcript4: I need to buy a birthday
76
- Example Prediction4: Present, Gift, Cake, Card
77
-
78
- Incomplete Transcript:
79
- """
80
  text = PROMPT + result.text + "Prediction: "
81
 
82
  openai.api_key = os.environ["Openai_APIkey"]
 
59
  print("result pre gp model from whisper: ", result, ".text ", result.text, "and the data type: ", type(result.text))
60
 
61
  PROMPT = """The following is an incomplete transcript of a brief conversation.
62
+ Predict the next few words in the transcript to complete the sentence.
63
+ A few examples of transcripts and predictions are provided below:
64
+
65
+ Example Transcript1: Tomorrow night we're going out to
66
+ Example Prediction1: The Movies, A Restaurant, A Baseball Game, The Theater, A Party for a friend
67
+ Example Transcript2: I would like to order a cheeseburger with a side of
68
+ Example Prediction2: French fries, Milkshake, Apple slices, Side salad, Extra katsup
69
+ Example Transcript3: My friend Savanah is
70
+ Example Prediction3: An elecrical engineer, A marine biologist, A classical musician
71
+ Example Transcript4: I need to buy a birthday
72
+ Example Prediction4: Present, Gift, Cake, Card
73
+
74
+ Incomplete Transcript: """
 
 
 
 
 
75
  text = PROMPT + result.text + "Prediction: "
76
 
77
  openai.api_key = os.environ["Openai_APIkey"]