feat: integrate JV Voice Profile cloning, Voicebox research, and ensure session voice/markdown prompt nudge
This commit is contained in:
@@ -30,6 +30,8 @@ _LIST_MARKER = re.compile(r"^[ \t]*[-*•]\s+", re.MULTILINE)
|
||||
_UNDERSCORE_WORD = re.compile(r"(?<=\w)_(?=\w)")
|
||||
_EXTRA_SPACE = re.compile(r"[ \t]{2,}")
|
||||
_CONTROL_TAGS = re.compile(r"\[(COMPLETE|NEEDS_DEEP|STATUS:[^\]]+)\]", re.IGNORECASE)
|
||||
_MARKDOWN_LINK = re.compile(r"\[([^\]]+)\]\((https?://[^\s)]+)\)")
|
||||
_BARE_URL = re.compile(r"https?://\S+")
|
||||
_VOICE_TAG = re.compile(r"\[Voice:\s*([a-zA-Z0-9_\-]+)\]", re.IGNORECASE)
|
||||
|
||||
|
||||
@@ -56,6 +58,8 @@ class SpokenTextFilter(MarkdownTextFilter):
|
||||
pass
|
||||
|
||||
text = _TIMES.sub(" times ", text)
|
||||
text = _MARKDOWN_LINK.sub(r"\1", text)
|
||||
text = _BARE_URL.sub("", text)
|
||||
text = await super().filter(text)
|
||||
text = _CONTROL_TAGS.sub("", text)
|
||||
text = _STRIKETHROUGH.sub(r"\1", text)
|
||||
|
||||
Reference in New Issue
Block a user