SShortSingh.
Back to feed

Why one developer enforces AI agent limits outside the prompt, not inside it

0
·1 views

A developer argues that AI agents with tool access should be treated like untrusted third-party dependencies and contained accordingly. The key rule is that constraints are set when the process starts, since a prompt is only a request that a model can ignore or be manipulated into bypassing. In their agent, the tool list is fixed in advance, allowing twelve read tools while refusing fifteen write tools, so the agent cannot write files or send messages even if it tries. Additional safeguards include an anti-injection section in the prompt, a mandatory adversarial review of outputs, and human approval before anything is published. The author's reasoning is that an agent does what its environment permits, so impossible actions remove the need to trust it.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

After a Year of Daily Use, Which AI Image Generators Actually Stick

A writer who generates images almost daily spent a year testing and re-subscribing to major AI image tools, concluding there is no single winner. Midjourney is still praised for the most consistently beautiful raw output, but it has no free tier and plans run from about $10 to $120 monthly. GPT Image, inside ChatGPT, is highlighted for multi-turn editing and for following instructions closely, which the author calls the biggest workflow difference. Ideogram is preferred for images containing text, while Stable Diffusion and Flux suit self-hosting, which is free in software but requires capable hardware and a learning curve. Adobe's Firefly and Recraft are noted for commercial licensing safety and genuine vector output, respectively.

0
ProgrammingDEV Community ·

Keeping Terraform Vault Secrets Out of State and Git

Using the vault_kv_secret_v2 data source to pull database passwords into Terraform stores those values in plain-text state, even when variables are marked sensitive. Newer Terraform and Vault provider releases offer ephemeral resources and write-only arguments, which keep secrets available during a run without persisting them in plan or state. The approach requires Terraform 1.10 or 1.11 or later, a KV version 2 secrets engine in Vault, and a non-interactive authentication method such as AppRole or JWT. Users should configure the Vault provider without hard-coded tokens, reading credentials from the environment or auth blocks. Support for write-only arguments varies by provider and resource, so the guide advises checking each provider's documentation before relying on it.

0
ProgrammingDEV Community ·

Developer builds Kyboro, an AI agent that runs plain-English tasks on a user's own PC

A developer has created Kyboro, a desktop tool that carries out tasks described in everyday language, such as opening a browser, editing files, or running terminal commands, while the user watches. The system is split into an Electron desktop app, a local Python executor that performs the actions, and a cloud orchestrator built with FastAPI and Postgres that plans tasks and selects models. The developer reports several engineering problems along the way, including timeouts that silently killed tasks, retry loops that evaded detection, and a confirmation flow that had to be built so risky actions like deleting files wait for user approval. Early versions are available for Windows, Mac, and as a Chrome extension, and the developer is asking for feedback from real-world use.

0
ProgrammingDEV Community ·

PPTX converter fixed to follow true slide order instead of filename order

A developer found that a pitch deck converted to Markdown placed the appendix before the main pitch because the converter read slide files alphabetically. In PPTX files, slide filenames like slide1.xml do not reflect presentation order, which is instead defined in presentation.xml. The fix parses the slide ID list and resolves each relationship ID to its target file, so slides appear in the order the author intended. The developer compares this to similar ordering issues in spreadsheets and EPUB files, where the index rather than the filename determines sequence. The corrected tool is available as part of the author's document tooling online.