All lessons › Function E — The Agentic SOC › Understand — Correlation, Intel and the Hunt
E3.5

Agent-assisted reconstruction — a timeline you can challenge

E3
▶
Lightboard recording

Not recorded yet. The lesson below is complete and runnable today — the video is added later without touching this page.

Video placeholderpublishes automatically from recordings/E3.5.mp4
Risk

Reaching for the agent once you're already behind.

Control

Pre-load logs, telemetry, segmentation model and playbooks.

The lab

Reconstruct a timeline from raw logs with a context-loaded agent.

◉Use case relevance

Reconstruction is reading, and agents read fast. The speed is real and so is the failure mode: a timeline that is 95% right and completely confident is worse than no timeline, because somebody will make decisions on it.

At CyberTravels. Reconstruction is pre-loaded or it is late. Everything the timeline needs already exists — A2.1's spans, A2.2's rows, B2.7's motive — and E1.3 decided how long each field survives. The timeline you can challenge is the one built from inputs rather than from the model's account of them.

◴What this lesson is — Day 0, Day 1, Day 2

Reconstruction as something pre-loaded rather than reached for once you are already behind, and the difference between a timeline built from inputs and one built from the agent's account of them.

Day 0 — why

A model correlates thousands of log lines in seconds and will produce a fluent narrative from logs that never supported one.

Day 1 — how

Separate what the logs establish from what the reconstruction infers, and keep the evidence beside each claim.

Day 2 — measure

Claims with a log line behind them, as a share of claims in the timeline. A fast conclusion is not a finished one.

Measure this

what to measuredenominator or target
claims with a log line behind themshare of claims in the timeline

▦The framework, and how it works

   scattered evidence            reconstructed timeline
   +------------------+          +---------------------+
   | 6 log sources    |   -->    | ordered, attributed |
   | 900k lines       |          | 40 events           |
   +------------------+          +---------------------+
                                          |
                              every claim carries its source line
                              unsourced claim -> not in the timeline

Reconstruction is the first phase of any incident: build the timeline, establish what happened, decide what to contain.

An agent makes this faster and more dangerous at the same time. Faster, because a model can correlate thousands of log lines in seconds. More dangerous, because it will produce a fluent, confident narrative from logs that were never sufficient to support one — and a fluent narrative is much harder to challenge than an obviously incomplete one.

So the discipline is to separate two questions that feel like one:

  1. What do the logs say?
  2. What can the logs support?

The gap between them is where reconstruction goes wrong, and it is the responder's job to state that gap explicitly in the incident record.

Anchor → E1.0. This shortens the interval and can end it in the wrong place at the same time. A model correlates thousands of log lines in seconds, and will produce a fluent narrative from logs that never supported one — which is harder to challenge than an obviously incomplete one, so a fast conclusion is not the same as a finished one.

2 · Demo — a timeline that reads perfectly

3 · Where it breaks — the confident wrong narrative

4 · The control — state what the evidence can support

The fix is not a better model. It is a reconstruction step that reports its own evidentiary limits before it reports a conclusion.

5 · The procedure, as a skill

The timeline attributes every action to dana@corp and the fluent narrative recommends suspending her. The skill renders that view first, produces the truth view from an independent source, and then gates every claim on a field that supports it.

▶Real time execution as skill

The skill — skills/response/incident-reconstruction-check/SKILL.md

name: incident-reconstruction-check
description: >-
  Reconstruct an incident from logs that attribute every action to a human,
  check what the evidence actually supports, and refuse to publish a narrative
  it does not carry. Use during response, when the timeline names a person and
  an agent did the work.
allowed-tools: Read, Grep, Glob

The fluent narrative recommends suspending the wrong person

Agent logs that record only the delegated principal produce a timeline in which a human did everything. A model asked to summarise it writes something fluent and confident that recommends suspending her. The reconstruction is not wrong about the events; it is wrong about the actor, and nothing in the log says so.

When to use this

Every incident involving an agent, and before any narrative reaches a person who will act on it.

Procedure

1 — Render the timeline as the logs have it. Do not correct it yet. This is what an investigator would see, and seeing it is the point.

2 — Ask which field carries the acting identity. Not the delegated principal — the identity that performed the action. If no field carries it, stop: every attribution below is inherited from the request, not observed.

3 — Produce the truth view from an independent source where one exists — host accounting, the gateway, the downstream's own log. Diff it against the timeline and record what changes. Usually one or two actions move from the human to the agent, and they are the important ones.

4 — Gate the narrative on evidence. A summary may assert only what a field supports. Attach the field to each claim; a claim with no field is removed, not softened.

5 — Publish the safe version and the gap. State plainly which questions the record cannot answer. An investigation that says so is more useful than one that fills the gap fluently.

Example

Input — the fixture committed at the top of scripts/incident_reconstruction_check.py. Edit it and re-run: the buckets, counts and verdicts below are derived from it, not hard-coded.

Output — the opening lines of a real run:

WHAT THE RESPONDER SEES
   t+s  actor           action          target
     0  dana@corp       login           sso
    22  dana@corp       open_ticket     SEC-4471
    40  dana@corp       read_file       /work/repo/billing.py
    41  dana@corp       read_file       /home/app/.aws/credentials
    43  dana@corp       http_post       collect.example.com
   180  dana@corp       logout          sso

The run continues past this. test_skills.py executes the script on every build, with no model configured — so what CI proves is that it runs and refuses legibly, not that it prints these lines. The output above is a recorded run against a real model, and nothing re-diffs it: a model's answer is not reproducible, and this repository does not claim otherwise anywhere it can be checked.

Output contract

{
  "timeline": [{"at": "str", "attributed_to": "str", "action": "str"}],
  "acting_identity_field": "str|null",
  "truth_view": [{"at": "str", "actual_actor": "str", "action": "str", "source": "str"}],
  "narrative": {"claims": [{"text": "str", "supported_by": "str|null"}], "removed": 0},
  "gaps": ["str"]
}

Failure modes

  • Publishing the fluent version. It is confident and it names a person.
  • Correcting the timeline before showing it. The uncorrected view is what everyone else is looking at.
  • Softening unsupported claims. Remove them.

Three ways to do this lesson. Pick one. They run the same procedure against the same code — what changes is who drives it, and how much you see.

1In your AI agent — you are taught

The agent reads the lesson, explains the idea, fetches the code, runs the check and answers your questions as you go. This is the one to take if you are here to learn.

Install it, once. From the folder you cloned. --all does every agent it finds on your machine:

python3 scripts/install_skills.py --all --lessons E3.5

Then restart your agent and open it in that folder. On Windows, if python3 says Python was not found, use python instead.

Then pick e3-5-agent-assisted-reconstruction:

agentinstall just for this agentstart it
Claude Codepython3 scripts/install_skills.py --tool claude --lessons E3.5type /e3-5-agent-assisted-reconstruction
GitHub Copilot (VS Code)python3 scripts/install_skills.py --tool copilot --lessons E3.5type /e3-5-agent-assisted-reconstruction in Chat
Cursorpython3 scripts/install_skills.py --tool cursor --lessons E3.5type / in Agent chat and search for it
Codexpython3 scripts/install_skills.py --tool agents --lessons E3.5type $e3-5-agent-assisted-reconstruction, or run /skills

2As one Python command — you just run it

No agent, no conversation. The same lesson executes and prints the same readback. Take this one if you have no assistant, if you are reviewing rather than learning, or if you want the result without the teaching around it.

python3 scripts/lesson.py E3.5

3Read the code, and the difference — nothing runs

Neither of the above, and no model needed. The first command writes CyberTravels exactly as it stood at the end of this lesson; the second prints the diff — the lines this lesson added or changed, and nothing from any later one.

python3 scripts/checkpoint.py --at E3.5 --out work/cybertravels
python3 scripts/checkpoint.py --at E3.5 --diff

On Windows, type python wherever these say python3 — and use \ instead of / in the paths. Everything else is identical. A0.0 step 2 explains why.

Ways 1 and 2 need a model; way 3 does not. A signed-in Claude Code CLI needs no API key, and any OpenAI-compatible endpoint works too. With neither, the audit exits 2 and says so rather than inventing an answer. A0.0 sets this up.

Ways 1 and 2 both end with the same readback: What I did, What changed, The number and Read this next. A step that was skipped or refused is reported as exactly that, never as a pass.

If you did the last lesson’s challenge, expect this to stop. Most challenges ask you to edit the code, and ways 1 and 2 will not overwrite your edits: you get stopped, not a failure, with two options — --out for a fresh folder that keeps your work, or --force to discard it and start this lesson clean.

✓What you just proved

The timeline attributes every action to dana@corp. The fluent narrative recommends suspending her. The truth view shows patch-agent performed the credential read and the external POST; reconstruction reports BROKEN attribution with 3 misattributed lines. The evidence check flags the missing acting-identity field, the missing chain, and a non-human action rate.

✎Your turn

Take a real incident timeline from your own history and ask what it would look like if an agent had been operating on the user's credential. If you cannot tell from the logs, your reconstructions already carry this risk.

Tools used

VelociraptorOpenSearchGLM-4.6Claude Haiku 4.5

Skill source: skills/response/incident-reconstruction-check

← PreviousE3.4 · When the actor is an agent — three instincts that misfire