about summary refs log tree commit diff
path: root/gn3/api/llm.py
diff options
context:
space:
mode:
Diffstat (limited to 'gn3/api/llm.py')
-rw-r--r--gn3/api/llm.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/gn3/api/llm.py b/gn3/api/llm.py
index 83b5e85..68e6acc 100644
--- a/gn3/api/llm.py
+++ b/gn3/api/llm.py
@@ -2,7 +2,7 @@
 
 # pylint: skip-file
 
-from flask import jsonify, request, Blueprint
+from flask import jsonify, request, Blueprint, current_app
 
 from gn3.llms.process import getGNQA
 
@@ -16,7 +16,10 @@ def gnqa():
         return jsonify({"error": "querygnqa is missing in the request"}), 400
 
     try:
-        answer, refs = getGNQA(query)
+        auth_token = current_app.config.get("FAHAMU_AUTH_TOKEN")
+        answer, refs = getGNQA(
+            query, auth_token)
+
         return jsonify({
             "query": query,
             "answer": answer,