mirror of
https://github.com/ParisNeo/lollms.git
synced 2025-04-16 23:08:51 +00:00
Enhanced code
This commit is contained in:
parent
1a49dd9dfc
commit
f1fd6521e3
@ -96,8 +96,6 @@ class LollmsXTTS:
|
||||
self.auto_xtts_url = self.auto_xtts_base_url+"/sdapi/v1"
|
||||
shared_folder = root_dir/"shared"
|
||||
self.xtts_folder = shared_folder / "xtts"
|
||||
self.output_dir = root_dir / "outputs/sd"
|
||||
self.output_dir.mkdir(parents=True, exist_ok=True)
|
||||
|
||||
|
||||
ASCIIColors.red(".____ ________ .____ .____ _____ _________ ____ __________________________________ ")
|
||||
|
@ -1979,6 +1979,20 @@ class APScript(StateMachine):
|
||||
if callback:
|
||||
callback(code, MSG_TYPE.MSG_TYPE_CODE)
|
||||
|
||||
def chunk(self, full_text:str, callback: Callable[[str, MSG_TYPE, dict, list], bool]=None):
|
||||
"""This sends full text to front end
|
||||
|
||||
Args:
|
||||
step_text (dict): The step text
|
||||
callback (callable, optional): A callable with this signature (str, MSG_TYPE) to send the text to. Defaults to None.
|
||||
"""
|
||||
if not callback and self.callback:
|
||||
callback = self.callback
|
||||
|
||||
if callback:
|
||||
callback(full_text, MSG_TYPE.MSG_TYPE_CHUNK)
|
||||
|
||||
|
||||
def full(self, full_text:str, callback: Callable[[str, MSG_TYPE, dict, list], bool]=None):
|
||||
"""This sends full text to front end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user