Skip to content

Evidence

jnrahme edited this page Feb 28, 2026 · 1 revision

Usage Evidence

Every single tool call is logged with full context. When Claude calls rag_search, an enriched evidence entry is written to usage_log.jsonl.

Current Evidence Snapshot

Metric Value
Tool Calls Logged 20,070
Search Hit Rate 54%
Avg Search Latency 838ms
Median Latency 804ms
P95 Latency 2,344ms

By Tool

Tool Calls Percentage
rag_search 14,742 73.4%
rag_dashboard 5,328 26.6%

Search Quality

Outcome Count Percentage
Returned results (relevant) 7,957 54%
Correctly filtered (irrelevant) 6,785 46%

Evidence Log Format

Each search logs the complete story:

{
  "timestamp": "2026-02-27T08:04:30.223791",
  "tool": "rag_search",
  "query": "how to run unit tests in this project",
  "results_count": 5,
  "latency_ms": 10499.5,
  "lessons": [
    {"category": "testing", "relevance_pct": 52, "lesson_text": "Use it.each for parameterized test cases..."},
    {"category": "git", "relevance_pct": 56, "lesson_text": "Run yarn prettier --write, yarn lint:ci..."}
  ],
  "search_meta": {
    "raw_count": 20,
    "distance_filtered": 0,
    "category_filtered": 0,
    "category_filter_used": null,
    "enhanced_query": "Correction for this project: how to run unit tests in this project"
  }
}

Decision Funnel Examples

Relevant Query: "how to style components with theme colors"

20 fetched → 4 too distant → Cross-encoder rerank → 3 returned
  • 72% [code_edit] Use semantic colors from theme tokens
  • 65% [code_edit] Import semanticColors from @/theme
  • 58% [code_edit] Avoid hardcoded colors in StyleSheet.create()

Irrelevant Query: "quantum physics dark matter theory"

20 fetched → 20 too distant → 0 returned

Correctly filtered — distance threshold (1.30) prevents noise.

How to Verify

Method How
CLI Health Check smartassist health — see all 6 subsystem checks
Usage Log Read .claude/smartassist/data/usage_log.jsonl — 20,070+ entries
Test Suite python -m pytest tests/ -v — 59 tests in 0.09s

Clone this wiki locally