diff --git a/koboldcpp.py b/koboldcpp.py index 40441cffa..54cf75d90 100755 --- a/koboldcpp.py +++ b/koboldcpp.py @@ -303,7 +303,7 @@ maxhordectx = 1024 maxhordelen = 256 modelbusy = threading.Lock() defaultport = 5001 -KcppVersion = "1.39.2" +KcppVersion = "1.40" showdebug = True showsamplerwarning = True showmaxctxwarning = True @@ -495,7 +495,7 @@ class ServerRequestHandler(http.server.SimpleHTTPRequestHandler): laste = handle.get_last_eval_time() lastc = handle.get_last_token_count() stopreason = handle.get_last_stop_reason() - response_body = (json.dumps({"last_process":lastp,"last_eval":laste,"last_token_count":lastc, "stop_reason":stopreason}).encode()) + response_body = (json.dumps({"last_process":lastp,"last_eval":laste,"last_token_count":lastc, "stop_reason":stopreason, "idle":(0 if modelbusy.locked() else 1)}).encode()) if response_body is None: self.send_response(404)