Loading...
Loading...
Analyzes logs efficiently through targeted search and iterative refinement. Use when investigating errors, debugging incidents, or analyzing patterns in application logs.
npx skill4agent add rileyhilliard/claude-essentials reading-logs**/*.log
**/logs/**
**/*.log.* # Rotated logs# Severity search
grep -Ei "error|warn" app.log
# Exclude noise
grep -i "ERROR" app.log | grep -v "known-benign"
# Context around matches
grep -C 5 "ERROR" app.log # 5 lines before/after
# Time window
grep "2025-12-04T11:" app.log | grep "ERROR"
# Count occurrences
grep -c "connection refused" app.log# Recent only
tail -n 2000 app.log | grep -Ei "error"
# Top recurring
grep -i "ERROR" app.log | sort | uniq -c | sort -nr | head -20-C-A-BGlobgrep "2025-12-04T11:" service.log | grep -i "timeout"grep "req-abc123" *.loggrep -C 10 "req-abc123" app.loggrep -Ei "error|warn" app.loggrep -i "ERROR" app.log | sort | uniq -c | sort -nr | headscripts/# Aggregate errors by frequency (normalizes timestamps/IDs)
bash scripts/aggregate-errors.sh app.log "ERROR" 20
# Extract and group stack traces by type
bash scripts/extract-stack-traces.sh app.log "NullPointer"
# Parse JSON logs with jq filter
bash scripts/parse-json-logs.sh app.log 'select(.level == "error")'
# Show error distribution over time (hourly/minute buckets)
bash scripts/timeline.sh app.log "ERROR" hour
# Trace a request ID across multiple log files
bash scripts/trace-request.sh req-abc123 logs/
# Find slow operations by duration
bash scripts/slow-requests.sh app.log 1000 20