{% extends "base.html" %} {% block title %}Retrieval Debugger — MemoryLens{% endblock %} {% block content %} {% set attrs = span._attrs %} {% set scores = attrs.get('scores', []) %} {% set threshold = attrs.get('threshold', 0) %} {% set top_k = attrs.get('top_k', 0) %} {% set results_count = attrs.get('results_count', 0) %} {% set query = attrs.get('query', span.input_content or '') %}
← Traces / {{ span.trace_id[:12] }} / Retrieval Debugger

Retrieval Debugger

{{ span.operation }} ● {{ span.status }}
{{ span.agent_id or '-' }} · {{ span.session_id or '-' }} · {{ "%.1f"|format(span.duration_ms) }}ms
Query
{{ query }}
Parameters
backend
{{ attrs.get('backend', '-') }}
top_k
{{ top_k }}
threshold
{{ threshold }}
results
{{ results_count }} / {{ top_k }}
{% include "partials/score_chart.html" %} {% set near_misses = [] %} {% for score in scores %} {% if score < threshold and score >= threshold - 0.10 %} {% if near_misses.append(score) %}{% endif %} {% endif %} {% endfor %} {% if near_misses %}
THRESHOLD INSIGHT
{{ near_misses|length }} candidate(s) scored within 0.10 of the {{ threshold }} threshold. If relevant memories are being filtered out, consider lowering the threshold or improving query specificity.
{% endif %}
{% endblock %}