burak commited on
Commit
5c5eb25
·
verified ·
1 Parent(s): 9292334

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -0
app.py CHANGED
@@ -16,6 +16,8 @@ import pandas as pd
16
  OPENAI_API_KEY = os.environ.get('OPENAI_API_KEY')
17
  MAPS_API_KEY = os.environ.get('MAPS_API_KEY')
18
 
 
 
19
  client = OpenAI(api_key=OPENAI_API_KEY)
20
 
21
  def get_place_details(place_id, api_key):
@@ -166,6 +168,9 @@ def provide_user_specific_recommendations(user_input, location):
166
 
167
  def bot(user_input, history,Konum):
168
 
 
 
 
169
  if Konum:
170
  output = provide_user_specific_recommendations(user_input, Konum)
171
 
 
16
  OPENAI_API_KEY = os.environ.get('OPENAI_API_KEY')
17
  MAPS_API_KEY = os.environ.get('MAPS_API_KEY')
18
 
19
+ LOC_ERR_MSG = "Lütfen yukaradıki bölümden konum giriniz."
20
+
21
  client = OpenAI(api_key=OPENAI_API_KEY)
22
 
23
  def get_place_details(place_id, api_key):
 
168
 
169
  def bot(user_input, history,Konum):
170
 
171
+ if not Konum:
172
+ yield LOC_ERR_MSG
173
+
174
  if Konum:
175
  output = provide_user_specific_recommendations(user_input, Konum)
176