Show HN: Build Rules for Claude Code, Cursor, and Codex

carlosjimenez11 pts0 comments

Hi HN, Fernando and I built Kastra. Kastra intercepts AI agent tool calls and evaluates them against deterministic policies before they execute. We built this product to control pre- and post-inference workloads. This is aimed at developers using coding agents like Claude Code, Codex, Cursor, and OpenClaw.Kastra pushes an allow, hold, and deny decision before the action runs. You can build these policies in plain English from the web app. The interception engine evaluates the tools, targets, and parameters of every action at sub 1ms at a scale of billions of interceptions per day. We also shipped many policy packs covering common high-risk scenarios, and every decision is recorded in an immutable audit trail. The desktop app, CLI, dashboard, and Recon scan are free to use for developers.If you often use Claude, Codex, Openclaw, and Cursor, Kastra can also run a scan command on which risky actions your agents have already taken and automatically build rules to avoid them from happening again. Recon is a feature of Kastra that scans your local agent history. In order to run this scan, execute the commands below in your coding agent.brew install kastra-labs/tap/kastra-edgekastra-edge scanThe scan reads your local agent session history, and it shows all the risky actions your agent has already taken before, the secrets written to tracked files, production databases touched, force pushes, curl-to-shell, and more. This runs on your machine, and secrets never leave. In our own use cases, we kept finding things we d forgotten or didnt know agents had done.Each finding can be converted into a runtime policy, letting you delegate more work to AI without trusting the model itself. Kastra intercepts all workloads at runtime and makes sure these policy evaluations typically complete in under a millisecond. Instead of trusting the model or sandboxing every agent and limiting its capabilities, you trust the deterministic rules that govern its actions.One problem we are still working on is improving the memory and context of the workspace to optimize behaviors and cost reductions for the LLM usage. In order to start building policy packs around LLM cost optimization. Fernando and I will be reviewing the comments. We are super curious what your first scan finds. Please post results below so we can see what the most common patterns are and adjust policy packs for our users based on your feedback.Documentation: https://kastra.ai/docsDownload for MacOS Kastra Edge: https://kastra.ai/edge/download.htmlCheck Kastra in action today: https://www.youtube.com/watch?v=6TUETu5lb3Q feature=youtu.be

kastra agent scan https policy edge

Related Articles