Skip to main content
TealDrift detects behavioral drift — when an AI agent’s behavior deviates from its established statistical baseline. It monitors action patterns, tool usage frequency, content characteristics, and MCP tool definitions to identify anomalous behavior that may indicate compromise, misconfiguration, or prompt injection.
TealDrift addresses OWASP ASI-02 (Agentic Behavior Manipulation) — the risk that an agent’s behavior is subtly altered through prompt injection, model updates, or configuration changes without triggering explicit policy violations.

Why This Matters

Compliance alignment: NIST AI RMF (MEASURE 2.7 — AI system monitoring), ISO 42001 (A.9.4 — monitoring and measurement), EU AI Act Article 9 (risk management system).

Core Concepts

Statistical Baselines

TealDrift builds a baseline profile of normal agent behavior over a configurable window. It tracks:
  • Action distribution — What actions the agent performs and how often
  • Tool usage patterns — Which tools are called, in what order, at what frequency
  • Content characteristics — Average content length, vocabulary diversity, sentiment
  • Temporal patterns — When the agent is active, request frequency over time
  • Error rates — Normal failure rate vs. current failure rate

Drift Score

Each evaluation produces a drift score (0.0 - 1.0) indicating how far current behavior deviates from the baseline:

Class


DriftOptions


evaluate()

Evaluate a request against the agent’s behavioral baseline.

DriftResult


min_samples Guard

TealDrift requires a minimum number of observations before activating drift detection. This prevents false positives during the initial learning period.
Set min_samples based on your agent’s activity level. A high-traffic agent (1000+ requests/day) can use min_samples: 500. A low-traffic agent (10 requests/day) might need min_samples: 50 with a longer baselineWindow.

MCP Definition-Drift Monitoring

TealDrift monitors MCP tool definitions for unauthorized changes — new tools added, parameters modified, or tools removed.

DefinitionDriftResult


Baseline Management


Integration with TealEngine