{% extends 'base.html' %} {% load dashboard_extras %} {% block title %}Data View | Chat Analytics{% endblock %} {% block content %}

Data View

Back to Dashboard {% if selected_data_source %} View Source {% endif %}
Data Source Selection
Chat Sessions {% if selected_data_source %} for {{ selected_data_source.name }} {% endif %} {% if view != 'all' %} ({{ view|title }}) {% endif %}
{{ page_obj.paginator.count }} sessions
{% for session in page_obj %} {% empty %} {% endfor %}
Session ID Start Time Country Language Messages Sentiment Response Time Category Actions
{{ session.session_id|truncatechars:10 }} {{ session.start_time|date:"M d, Y H:i" }} {{ session.country|default:"N/A" }} {{ session.language|default:"N/A" }} {{ session.messages_sent }} {% if session.sentiment %} {% if 'positive' in session.sentiment|lower %} {{ session.sentiment }} {% elif 'negative' in session.sentiment|lower %} {{ session.sentiment }} {% elif 'neutral' in session.sentiment|lower %} {{ session.sentiment }} {% else %} {{ session.sentiment }} {% endif %} {% else %} N/A {% endif %} {{ session.avg_response_time|floatformat:2 }}s {{ session.category|default:"N/A" }}
No chat sessions found.
{% if page_obj.paginator.num_pages > 1 %} {% endif %}
{% if page_obj %}
Summary
Total Sessions

{{ page_obj.paginator.count }}

Chat conversations

Avg Response Time

{{ avg_response_time|floatformat:2 }}s

Average response

Avg Messages

{{ avg_messages|floatformat:1 }}

Per conversation

Escalation Rate

{{ escalation_rate|floatformat:1 }}%

Escalated sessions

{% endif %} {% endblock %}