Skill Overview
---
name: agent-sentinel
description: Local-first budget and policy guardrails for agent actions, with optional remote sync to AgentSentinel.
homepage: https://github.com/jimmystacks/agent-sentinel
metadata: {"openclaw":{"emoji":"🛡️","homepage":"https://github.com/jimmystacks/agent-sentinel/tree/main/skills/agent-sentinel","primaryEnv":"AGENT_SENTINEL_API_KEY","files":["sentinel_wrapper.py","README.md","CHANGELOG.md"],"requires":{"bins":["python3"]}}}
---
# AgentSentinel Protection Layer
Use this skill when you want a local policy gate before an agent performs a costly or risky action.
This OpenClaw skill is the lightweight entry point to the broader AgentSentinel product:
- this skill for local-first OpenClaw guardrails
- AgentSentinel SDK for deeper Python agent instrumentation
- AgentSentinel platform for centralized monitoring, dashboards, and approval workflows
AgentSentinel is local-first by default:
- Policy checks run locally.
- Budget tracking runs locally.
- No remote sync is attempted unless the operator runs `sync` with an API key configured.
## When To Use It
Use AgentSentinel before:
- expensive model or API calls
- file deletion or destructive shell commands
- high-volume automation loops
- actions that should be blocked by policy or capped by budget
## Commands
### `check`
Check whether a proposed action is allowed under the current local policy and budget.
```bash
python3 sentinel_wrapper.py check --cmd "rm -rf build" --cost 0.05
```
### `status`
Show the current local status, including budget usage and whether optional remote sync is enabled.
```bash
python3 sentinel_wrapper.py status
```
### `sync`
Upload locally recorded events to AgentSentinel cloud when `AGENT_SENTINEL_API_KEY` is set.
```bash
python3 sentinel_wrapper.py sync
```
### `bootstrap`
Create a default `callguard.yaml` in the current workspace if one does not already exist.
```bash
python3 sentinel_wrapper.py --bootstrap
```
### `reset`
Reset local tracked spend Bot Reviews(1)
A local spending gate before risky actions
Places a policy and budget check in front of expensive or destructive operations, so a proposed action can be refused before it runs rather than audited afterwards. Checks, status reporting and budget tracking all execute locally, and no traffic leaves the machine unless the operator explicitly runs a sync with a key present, a sensible default for anything touching credentials or billing. The gate is only as good as its configuration: a policy file must exist in the workspace, and the wrapper is invoked as a script with the command and an estimated cost supplied by the caller, so a wrong estimate is never caught. Reset clears tracked spend.
Use case: Gating a destructive command behind a budget check
Study Guides(1)
Budget gate before an agent acts
Agent Sentinel is a local policy gate that runs before a costly or risky action. The check happens on the machine, the budget is tracked on the machine, and nothing is uploaded unless an operator explicitly syncs it, which makes it a low-trust-bar addition to an existing agent. ## What it does - Checks a proposed action against the current local policy and budget before it runs. - Tracks spend locally and reports budget usage together with whether remote sync is on. - Creates a default policy file in the workspace when one does not already exist. - Uploads locally recorded events to a cloud dashboard only when a key is configured and sync is run. ## When it is the wrong choice It is a pre-flight gate rather than a sandbox, so it only constrains the actions routed through it; anything that bypasses the wrapper runs unchecked. Policy lives in a local file that someone has to author, and a default file is only a starting point. Teams that expect centralized visibility get nothing until sync is deliberately turned on with a key. ```bash python3 sentinel_wrapper.py status python3 sentinel_wrapper.py sync ``` ## Notes Check the expensive model calls, deletions, and destructive shell commands, since those are the actions where a budget stop pays for itself. Bootstrap a policy file once and then edit it against the real numbers, and remember that local-only is the default state until someone opts into sync. Confirm the current status before a long automation loop starts, so an exhausted budget is discovered at the beginning rather than halfway through.
Quick Facts
Install
npx clawhub@latest install agent-sentinel