From e2148a5cb3738d8ff4302a1813c30a92b8538ffd Mon Sep 17 00:00:00 2001 From: Yera All Date: Tue, 7 Apr 2026 00:13:22 +0500 Subject: [PATCH] Fix AI not asking name during IVR flow by enforcing voice_start profile --- services/asterisk_bridge_service/config.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/services/asterisk_bridge_service/config.py b/services/asterisk_bridge_service/config.py index aa26fd0..8cfb0ae 100644 --- a/services/asterisk_bridge_service/config.py +++ b/services/asterisk_bridge_service/config.py @@ -231,10 +231,14 @@ def ai_voice_config_for_queue(queue_code: str | None) -> dict[str, Any] | None: next_queue_id = queue_map().get(next_queue_code) if stage == "voice_start" and not handoff_queue_id: handoff_queue_id = next_queue_id + agent_profile = str(item.get("agent_profile") or "voice_support").strip() or "voice_support" + if (key.startswith("ivr_") and "_ai" in key) or key == "voice_lab_ivr": + agent_profile = "voice_start" + return { "queue_code": key, "mode": "ai_first", - "agent_profile": str(item.get("agent_profile") or "voice_support").strip() or "voice_support", + "agent_profile": agent_profile, "language": str(item.get("language") or "").strip() or None, "stage": stage, "next_queue_code": next_queue_code,