Skip to content

Send a phone call from AI agent, in an API call. Or, directly call the bot from the configured phone number!

Python

fix: Enhance sentences detection

Clémence Lesné4437f748045f
diff --git a/main.py b/main.py
index f690b94..fc4ed5f 100644
--- a/main.py
+++ b/main.py
@@ -144,7 +144,7 @@ api = FastAPI(
CALL_EVENT_URL = f'{CONFIG.api.events_domain.strip("/")}/call/event/{{phone_number}}/{{callback_secret}}'
-SENTENCE_R = r"[^\w\s+\-/'\",:;()@=]"
+SENTENCE_R = r"[^\w\s+\-–—’/'\",:;()@=]"
MESSAGE_ACTION_R = rf"action=([a-z_]*)( .*)?"
MESSAGE_STYLE_R = rf"style=([a-z_]*)( .*)?"
FUNC_NAME_SANITIZER_R = r"[^a-zA-Z0-9_-]"