{% extends "base.html" %} {% block title %}{{ project.name }} Analytics - AutoModerate{% endblock %} {% block page_title %}{{ project.name }} Analytics{% endblock %} {% block page_actions %}
Back to Project
7 Days 30 Days 90 Days
{% endblock %} {% block scripts %} {% endblock %} {% block content %}

{{ project.name }}

{{ project.description or 'No description provided' }}

{{ days }}
Day Analysis

{{ project_stats.total_content }}

Total Content

{{ project_stats.total_moderations }}

Moderations

{{ project_stats.total_rules }}

Active Rules

{{ project_stats.active_api_keys }}

Active Keys

{{ project_stats.total_api_keys }} total

{{ top_users|length }}

Active Users

Content Submissions Over Time ({{ days }} days)
Moderation Decisions
API Keys Usage
{% if api_usage %}
{% for key in api_usage %} {% endfor %}
Key Name Total Usage Status Last Used
{{ key.name or "Unnamed Key" }} {{ key.usage_count or 0 }} {{ 'Active' if key.is_active else 'Inactive' }} {% if key.last_used %} {{ key.last_used.strftime('%Y-%m-%d %H:%M') }} {% else %} Never {% endif %}
{% else %}

No API keys found for this project.

{% endif %}
Content Type Distribution
Top Active Users
{% if top_users %}
{% for user in top_users %} {% endfor %}
User ID Submissions Approved Rejected Rate
{{ user.external_user_id }} {{ user.submissions }} {{ user.approved or 0 }} {{ user.rejected or 0 }} {% if user.submissions > 0 %} {% set rate = ((user.approved or 0) / user.submissions * 100) %} {{ "%.1f"|format(rate) }}% {% else %} N/A {% endif %}
{% else %}

No user activity found for this period.

{% endif %}
Most Triggered Rules
{% if rule_stats %}
{% for rule in rule_stats %} {% endfor %}
Rule Name Type Triggered
{{ rule.name }} {{ rule.rule_type }} {{ rule.triggered }}
{% else %}

No rule activity found for this period.

{% endif %}
Recent Activity
{% if recent_content %}
{% for content in recent_content %} {% endfor %}
Content Type Status User Submitted
{{ content.content_data[:100] }}{% if content.content_data|length > 100 %}...{% endif %}
{{ content.content_type }} {{ content.status }} {% if content.api_user and content.api_user.external_user_id %} {{ content.api_user.external_user_id }} {% else %} Unknown {% endif %} {{ content.created_at.strftime('%Y-%m-%d %H:%M') }}
{% else %}

No recent activity found.

{% endif %}
{% endblock %}