mirror of
https://github.com/KoboldAI/KoboldAI-Client.git
synced 2025-06-05 21:59:24 +02:00
Support title in aidg import
This commit is contained in:
@@ -297,6 +297,7 @@ class ImportBuffer:
|
|||||||
authors_note: Optional[str] = None
|
authors_note: Optional[str] = None
|
||||||
notes: Optional[str] = None
|
notes: Optional[str] = None
|
||||||
world_infos: Optional[dict] = None
|
world_infos: Optional[dict] = None
|
||||||
|
title: Optional[str] = None
|
||||||
|
|
||||||
@dataclass
|
@dataclass
|
||||||
class PromptPlaceholder:
|
class PromptPlaceholder:
|
||||||
@@ -416,6 +417,7 @@ class ImportBuffer:
|
|||||||
self.memory = j["memory"]
|
self.memory = j["memory"]
|
||||||
self.authors_note = j["authorsNote"]
|
self.authors_note = j["authorsNote"]
|
||||||
self.notes = j["description"]
|
self.notes = j["description"]
|
||||||
|
self.title = j["title"] or "Imported Story"
|
||||||
|
|
||||||
self.world_infos = []
|
self.world_infos = []
|
||||||
|
|
||||||
@@ -449,6 +451,7 @@ class ImportBuffer:
|
|||||||
koboldai_vars.memory = self.memory or ""
|
koboldai_vars.memory = self.memory or ""
|
||||||
koboldai_vars.authornote = self.authors_note or ""
|
koboldai_vars.authornote = self.authors_note or ""
|
||||||
koboldai_vars.notes = self.notes
|
koboldai_vars.notes = self.notes
|
||||||
|
koboldai_vars.story_name = self.title
|
||||||
|
|
||||||
for wi in self.world_infos:
|
for wi in self.world_infos:
|
||||||
koboldai_vars.worldinfo_v2.add_item(
|
koboldai_vars.worldinfo_v2.add_item(
|
||||||
|
Reference in New Issue
Block a user