{% extends "base.html" %} {% block title %}Sentinel — Eval History{% endblock %} {% block content %} {% if not results %}

No evaluation results yet

Run sentinel eval or use the Eval page to generate your first evaluation.

{% else %}
Total Evals
{{ results|length }}
Latest Precision
{{ "%.0f"|format(results[0].precision * 100) }}%
Latest Recall
{{ "%.0f"|format(results[0].recall * 100) }}%
Latest TP / Total
{{ results[0].true_positives }} / {{ results[0].total_findings }}
{% if chart_points|length >= 2 %}
Precision & Recall Trend Precision Recall
{# SVG chart: viewBox 0 0 width height, Y-axis: 0%=bottom, 100%=top #} {% set chart_w = 600 %} {% set chart_h = 200 %} {% set pad_l = 40 %} {% set pad_r = 20 %} {% set pad_t = 10 %} {% set pad_b = 30 %} {% set plot_w = chart_w - pad_l - pad_r %} {% set plot_h = chart_h - pad_t - pad_b %} {% set n = chart_points|length %} {# Y-axis labels and gridlines #} {% for pct in [0, 25, 50, 75, 100] %} {% set y = pad_t + plot_h - (pct / 100 * plot_h) %} {{ pct }}% {% endfor %} {# Threshold lines: precision 70%, recall 90% #} {% set y70 = pad_t + plot_h - (70 / 100 * plot_h) %} {% set y90 = pad_t + plot_h - (90 / 100 * plot_h) %} {# X-axis labels #} {% for pt in chart_points %} {% set x = pad_l + (loop.index0 / (n - 1) * plot_w) if n > 1 else pad_l %} {% if loop.index0 % ((n // 6) + 1) == 0 or loop.last %} {{ pt.label }} {% endif %} {% endfor %} {# Precision polyline #} {# Recall polyline #} {# Data point dots #} {% for pt in chart_points %} {% set x = pad_l + (loop.index0 / (n - 1) * plot_w) if n > 1 else pad_l %} {% endfor %}
{% endif %}
{% for r in results %} {% endfor %}
# Date Repo Findings TP FP Missing Precision Recall Status
{{ r.id }} {{ r.evaluated_at.strftime('%Y-%m-%d %H:%M') }} {{ r.repo_path.split('/')[-1] }} {{ r.total_findings }} {{ r.true_positives }} {{ r.false_positives_found }} {{ r.missing_count }} {{ "%.0f"|format(r.precision * 100) }}% {{ "%.0f"|format(r.recall * 100) }}% {% if r.precision >= 0.7 and r.recall >= 0.9 %} PASS {% else %} FAIL {% endif %}
{% endif %} {% endblock %}