mgokg commited on
Commit
01fdbba
·
verified ·
1 Parent(s): c7a30fb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -9
app.py CHANGED
@@ -60,15 +60,7 @@ def predict(prompt):
60
 
61
  if response and response.text:
62
  return response.text
63
- else:
64
- logging.error(f"Unexpected response: {response}")
65
- return "Error: Could not extract text from the response."
66
- except genai.APIError as e:
67
- logging.error(f"API error occurred: {e}")
68
- raise
69
- except Exception as e:
70
- logging.error(f"An error occurred: {e}")
71
- return f"An error occurred: {e}"
72
 
73
  # Create the Gradio interface
74
  with gr.Blocks(css=custom_css) as demo:
 
60
 
61
  if response and response.text:
62
  return response.text
63
+
 
 
 
 
 
 
 
 
64
 
65
  # Create the Gradio interface
66
  with gr.Blocks(css=custom_css) as demo: