Skip to content

Trajectories

Sample attack paths through a manifest using algorithmic samplers. Goals, strategies, counts, and seeds.

A trajectory is a sampled attack path through a manifest — a sequence of commands, their targets, the outputs, and the state transitions they cause. Trajectories are durable: once generation completes, you can replay, score, or feed them into training.

This page covers the built-in algorithmic samplers: kali and c2. To run your own agent against a manifest instead, see Agent-mode trajectories.

Terminal window
dn worlds trajectory-create \
--manifest-id <manifest-id> \
--goal "Domain Admins" \
--count 4 \
--strategy smart-random \
--mode kali \
--max-steps 100 \
--seed 42 \
--json

The command returns a job record. Wait on it before listing or replaying:

Terminal window
dn worlds job-wait <job-id>
dn worlds trajectory-list --manifest-id <manifest-id>
dn worlds trajectory-get <trajectory-id>

Each trajectory record carries success, termination_reason, step_count, and artifact_refs pointing to the stored step record.

--goal is a natural-language target the sampler aims for — for example "Domain Admins" (the default), "Escalate to local admin on DC01", or "Exfiltrate credentials from HR workstation". The sampler interprets it against the manifest’s principals and hosts.

Goals don’t have to be reachable. A goal the sampler can’t satisfy produces trajectories with success=false and a termination reason explaining why, which is often what you want for negative training examples.

ModeWhen to pick it
kaliDeterministic, Kali-flavored command sampler. Fast, no external agent. The default choice for volume.
c2Command-and-control sampler that models post-exploitation traffic. Same deterministic shape as kali, different command vocabulary.
agentRuns a capability-bound agent against the environment. See Agent-mode trajectories.

kali and c2 share the same strategy, goal, and step-limit controls. agent adds runtime and capability bindings.

Strategies control how the sampler picks the next command from the manifest’s command vocabulary:

StrategyBehavior
randomUniform random choice over applicable commands. Noisy but diverse.
greedyPrefer commands that move measurably toward the goal.
recon-firstFront-load enumeration (host/service/principal discovery) before exploitation.
smart-randomWeighted random, biased toward productive commands without being fully greedy.

smart-random is the usual starting point. Use random to generate harder negatives; use greedy when you want short canonical paths.

  • --count — number of trajectories to generate in one job. Each gets a distinct sequence_index.
  • --max-steps — per-trajectory cap. Trajectories that hit the cap terminate with a max_steps reason.
  • --seed — makes sampling deterministic given the same manifest, goal, strategy, and mode. Different seeds produce different paths through the same graph.
  • --threads — parallelism inside the Worlds backend. Higher values finish faster at the cost of determinism ordering between trajectories.

--only-successful discards trajectories that didn’t satisfy the goal before returning. Useful when you need positive examples for SFT and don’t want to filter downstream. It still counts against --count — if you asked for 10 and only 4 succeeded, you get 4.

Trajectories show up under Worlds → Trajectories in the web app. Each list entry shows a success dot, goal, strategy, step count, and parent manifest ID. Clicking a trajectory opens:

  • Overview — the trajectory record (goal, strategy, termination reason, artifact refs).
  • Steps — the replay inspector, when step artifacts are available. See Replay & artifacts.

Completed trajectory jobs publish a training dataset alongside the individual records. See Training integration for loading trajectories as SFT conversations, offline-RL rows, or rollout inputs.