-
Notifications
You must be signed in to change notification settings - Fork 0
Update receptionist opening line to Jess script #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -207,7 +207,7 @@ def build_reception_instructions() -> str: | |
| "but do not overuse fillers. " | ||
| "\n\n" | ||
| "Call flow rules:\n" | ||
| f"1) First turn must be exactly: 'This is {business_name}, {ASSISTANT_NAME} speaking. How can I help?'\n" | ||
| "1) First turn must be exactly: 'Downtown Demo Barbershop, this is Jess— I can help you get booked or check what we have open. What are you looking to come in for today?'\n" | ||
| "2) Be helpful first: answer the caller's question directly before suggesting any next step.\n" | ||
| "3) Do not pressure, upsell, or repeatedly circle back to appointments. Only mention booking when the caller asks to book or when it genuinely helps answer their question.\n" | ||
| "4) If the caller interrupts, changes the subject, or asks a new question, stop the current response immediately in your next turn, answer the new request, and drop any unfinished booking script.\n" | ||
|
|
@@ -300,11 +300,10 @@ async def agent_session(ctx: JobContext) -> None: | |
| ), | ||
| ) | ||
|
|
||
| business_name = str( | ||
| BUSINESS_PROFILE.get("business_name", "Downtown Demo Barber Shop") | ||
| ) | ||
| await session.say( | ||
|
Comment on lines
-303
to
306
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. suggestion: Duplicated, hard-coded greeting string in The first-turn utterance is defined both in Suggested implementation: "\n\n"
"Call flow rules:\n"
f"1) First turn must be exactly: '{FIRST_TURN_GREETING}'\n"
"2) Be helpful first: answer the caller's question directly before suggesting any next step.\n"
"3) Do not pressure, upsell, or repeatedly circle back to appointments. Only mention booking when the caller asks to book or when it genuinely helps answer their question.\n"
"4) If the caller interrupts, changes the subject, or asks a new question, stop the current response immediately in your next turn, answer the new request, and drop any unfinished booking script.\n"
),
)
await session.say(FIRST_TURN_GREETING)To complete the refactor and avoid duplication, you should also:
|
||
| f"This is {business_name}, {ASSISTANT_NAME} speaking. How can I help?" | ||
| "Downtown Demo Barbershop, this is Jess— " | ||
| "I can help you get booked or check what we have open. " | ||
| "What are you looking to come in for today?" | ||
|
Comment on lines
303
to
+306
|
||
| ) | ||
|
|
||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -157,11 +157,11 @@ async def test_uses_caller_led_opening_line() -> None: | |||||||||||
| .judge( | ||||||||||||
| llm, | ||||||||||||
| intent=""" | ||||||||||||
| Uses a natural phone greeting like: | ||||||||||||
| - "This is Downtown Demo Barber Shop, Jessica speaking." | ||||||||||||
| - Asks "How can I help?" | ||||||||||||
| Uses this caller-led opening greeting: | ||||||||||||
| - "Downtown Demo Barbershop, this is Jess—" | ||||||||||||
| - "I can help you get booked or check what we have open. What are you looking to come in for today?" | ||||||||||||
|
Comment on lines
+160
to
+162
|
||||||||||||
| Uses this caller-led opening greeting: | |
| - "Downtown Demo Barbershop, this is Jess—" | |
| - "I can help you get booked or check what we have open. What are you looking to come in for today?" | |
| The assistant must use this exact opening greeting verbatim, including punctuation and spacing: | |
| "Downtown Demo Barbershop, this is Jess—I can help you get booked or check what we have open. What are you looking to come in for today?" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The prompt now hardcodes a first-turn greeting with “Downtown Demo Barbershop” and “Jess”, but elsewhere in the same instructions the agent identity still uses the configurable BUSINESS_PROFILE business_name and ASSISTANT_NAME (defaulting to “Downtown Demo Barber Shop” / “Jessica”). This inconsistency can confuse the model and makes the “must be exactly” rule more fragile. Consider either (a) aligning BUSINESS_PROFILE/defaults + ASSISTANT_NAME to match this exact script, or (b) generating the greeting from those configured values so the identity is consistent end-to-end.