mirror of
https://github.com/KoboldAI/KoboldAI-Client.git
synced 2025-06-05 21:59:24 +02:00
revert more unrelated code
This commit is contained in:
@@ -11211,7 +11211,7 @@ def get_story():
|
|||||||
chunks = []
|
chunks = []
|
||||||
if koboldai_vars.gamestarted:
|
if koboldai_vars.gamestarted:
|
||||||
chunks.append({"num": 0, "text": koboldai_vars.prompt})
|
chunks.append({"num": 0, "text": koboldai_vars.prompt})
|
||||||
for num, action in koboldai_vars.actions.actions.items():
|
for num, action in koboldai_vars.actions.items():
|
||||||
chunks.append({"num": num + 1, "text": action})
|
chunks.append({"num": num + 1, "text": action})
|
||||||
return {"results": chunks}
|
return {"results": chunks}
|
||||||
|
|
||||||
@@ -11597,7 +11597,7 @@ def get_world_info():
|
|||||||
if wi["folder"] != last_folder:
|
if wi["folder"] != last_folder:
|
||||||
folder = []
|
folder = []
|
||||||
if wi["folder"] is not None:
|
if wi["folder"] is not None:
|
||||||
folders.append({"uid": wi["folder"], "name": koboldai_vars.wifolders_d[str(wi["folder"])]["name"], "entries": folder})
|
folders.append({"uid": wi["folder"], "name": koboldai_vars.wifolders_d[wi["folder"]]["name"], "entries": folder})
|
||||||
last_folder = wi["folder"]
|
last_folder = wi["folder"]
|
||||||
(folder if wi["folder"] is not None else entries).append({k: v for k, v in wi.items() if k not in ("init", "folder", "num") and (wi["selective"] or k != "keysecondary")})
|
(folder if wi["folder"] is not None else entries).append({k: v for k, v in wi.items() if k not in ("init", "folder", "num") and (wi["selective"] or k != "keysecondary")})
|
||||||
return {"folders": folders, "entries": entries}
|
return {"folders": folders, "entries": entries}
|
||||||
@@ -11685,7 +11685,7 @@ def get_world_info_folders():
|
|||||||
"""
|
"""
|
||||||
stablesortwi()
|
stablesortwi()
|
||||||
koboldai_vars.worldinfo_i = [wi for wi in koboldai_vars.worldinfo if wi["init"]]
|
koboldai_vars.worldinfo_i = [wi for wi in koboldai_vars.worldinfo if wi["init"]]
|
||||||
return {"folders": [{"uid": folder, **{k: v for k, v in koboldai_vars.wifolders_d[str(folder)].items() if k != "collapsed"}} for folder in koboldai_vars.wifolders_l]}
|
return {"folders": [{"uid": folder, **{k: v for k, v in koboldai_vars.wifolders_d[folder].items() if k != "collapsed"}} for folder in koboldai_vars.wifolders_l]}
|
||||||
|
|
||||||
|
|
||||||
@api_v1.get("/world_info/folders/uids")
|
@api_v1.get("/world_info/folders/uids")
|
||||||
|
@@ -1801,7 +1801,6 @@ class KoboldStoryRegister(object):
|
|||||||
if "wi_highlighted_text" in self.actions[action_id]:
|
if "wi_highlighted_text" in self.actions[action_id]:
|
||||||
del self.actions[action_id]["wi_highlighted_text"]
|
del self.actions[action_id]["wi_highlighted_text"]
|
||||||
self.actions[action_id]['Selected Text Length'] = 0
|
self.actions[action_id]['Selected Text Length'] = 0
|
||||||
self.action_count -= 1
|
|
||||||
process_variable_changes(self._socketio, "story", 'actions', {"id": action_id, 'action': self.actions[action_id]}, None)
|
process_variable_changes(self._socketio, "story", 'actions', {"id": action_id, 'action': self.actions[action_id]}, None)
|
||||||
self.set_game_saved()
|
self.set_game_saved()
|
||||||
logger.debug("Calcing AI Text from Action Delete")
|
logger.debug("Calcing AI Text from Action Delete")
|
||||||
|
Reference in New Issue
Block a user