Chat Message Flow
End-to-end flow for a single chatbot message — moderation, agent selection, RAG retrieval, tool execution, and streaming response from /api/chatbot/stream
End-to-end flow for a single chatbot message — moderation, agent selection, RAG retrieval, tool execution, and streaming response from /api/chatbot/stream
Definitive source of truth for the entire chatbot request lifecycle, from HTTP request arrival to response return. Every code path, every tool, every third-party call, every expected result. Generated 2026-04-02 from a full read of every file in the pipeline.
Multi-layer content moderation for the chatbot — blocklist patterns, LLM-based abuse detection, user restriction tracking, and crisis escalation to 988 / church staff
How both the chatbot and voice agent detect crisis signals (suicidal ideation, domestic violence, medical emergencies), immediately route to safety resources (988), and escalate to pastoral staff
Complete audit of every protection mechanism for the ChurchWiseAI chatbot and voice agent, with gap analysis and the test/baseline/benchmark framework definition.
Non-technical walkthrough of a complete voice call — from phone ring through greeting, RAG lookup, tool use, potential Care Agent handoff, and post-call DB writes
Step-by-step pipeline for each voice turn — noise filtering, moderation check, RAG retrieval, LLM inference, tool execution, and TTS output — implemented via on_user_turn_completed callbacks and call_handler.py utilities