Add clear cache indicators to output
- Show "⚡ CACHED RESULTS (Xh old)" in compact output header - Add "use --refresh for fresh data" hint - Track from_cache and cache_age_hours in Report schema - Update UI to show cache age in stderr message Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -29,6 +29,13 @@ def render_compact(report: schema.Report, limit: int = 15) -> str:
|
||||
# Header
|
||||
lines.append(f"## Research Results: {report.topic}")
|
||||
lines.append("")
|
||||
|
||||
# Cache indicator
|
||||
if report.from_cache:
|
||||
age_str = f"{report.cache_age_hours:.1f}h old" if report.cache_age_hours else "cached"
|
||||
lines.append(f"**⚡ CACHED RESULTS** ({age_str}) - use `--refresh` for fresh data")
|
||||
lines.append("")
|
||||
|
||||
lines.append(f"**Date Range:** {report.range_from} to {report.range_to}")
|
||||
lines.append(f"**Mode:** {report.mode}")
|
||||
if report.openai_model_used:
|
||||
|
||||
Reference in New Issue
Block a user