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

Method set_agent

atomic-agent/src/turn/orchestrator/mod.rs:313–316  ·  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

311 /// events. This ensures new sessions get the correct agent name
312 /// (e.g., "claude-code" / "Claude Code") instead of "unknown".
313 pub fn set_agent(&mut self, name: impl Into<String>, display_name: impl Into<String>) {
314 self.agent_name = name.into();
315 self.agent_display_name = display_name.into();
316 }
317
318 /// Attach the managed-run context for this hook invocation
319 /// (see [`ManagedRunContext`]).

Calls

no outgoing calls