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

Function normalize_agent_name

atomic-agent/src/identity.rs:383–389  ·  view source on GitHub ↗

Normalize the agent name for use in the `+tag`. Removes hyphens and converts to lowercase for a clean tag format. ```rust use atomic_agent::identity::normalize_agent_name; assert_eq!(normalize_agent_name("claude-code"), "claude"); assert_eq!(normalize_agent_name("gemini-cli"), "gemini"); assert_eq!(normalize_agent_name("codex"), "codex"); assert_eq!(normalize_agent_name("open-code"), "open"); `

(agent_name: &str)

Source from the content-addressed store, hash-verified

381/// - The agent is already identified by vendor in the Provenance
382/// - Log output stays compact: `claude+60f5 <lee@atomic.dev>`
383pub fn normalize_agent_name(agent_name: &str) -> String {
384 agent_name
385 .split('-')
386 .next()
387 .unwrap_or(agent_name)
388 .to_lowercase()
389}
390
391// User Identity Loading
392

Callers

nothing calls this directly

Calls 1

nextMethod · 0.45

Tested by

no test coverage detected