<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Yaniv Shenhav</title>
    <description>The latest articles on DEV Community by Yaniv Shenhav (@yanivshenhav).</description>
    <link>https://dev.to/yanivshenhav</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4134528%2F6a30c123-36a8-4e3e-94f5-3967c9f1071c.png</url>
      <title>DEV Community: Yaniv Shenhav</title>
      <link>https://dev.to/yanivshenhav</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/yanivshenhav"/>
    <language>en</language>
    <item>
      <title>Seven Controls to Put in Place Before an AI Agent Gets Production Access</title>
      <dc:creator>Yaniv Shenhav</dc:creator>
      <pubDate>Sun, 20 Sep 2026 19:26:15 +0000</pubDate>
      <link>https://dev.to/yanivshenhav/seven-controls-to-put-in-place-before-an-ai-agent-gets-production-access-6bp</link>
      <guid>https://dev.to/yanivshenhav/seven-controls-to-put-in-place-before-an-ai-agent-gets-production-access-6bp</guid>
      <description>&lt;p&gt;AI agents cross a line that ordinary chat systems do not: they connect probabilistic decisions to real actions.&lt;/p&gt;

&lt;p&gt;An agent that can read mail, update a record, run a tool, or spend money is part of your production control plane. Prompt quality matters, but prompts are not a security boundary. The controls below should exist before an agent receives production access.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Separate read, recommend, and execute
&lt;/h2&gt;

&lt;p&gt;Do not treat "access" as a single permission.&lt;/p&gt;

&lt;p&gt;Use three distinct stages:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Read&lt;/strong&gt; - retrieve the minimum data needed for the task.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Recommend&lt;/strong&gt; - prepare a proposed action without changing external state.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Execute&lt;/strong&gt; - make the approved change through a narrowly scoped tool.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;This split gives you useful checkpoints. A support agent may read a ticket and draft an answer automatically, while sending remains gated. A finance agent may analyze invoices but require an approval before changing payment details.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Give every tool its own narrow permission
&lt;/h2&gt;

&lt;p&gt;A single broad credential turns every mistake into a high-impact mistake. Prefer separate credentials and scopes for separate tools.&lt;/p&gt;

&lt;p&gt;Ask four questions for each tool:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Which resources can it access?&lt;/li&gt;
&lt;li&gt;Which operations can it perform?&lt;/li&gt;
&lt;li&gt;How long does the permission last?&lt;/li&gt;
&lt;li&gt;Which environment does it apply to?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Short-lived credentials and environment-specific roles reduce the damage from a bad decision, a leaked token, or a malicious instruction hidden in external content.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Add an action budget
&lt;/h2&gt;

&lt;p&gt;Agents need more than an API rate limit. They need a business-action budget.&lt;/p&gt;

&lt;p&gt;Useful limits include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;maximum records changed per run;&lt;/li&gt;
&lt;li&gt;maximum messages sent per hour;&lt;/li&gt;
&lt;li&gt;maximum cost per transaction and per day;&lt;/li&gt;
&lt;li&gt;maximum number of retries;&lt;/li&gt;
&lt;li&gt;maximum number of external systems touched in one workflow.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The budget should fail closed. Crossing it should stop the run and request review, not trigger an improvised workaround.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Put approval at the point of commitment
&lt;/h2&gt;

&lt;p&gt;Approval works only when the reviewer can see the exact action that will occur.&lt;/p&gt;

&lt;p&gt;For a message, show the final recipient and wording together. For a deployment, show the target environment and revision. For a purchase, show the item, delivery address, and full total.&lt;/p&gt;

&lt;p&gt;Avoid vague approvals such as "continue" when several actions are still possible. The approval object should be concrete enough to log and later audit.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Treat external content as untrusted input
&lt;/h2&gt;

&lt;p&gt;Email, webpages, documents, issue comments, and retrieved knowledge can all contain instructions that conflict with the agent's actual task.&lt;/p&gt;

&lt;p&gt;Do not let retrieved content redefine the agent's goals, choose new tools, expand permissions, or select a new disclosure destination. Parse it as data. Keep authority in a separate, trusted control path.&lt;/p&gt;

&lt;p&gt;Test whole workflows rather than individual prompts. A sequence of individually allowed actions can still produce a harmful result.&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Log decisions and effects separately
&lt;/h2&gt;

&lt;p&gt;A useful audit trail answers two different questions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Why did the agent decide to act?&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;What changed in the external system?&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Record the task identifier, tool, target, approval reference, before/after state, and provider response. Keep logs outside the agent's own write permissions when possible.&lt;/p&gt;

&lt;p&gt;Observability should also include alerts for unusual tool combinations, repeated failures, sudden increases in volume, and actions outside normal hours.&lt;/p&gt;

&lt;h2&gt;
  
  
  7. Build a real stop mechanism
&lt;/h2&gt;

&lt;p&gt;A stop button is not a prompt that says "please stop." It is an independent control that can revoke credentials, disable tool execution, or block the workflow runner.&lt;/p&gt;

&lt;p&gt;Define who can activate it, what it disables, and how recovery works. Practice using it before launch.&lt;/p&gt;

&lt;h2&gt;
  
  
  A small pre-production failure drill
&lt;/h2&gt;

&lt;p&gt;Before giving an agent live access, run at least these tests:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;A document contains an instruction that conflicts with the assigned task.&lt;/li&gt;
&lt;li&gt;The agent is given the wrong recipient or resource identifier.&lt;/li&gt;
&lt;li&gt;A required external service fails halfway through the workflow.&lt;/li&gt;
&lt;li&gt;The same event is delivered twice.&lt;/li&gt;
&lt;li&gt;An approval expires before execution.&lt;/li&gt;
&lt;li&gt;The agent tries to exceed its action budget.&lt;/li&gt;
&lt;li&gt;The stop mechanism is activated during a run.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The goal is not to prove that the agent never fails. It is to prove that failures are bounded, visible, and recoverable.&lt;/p&gt;

&lt;h2&gt;
  
  
  The minimum launch checklist
&lt;/h2&gt;

&lt;p&gt;Before production access, confirm that you have:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a tool allowlist;&lt;/li&gt;
&lt;li&gt;least-privilege, short-lived credentials;&lt;/li&gt;
&lt;li&gt;separate read and write paths;&lt;/li&gt;
&lt;li&gt;explicit approval for high-impact actions;&lt;/li&gt;
&lt;li&gt;action and cost limits;&lt;/li&gt;
&lt;li&gt;idempotency protection;&lt;/li&gt;
&lt;li&gt;tamper-resistant logs;&lt;/li&gt;
&lt;li&gt;monitoring and alerts;&lt;/li&gt;
&lt;li&gt;a credential-level stop mechanism;&lt;/li&gt;
&lt;li&gt;tested failure and recovery paths.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;An AI agent should earn more authority only after its behavior is observable under real conditions. Start with read-only access, measure what happens, and expand one permission at a time.&lt;/p&gt;




&lt;p&gt;This article is an English technical adaptation of the original Hebrew guide published by AI NEWS Israel: &lt;a href="https://ainewsil.co.il/articles/governing-ai-agents-before-production" rel="noopener noreferrer"&gt;לפני שנותנים לסוכן הרשאה: שבע בקרות שחייבות להגיע לפני הייצור&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>security</category>
      <category>agents</category>
      <category>devops</category>
    </item>
  </channel>
</rss>
