Thiloid commited on
Commit
89b305d
·
verified ·
1 Parent(s): 9e2d2e2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -195,10 +195,10 @@ def responsefull(
195
  seed=42,
196
  )
197
  #get ID
198
- full_url = gr.Request.url
199
  IDval= get_value_after_question_mark(full_url)
200
  print(full_url)
201
- headers = gr.Request.headers
202
  IP, dev = extract_ip_and_device(headers)
203
 
204
  #if is_single_word_question(prompt)==1:
@@ -300,7 +300,7 @@ with gr.Blocks(title="test") as demo:
300
  textbox = gr.Textbox(label="Deine Frage")
301
 
302
  def combined_response(prompt, history, dropdown_value):
303
- answer = responsefull(gr.Request,prompt, history, dropdown_value)
304
  return history + [[prompt, answer]]
305
 
306
  submit_button = gr.Button("Submit")
 
195
  seed=42,
196
  )
197
  #get ID
198
+ full_url = request.url
199
  IDval= get_value_after_question_mark(full_url)
200
  print(full_url)
201
+ headers = request.headers
202
  IP, dev = extract_ip_and_device(headers)
203
 
204
  #if is_single_word_question(prompt)==1:
 
300
  textbox = gr.Textbox(label="Deine Frage")
301
 
302
  def combined_response(prompt, history, dropdown_value):
303
+ answer = responsefull(request,prompt, history, dropdown_value)
304
  return history + [[prompt, answer]]
305
 
306
  submit_button = gr.Button("Submit")