Skip to main content

Crate ai_env

Crate ai_env 

Source

Structs§

AiEnvironment

Enums§

AiAgent
List of detectable AI coding agents.
AiNetworkPolicy
Network/egress policy imposed on the process, as reported by the environment.

Functions§

detect_agent
Detects the AI agent running the process. Returns Unknown when no known agent is matched.
detect_network_policy
Detects the network/egress policy imposed on the process, from environment variables only (no network I/O is performed). Pass the agent governing the process, typically from detect_agent.
get_environment
Returns metadata about the current AI agent environment, or None when no agent is detected.
is_ai_agent
Returns true if the process is being run by an AI coding agent.