51 lines
1.6 KiB
HTML
51 lines
1.6 KiB
HTML
{% extends "base.html" %}
|
|
|
|
{% block title %}审计日志{% endblock %}
|
|
|
|
{% block content %}
|
|
<header class="page-header">
|
|
<span class="eyebrow">执行留痕</span>
|
|
<h1 class="page-title">审计日志</h1>
|
|
<p class="page-lead">每次 Agent 执行都会记录模型、检索片段、工具调用和最终结果,方便演示链路可解释性。</p>
|
|
{% if selected_scenario_id %}
|
|
<p style="margin-top: 14px;">
|
|
<span class="meta-badge">当前筛选场景:{{ selected_scenario_id }}</span>
|
|
<a class="button" href="{% url 'audit:list' %}">清空筛选</a>
|
|
</p>
|
|
{% endif %}
|
|
</header>
|
|
|
|
<article class="panel">
|
|
<table class="kv-table">
|
|
<thead>
|
|
<tr>
|
|
<th>ID</th>
|
|
<th>场景</th>
|
|
<th>输入摘要</th>
|
|
<th>状态</th>
|
|
<th>模型</th>
|
|
<th>耗时</th>
|
|
<th>创建时间</th>
|
|
<th>详情</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for log in logs %}
|
|
<tr>
|
|
<td>{{ log.id }}</td>
|
|
<td>{{ log.scenario_name }}</td>
|
|
<td>{{ log.get_user_input_summary }}</td>
|
|
<td>{{ log.get_status_display_text }}</td>
|
|
<td>{{ log.model_name }}</td>
|
|
<td>{{ log.latency_ms }} ms</td>
|
|
<td>{{ log.created_at|date:"Y-m-d H:i" }}</td>
|
|
<td><a class="button" href="{% url 'audit:detail' log.id %}">查看详情</a></td>
|
|
</tr>
|
|
{% empty %}
|
|
<tr><td colspan="8">暂无审计日志,先去执行一次对话吧。</td></tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</article>
|
|
{% endblock %}
|