Invariant Guardrails
App : A product you use directly
Security rules applied in real time to agent tool calls.
The runtime complement to mcp-scan for blocking rather than just detecting.
Security reflects where data goes, requested permissions and incidents on record at the verification date. It is not a guarantee of zero risk: check the deployment mode and the connections you enable.
What it does, concretely
AI agents that call external tools can be hijacked by malicious instructions injected into the data they process. Invariant Guardrails addresses this by sitting between your application and your MCP servers or LLM provider, analyzing and blocking suspicious tool calls before they execute.
It works through rules written in a Python-inspired syntax. Each rule describes a sequence of behaviors to intercept, for example detecting that an agent reads an inbox and then attempts to send an email to an unknown address. Guardrails evaluates these rules in real time on every LLM and MCP request, both before and after the call.
The tool is aimed at developers building agentic systems who want to add a security layer without modifying their application code. It can be used as a transparent proxy via Gateway, or integrated directly into Python code using the invariant-ai package.
It is not suited to non-technical users looking for a ready-to-use solution without configuration: writing meaningful rules requires understanding your agent's call flows and the specific risks of your context.
What it offers
- ·Real-time interception of MCP tool calls and LLM requests, both before and after execution.
- ·Contextual security rules written in readable Python-inspired syntax, capable of detecting suspicious sequences of calls.
- ·Transparent deployment as an MCP or LLM proxy via Gateway, with no changes to application code.
- ·Direct programmatic use via the invariant-ai Python package to analyze agent traces locally.
- ·Built-in standard library including ready-to-use detectors such as prompt injection detection.
- ·Fully local execution possible, with no data sent to external servers.
In practice
- Price
- Freemium
- Commercial use
- Commercial use: yes
- Available on
- cli, docker
- Licence
- Apache-2.0
Security and data
- Rating
- Security: nothing to flag
- Your data
- Data stays local
- Maintenance
- Inactive for over six months
Links and repository checked on 25 October 2026 · added on 1 September 2024
How to install Invariant Guardrails
pip install invariant-ai