MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / set_agent

Method set_agent

atomic-agent/src/turn/orchestrator/mod.rs:300–303  ·  view source on GitHub ↗

Set the agent identity for sessions created by this orchestrator. Called by the CLI hook handler after construction, before dispatching events. This ensures new sessions get the correct agent name (e.g., "claude-code" / "Claude Code") instead of "unknown".

(&mut self, name: impl Into<String>, display_name: impl Into<String>)

Source from the content-addressed store, hash-verified

298 /// events. This ensures new sessions get the correct agent name
299 /// (e.g., "claude-code" / "Claude Code") instead of "unknown".
300 pub fn set_agent(&mut self, name: impl Into<String>, display_name: impl Into<String>) {
301 self.agent_name = name.into();
302 self.agent_display_name = display_name.into();
303 }
304
305 /// Attach the managed-run context for this hook invocation
306 /// (see [`ManagedRunContext`]).

Calls

no outgoing calls