Maps the agent's per-step directive plus the run's sourceArtifactId onto a target plan.
Pure — no I/O. Absent directive reproduces AgentRunner's historical behavior exactly:
a sourceArtifactId is versioned, otherwise the legacy chain (previous artifact on the
message, else a new artifact) applies.
An UNRECOGNIZED behavior resolves exactly like an absent directive. It deliberately does not
fall straight through to 'legacy': 'legacy' means "previous artifact on this message, else a
new one", and on a fresh agent-response detail there is no previous artifact — so dropping the
run's sourceArtifactId on the floor would make a garbled directive STRICTER than no directive
at all, silently starting a new artifact where the continuity signal said to add a version.
The caller logs the mismatch (see IsKnownArtifactBehavior); this function stays pure.
Maps the agent's per-step directive plus the run's sourceArtifactId onto a target plan. Pure — no I/O. Absent directive reproduces AgentRunner's historical behavior exactly: a sourceArtifactId is versioned, otherwise the legacy chain (previous artifact on the message, else a new artifact) applies.
An UNRECOGNIZED behavior resolves exactly like an absent directive. It deliberately does not fall straight through to
'legacy': 'legacy' means "previous artifact on this message, else a new one", and on a fresh agent-response detail there is no previous artifact — so dropping the run'ssourceArtifactIdon the floor would make a garbled directive STRICTER than no directive at all, silently starting a new artifact where the continuity signal said to add a version. The caller logs the mismatch (see IsKnownArtifactBehavior); this function stays pure.