← ClaudeAtlas

logdet-timelinelisted

Reconstructs what happened around an incident across services by merging logs of different formats into one UTC-ordered timeline, windowed around a given moment, tagged by source, with the first occurrence of each error signature ("first bad line") and error-rate spikes marked. Use when the user says "what happened at 14:03", "build a timeline of the outage", "correlate these logs", "which service failed first", "line up the web, worker and db logs", or "when did this start".
vivekbhange-hub/log-detective-skill · ★ 0 · Code & Development · score 75
Install: claude install-skill vivekbhange-hub/log-detective-skill
# logdet-timeline: one clock for every service Each service logs in its own format and time zone, so the cause is hard to see until the logs share a timeline. `timeline.py` parses every timestamp to UTC, merges the files, cuts a window around the incident and marks the lines worth reading. ## Inputs - Two or more log files (JSON lines, text, logfmt, syslog, nginx/apache access logs, `.gz`). `label=path` names a source; otherwise the file name is the label. - When it started, as the user knows it ("around 14:03 UTC"). If they give local time, ask for the zone and convert it. - The zone of logs whose timestamps carry none (`--tz`). Default is UTC; say that out loud. - Commands below say `python3`; on Windows use `python` (or `py -3`). ## Outputs - `logs-triage/timeline.md` and optionally `logs-triage/timeline.json`. - In chat: the first bad line with its source and time, the spike window, and the sequence of events across services in a few sentences, each with its `source:line` reference. ## Steps 1. **Confirm authorization.** The logs must belong to systems the user owns or may analyse. 2. **Build the timeline:** ``` python3 "${CLAUDE_SKILL_DIR}/timeline.py" web.jsonl worker.log db.log nginx-access.log \ --around 2026-11-12T14:03:00Z --window 10m --redact -o logs-triage/timeline.md ``` - `--window` is the half-width: `10m` covers 10 minutes either side. `--before` and `--after` override each side; `--since` and `--until` replace `--around`.