The vendor-neutral protocol for AI agent safety & security — and the neutral benchmark that ranks the vendors.
翻譯準備中
取自儲存庫 README
正在載入完整 README。 以下為已儲存的摘錄。
The vendor-neutral protocol for AI agent safety & security — and the neutral benchmark that ranks the vendors.
Integrate safety & security once, enforce it across every agent and LLM — instead of wiring every vendor to every tool by hand.
This monorepo is the home of the OpenGuardrails (OGR) specification and its
reference integrations. The specification is the normative contract every
integration and detector speaks; the integrations, benchmark, examples, skill,
and website live alongside it so changes can be reviewed and tested together.檢視完整 README ↗AI agent guardrails for every builder.
Let your agents do more, and walk away. Open source, and it runs on your machine.
Apache-2.0 · openguardrails.com
Most of what an agent does is safe, and a rule can tell. OpenGuardrails decides those actions on your machine, with no network and no model. It sends only the ones a rule cannot decide to a model built to judge agent actions, so you stop being asked, and it tells you when something is wrong.
tool call -> local rules --- allow ------------------------------> runs
|-- deny ---------------------------------> refused
`-- cannot tell -> OpenGuardrails model
|-- allow ------------> runs
|-- unsafe -----------> refused, the agent is told why
`-- your decision ----> the agent asks you
Unsafe and "your decision" are different things. A key on its way to an unknown host is a security problem, and it is refused. Nobody is asked to rule on it. Buying this lipstick is safe, and it is still your call.
cli/src/gate/gate.tsopenguardrails run starts an agent where it cannot read your
credentials and every connection is recorded. It also reports hosts the agent reached but no tool
call named.openguardrails decisions lists every decision, and
~/.openguardrails/model-requests.ndjson holds exactly what was sent to the model.Early, and honest about it. Tested end to end against the real harnesses through the local gateway,
with no plugin, using the scripted models in cli/experiments:
| Agent | Rules and model enforced | Agent told why | Secrets kept from the model provider | Tool gets the real value |
|---|---|---|---|---|
| Hermes 0.20 | yes | yes | yes | yes |
| OpenClaw 2026.6 | yes | yes | yes | yes |
| DeepSeek Harness 0.2 | yes | yes | yes | yes |
Not available yet:
Known limits are listed in cli/README.md.
Needs Node 22.12 or newer.
git clone https://github.com/openguardrails/openguardrails
cd openguardrails/cli && npm install && npm run build && npm link
Tell it about your model API in ~/.openguardrails/config.json, mode 0600:
{
"gateway": {
"upstreams": { "main": { "baseURL": "https://openrouter.ai/api/v1", "model": "qwen/qwen3.8-27b", "apiKeyEnv": "OPENROUTER_API_KEY" } },
"routes": { "auto": ["main"] }
}
}
openguardrails serve # port 4180; set gateway.port in the config to change it
Then point your agent at http://127.0.0.1:4180/v1, with model auto and any string as its API key.
That is the whole integration, and it works the same for every agent.
openguardrails connect turns on the model once it is public, and shows where to raise your quota.
openguardrails decisions shows what happened. For an enterprise deployment, the gateway connects to
OpenGuardrails AIRS instead, with no other change.
| Path | What it is |
|---|---|
cli/ | The openguardrails command: rules, local service, sandbox, firewall, gateway |
integrations/ | The Higress plugin, which connects a Higress gateway to OpenGuardrails AIRS |
benchmarks/ | The public evaluation. We enter too, and publish the results either way |
OpenGuardrails AIRS is the enterprise product: organization-wide policy, audit, SSO, analytics and private deployment. It uses the same models. See openguardrails.com.
Apache-2.0.