**agent-drift** logo

**agent-drift**

Free

![](https://img.shields.io/github/stars/jhammant/agent-drift?style=flat-square)

FreeFree tier
Type
Open Source

About **agent-drift**

agent-drift is an open-source CLI tool that stress-tests AI agents for goal drift and system prompt violations. Inspired by the ICLR 2026 Workshop paper 'Asymmetric Goal Drift in Coding Agents Under Value Conflict,' it allows developers to probe their agents with custom system prompts and evaluate how well they adhere to constraints, especially when faced with conflicting values. The tool supports multiple LLM providers including Anthropic, OpenAI, Groq, and local models via Ollama. It generates interactive HTML reports with radar charts, drift timelines, and violation examples, making it easy to identify exactly where your AI agents break.

Key Features

Detects goal drift and system prompt violations in AI agents
Supports multiple LLM providers: Anthropic, OpenAI, Groq, Ollama (local models)
Generates interactive HTML reports with radar charts, drift timelines, and violation examples
Customizable system prompts via CLI or file
Easy-to-use CLI command `drift probe`
Open source and free to use

Pros & Cons

Pros
  • Free and open source
  • Simple CLI interface with quick setup
  • Supports both cloud and local LLM providers
  • Provides detailed visual reports for analysis
  • Inspired by academic research on goal drift
Cons
  • Requires Python 3.10+
  • Requires API keys for cloud models (Anthropic, OpenAI, Groq)
  • Limited to specific testing scenario (goal drift and prompt violations)
  • No graphical user interface; command-line only

Best For

Testing AI agent adherence to safety rules and ethical constraintsEvaluating system prompt robustness against value conflictsBenchmarking model behavior under conflicting instructionsIdentifying failure modes in coding agents before deployment

FAQ

What models are supported?
agent-drift supports Anthropic (Claude), OpenAI (GPT), Groq, and local models via Ollama. The recommended judge model is Claude, which requires an Anthropic API key.
How do I install agent-drift?
Clone the repository and run 'pip install -e .' to get the 'drift' CLI command. Requires Python 3.10+.
Do I need an API key?
Yes, for testing cloud models you need the corresponding API key (Anthropic, OpenAI, or Groq). For local models via Ollama, no key is needed.
What kind of output does it produce?
It generates an interactive HTML report with radar charts, drift timelines, and violation examples, showing where the agent deviated from the system prompt.