diff options
Diffstat (limited to 'gn3/llms/process.py')
-rw-r--r-- | gn3/llms/process.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gn3/llms/process.py b/gn3/llms/process.py index 58d565a..526c1b3 100644 --- a/gn3/llms/process.py +++ b/gn3/llms/process.py @@ -7,6 +7,9 @@ import time import string import json import os +from urllib.request import urlretrieve +from urllib.parse import quote + from gn3.llms.client import GeneNetworkQAClient from gn3.llms.response import DocIDs @@ -77,7 +80,7 @@ def filterResponseText(val): def getGNQA(query, auth_token): apiClient = GeneNetworkQAClient(requests.Session(), api_key=auth_token) - res, task_id = apiClient.ask('?ask=' + query, auth_token) + res, task_id = apiClient.ask('?ask=' + quote(query), auth_token) res, success = apiClient.get_answer(task_id) if (success == 1): |