Work safely with AI agents like Claude Code, Cursor, Kiro
# AgentGuard [](https://github.com/krishkumar/agentguard/actions) [](https://www.npmjs.com/package/ai-agentguard) [](https://www.npmjs.com/package/ai-agentguard) [](https://opensource.org/licenses/MIT) [](https://nodejs.org/) **Work safely with agents like Claude Code, Cursor, Kiro CLI.** AI coding agents are powerful, but with great power comes `rm -rf /`. I've been recommending tools like Claude Code and Cursor to junior devs and non-technical folks lately. These agents can execute shell commands autonomously, which is useful. But it also means a single hallucination could wipe their SSH keys, nuke a folder, or brick a meticulously created dev environment. Frontier models do come with guardrails, but I wanted control over project-specific no-nos too - like pushing to master or running that one script that drops the staging database. An LLM deciding whether a command is "safe" is probabilistic. I wanted something classical: a system where I define exactly what's allowed and what's blocked, with no ambiguity. Inspired by `.gitignore`: simple pattern matching, one rule per line, easy for anyone to read and modify. > Built with [Kiro](https://kiro.dev) for the Kiroween Hackathon 2025 ## Highlights - Deterministic rules, not probabilistic LLM guardrails - `.gitignore`-style syntax anyone can read - Recursive command unwrapping (catches `sudo bash -c "rm -rf /"`) - Catastrophic path detection (blocks `rm -rf /`, `rm -rf ~`, etc.) - Zero latency - all validation is local ### Supported Agents | Agent | Status | Install Command | |-------|--------|-----------------| | Claude Code | ✅ Supported | `agentguard install cursor` | | Cursor | ✅
Agent that generates comprehensive documentation, API references, architecture diagrams, and developer onboarding guides from existing code.
Agent configuration for systematic bug investigation that traces issues from error logs through the codebase to root cause with suggested fixes.
Agent for integrating third-party APIs including SDK setup, type generation, error handling, retry logic, and rate limit management.
Cursor's built-in autonomous coding agent that can make multi-file edits, run terminal commands, search the codebase, and iteratively build features with minimal human intervention.
Cloud-based autonomous coding agent that runs in the background on remote sandboxed environments, handling complex multi-step tasks while you continue working.
Cursor's multi-file editing agent within Composer mode that can create, edit, and delete files across your entire project in a single conversation.