Skip to main content

Module mode

Module mode 

Source
Expand description

How a developer’s agent sessions reach AI Tracing: the developer’s choice, bounded by the workspace’s AI traffic policy.

Structs§

ResolvedMode
The mode of a session and how it came about.

Enums§

ModeReason
Why a session runs in the mode it does.
TracingMode
The capture path of a session. Exactly one is meant to be active.
TrafficPolicy
The workspace’s AI traffic policy, set by an admin in Control Plane (ai_traffic_policy of GET /api/v1/workspace/settings).

Constants§

GATEWAY_SESSION_ENV
Set to 1 on an agent started through the AI Gateway, and on nothing else: what tells the capture hooks to record nothing.
MODE_ENV
The environment variable that names the mode. visdom reads it as a choice and sets it on the agent it launches, where the capture hooks read it: under gateway they record nothing, the gateway does.

Functions§

configured_mode
The mode somebody chose: --mode, then VISDOM_TRACING_MODE, then the repository config, then the user config. None when nobody did.
effective_mode
The mode a session runs in. An admin may enforce one (enforced: gateway, direct: hooks); under per_agent, or when the policy is not known, the developer’s choice stands, and hooks when they made none.
parse_mode
Parse a mode as the command line and the config files spell it.