fix : jsonify problem in server

This commit is contained in:
martin legrand
2025-03-29 12:26:58 +01:00
parent 75ac1631c4
commit 8106cff45f
2 changed files with 2 additions and 0 deletions
+1
View File
@@ -41,6 +41,7 @@ class GeneratorLLM():
def get_status(self) -> dict:
with self.state.lock:
print("Returning status:\n", self.state.status())
return jsonify(self.state.status())
@abstractmethod
+1
View File
@@ -121,6 +121,7 @@ class Provider:
is_complete = False
while not is_complete:
response = requests.get(f"http://{self.server_ip}/get_updated_sentence")
print("raw:", response.json())
thought = response.json()["sentence"]
is_complete = bool(response.json()["is_complete"])
time.sleep(2)