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

refacto: Citations prompt name

Clémence Lesnédbff290b916b
diff --git a/helpers/config_models/prompts.py b/helpers/config_models/prompts.py
index e4cde7f..f935027 100644
--- a/helpers/config_models/prompts.py
+++ b/helpers/config_models/prompts.py
@@ -181,7 +181,7 @@ class LlmModel(BaseSettings, env_prefix="prompts_llm_"):
Conversation history:
{messages}
"""
- citations_tpl: str = """
+ citations_system_tpl: str = """
Assitant will add Markdown citations to the text. Citations are used to add additional context to the text, without cluttering the content itself.
Assitant:
@@ -361,7 +361,7 @@ class LlmModel(BaseSettings, env_prefix="prompts_llm_"):
reminders=_pydantic_to_str(reminders),
)
- def citations(
+ def citations_system(
self,
claim: ClaimModel,
messages: List[MessageModel],
@@ -369,7 +369,7 @@ class LlmModel(BaseSettings, env_prefix="prompts_llm_"):
text: str,
) -> str:
return self._return(
- self.citations_tpl,
+ self.citations_system_tpl,
claim=_pydantic_to_str(claim),
messages=_pydantic_to_str(
[
diff --git a/main.py b/main.py
index 32eb4f3..f04903b 100644
--- a/main.py
+++ b/main.py
@@ -1246,7 +1246,7 @@ async def post_call_synthesis(call: CallModel) -> None:
max_tokens=100,
),
gpt_completion(
- system=CONFIG.prompts.llm.citations(
+ system=CONFIG.prompts.llm.citations_system(
claim=call.claim,
messages=call.messages,
reminders=call.reminders,