Spaces:
PhilSpiel
/
Sleeping

PhilSpiel commited on
Commit
07373a7
·
verified ·
1 Parent(s): 3753eeb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -21,7 +21,7 @@ openai_model = "gpt-3.5-turbo-0125"
21
  ################# End OpenAI-SPECIFIC VALUES ######################
22
 
23
  tx = os.getenv("TX")
24
- prefix = "/data/" # "data/" if local or not persistent in HF
25
 
26
  ############### CHAT ###################
27
  def predict(user_input, history):
@@ -37,7 +37,7 @@ def predict(user_input, history):
37
  transcript = file.read()
38
  return transcript
39
  except FileNotFoundError:
40
- return "File 'transcript.txt' not found."
41
  elif len(user_input) > max_length:
42
  raise gr.Error(f"Input is TOO LONG. Max length is {max_length} characters. Try again.")
43
 
 
21
  ################# End OpenAI-SPECIFIC VALUES ######################
22
 
23
  tx = os.getenv("TX")
24
+ prefix = "" # "data/" if local or not persistent in HF
25
 
26
  ############### CHAT ###################
27
  def predict(user_input, history):
 
37
  transcript = file.read()
38
  return transcript
39
  except FileNotFoundError:
40
+ return "File " + transcript_file_path + " not found."
41
  elif len(user_input) > max_length:
42
  raise gr.Error(f"Input is TOO LONG. Max length is {max_length} characters. Try again.")
43