ソースを参照

Fixing Error due to 1 Missing Parameter in vn.generate_followup_questions Method

Shubham Thakur 1 年間 前
コミット
840d18dd13
1 ファイル変更3 行追加3 行削除
  1. 3 3
      app.py

+ 3 - 3
app.py

@@ -169,9 +169,9 @@ def add_training_data():
         return jsonify({"type": "error", "error": str(e)})
 
 @app.route('/api/v0/generate_followup_questions', methods=['GET'])
-@requires_cache(['df', 'question'])
-def generate_followup_questions(id: str, df, question):
-    followup_questions = vn.generate_followup_questions(question=question, df=df)
+@requires_cache(['df', 'question', 'sql'])
+def generate_followup_questions(id: str, df, sql, question):
+    followup_questions = vn.generate_followup_questions(question=question, sql=sql, df=df)
 
     cache.set(id=id, field='followup_questions', value=followup_questions)