Skip to main content

Knowledge > Runbooks > Chatbot Ops > Handle a Chatbot Care Agent Escalation

Handle a Chatbot Care Agent Escalation

Respond to a Care Agent escalation notification. The Care Agent (Claude Haiku 4.5) handles pastoral care conversations — grief, crisis, illness, spiritual distress — and escalates when human pastoral follow-up is required.

Background

The Care Agent monitors chatbot conversations for signals of pastoral need. When it detects a high-urgency situation (crisis, grief, medical emergency, suicidal ideation), it:

  1. Captures the contact information in voice_visitor_contacts or voice_prayer_requests
  2. Sends an escalation notification to the church admin email
  3. Logs the conversation with urgency markers

The voice_prayer_requests table is shared between voice and chatbot — "voice_" is a legacy prefix.

Prerequisites

  • Supabase MCP or direct DB access
  • Church admin contact information
  • Access to escalation notification (email or dashboard alert)

Steps

  1. Identify the escalation source — check the notification for:

    • Church name and ID
    • Escalation type (crisis / grief / pastoral / medical)
    • Timestamp of the conversation
    • Contact information captured (if the user provided it)
  2. Pull the escalation record from the database:

    SELECT
    pr.id,
    pr.church_id,
    pr.requester_name,
    pr.requester_phone,
    pr.request_text,
    pr.urgency,
    pr.source_type,
    pr.status,
    pr.created_at
    FROM voice_prayer_requests pr
    WHERE pr.church_id = '[uuid]'
    AND pr.source_type = 'chatbot'
    AND pr.urgency IN ('crisis', 'high')
    AND pr.created_at >= now() - interval '24 hours'
    ORDER BY pr.created_at DESC;
  3. Assess the urgency level:

    • Crisis (suicidal ideation, immediate danger): Contact emergency services if location is known. Notify church pastor immediately. Do not wait.
    • High (grief, medical, deep distress): Contact church pastor within 1–2 hours for pastoral follow-up.
    • Normal pastoral (prayer request, spiritual questions): Include in next pastoral care summary.
  4. Contact the church pastor/admin:

    SELECT pc.admin_email, c.name, c.phone
    FROM premium_churches pc
    JOIN churches c ON c.id = pc.church_id
    WHERE pc.church_id = '[uuid]';

    Email or call the admin. Include: the escalation type, the user's contact info (if captured), the approximate time of the conversation, and a recommendation to follow up.

  5. If the visitor left contact information, retrieve it:

    SELECT caller_name, caller_email, caller_phone, visit_interest, notes, created_at
    FROM voice_visitor_contacts
    WHERE church_id = '[uuid]'
    AND created_at >= now() - interval '24 hours'
    ORDER BY created_at DESC;
  6. Mark the request as escalated after notifying the church:

    UPDATE voice_prayer_requests
    SET status = 'escalated', updated_at = now()
    WHERE id = '[request-uuid]';
  7. Log the follow-up action in the status or notes field:

    UPDATE voice_prayer_requests
    SET status = 'notified',
    updated_at = now()
    WHERE id = '[request-uuid]';

When a User Is In Immediate Danger

If the escalation indicates someone is in immediate danger (self-harm, medical emergency):

  1. Contact emergency services (911) if location is known.
  2. Notify the church pastor immediately by phone.
  3. If no contact info was captured, document the timestamp and encourage the church to have pastoral staff monitor any follow-up contacts.

The chatbot displays a crisis resources message (988 Suicide & Crisis Lifeline) during these conversations by design.

Verification

  • Church pastor/admin has been contacted and is aware of the follow-up need.
  • voice_prayer_requests.status updated from pending to escalated or notified.

See Also