eaglelandsonce commited on
Commit
1c6c2c1
·
1 Parent(s): f0d974c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -4
app.py CHANGED
@@ -44,13 +44,10 @@ def chat_with_model(prompt, document_section):
44
 
45
  def transcribe_audio(file_path, model):
46
 
47
- headers = {
48
- "Authorization": f"Bearer {openai.api_key}",
49
- }
50
  with open(file_path, 'rb') as f:
51
  data = {'file': f}
52
  # check for correctness - lively addition
53
- response = requests.post(openai.api_key, headers=headers, files=data, data={'model': model})
54
  if response.status_code == 200:
55
  st.write(response.json())
56
  response2 = chat_with_model(response.json().get('text'), '')
 
44
 
45
  def transcribe_audio(file_path, model):
46
 
 
 
 
47
  with open(file_path, 'rb') as f:
48
  data = {'file': f}
49
  # check for correctness - lively addition
50
+ response = requests.post(openai.api_key, files=data, data={'model': model})
51
  if response.status_code == 200:
52
  st.write(response.json())
53
  response2 = chat_with_model(response.json().get('text'), '')