amish1706 commited on
Commit
3172412
·
verified ·
1 Parent(s): 565663b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -4
app.py CHANGED
@@ -52,7 +52,6 @@ def ask_chatbot(query, chat_history, project_data):
52
 
53
  return answer
54
 
55
-
56
  def generate_response(message, history):
57
  project_data = {}
58
  if os.path.exists("/content/project_data.json"):
@@ -60,8 +59,6 @@ def generate_response(message, history):
60
  project_data = json.load(f)
61
  return ask_chatbot(message, history, project_data)
62
 
63
-
64
-
65
  def upload_file(data_file):
66
  with open(data_file.name, "r") as f:
67
  data = json.load(f)
@@ -74,7 +71,7 @@ with gr.Blocks() as demo:
74
  u = gr.UploadButton("Upload a file", file_count="single")
75
  u.upload(upload_file, u)
76
  gr.ChatInterface(
77
- yes_man,
78
  chatbot=gr.Chatbot(height=300),
79
  title="AI Project Manager",
80
  description="Virtual Project Management Assistant",
 
52
 
53
  return answer
54
 
 
55
  def generate_response(message, history):
56
  project_data = {}
57
  if os.path.exists("/content/project_data.json"):
 
59
  project_data = json.load(f)
60
  return ask_chatbot(message, history, project_data)
61
 
 
 
62
  def upload_file(data_file):
63
  with open(data_file.name, "r") as f:
64
  data = json.load(f)
 
71
  u = gr.UploadButton("Upload a file", file_count="single")
72
  u.upload(upload_file, u)
73
  gr.ChatInterface(
74
+ generate_response,
75
  chatbot=gr.Chatbot(height=300),
76
  title="AI Project Manager",
77
  description="Virtual Project Management Assistant",