Human Approval Gate for AI Agents

    1

    Teaches your agent to pause for human review on risky or low-confidence output, using rule-based confidence instead of the model's own guess.

    Free

    Security scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    Human Approval Gate for AI Agents

    Example session with this skill installed

    Add a human-approval gate to my LangGraph agent that recommends fixes for failing equipment. It should pause for a supervisor when confidence is low or severity is high, and a supervisor must not be able to approve their own request.

    • Read your context and instructions
    • Compiled the human approval gate

    Summary

    Added an approval gate after the diagnosis step. The agent now pauses when confidence is below 0.75, severity is high or critical, or a safety filter blocked part of the answer. Confidence is computed from evidence, not from the model's own number.

    RuleWhat it does
    Evidence firstAt least one tool call is required before a diagnosis is accepted
    Rule-based confidenceBase 0.5, bonuses for documents and data actually retrieved, penalty for tool errors, clamped to 0.05-0.95
    Citation checkClaims citing a source that was not retrieved in this run are dropped and counted
    Approval triggerconfidence < 0.75, or severity in (high, critical), or a blocked unsafe action
    No self-approvalReviewer id must differ from the requester id
    def needs_human(conf: float, severity: str, threshold: float = 0.75) -> bool:
        return conf < threshold or severity in ("high", "critical")
    
    decision = interrupt({"summary": result["summary"], "severity": result["severity"], "confidence": result["confidence"]})
    

    Next steps

    • Add a UNIQUE constraint on the decision table so two simultaneous decisions cannot both succeed
    • Write the five tests from the checklist: low confidence pauses, high severity pauses, fake citation dropped, self-approval rejected, double decision rejected
    • Tune the confidence weights on your own labelled cases; they are starting values

    Connects securely to your tools. The creator never sees your data.

    About this skill

    When an AI agent's output can affect real work, "the model said it is 90% sure" is not good enough. This skill walks your agent through building a human-approval gate that you can inspect and test.

    What it covers

    • Gathering evidence with tools before the agent is allowed to answer
    • Computing confidence from rules (what evidence was actually retrieved), not from the model's self-report
    • Dropping any citation the agent did not really retrieve
    • Requiring human review when confidence is low, severity is high, or a safety filter fired
    • Pausing and resuming with LangGraph interrupt() and a checkpointer, with a worked example
    • Storing the reviewer's decision safely: no self-approval, one decision per result, audit log, per-tenant scoping
    • A checklist and a list of tests to write

    Extracted from a maintenance-diagnosis project where this pattern is implemented and tested (MIT licensed, public on GitHub: https://github.com/nithya-prakash/IndustrialAICopilot).

    Honest limits

    The confidence weights are starting values you should tune on your own labelled cases. Rule-based confidence is auditable, not proven accurate, and a gate does not replace a reviewer who actually reads the result.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Agents & Orchestration.

    Confidence weights are judgment-based and require manual tuning for specific domains. Requires an orchestrator that supports state interrupts and checkpointers like LangGraph.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free to use

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 15 days ago

    • Free with an Agensi account

    Nothing to install. It runs in your AI agent.

    Optional
    Python 3.10+LangGraph

    Python and the langgraph package are only for the worked example.

    Permissions

    Read Files
    Write Files
    Listed15 days ago

    What's inside

    Frequently Asked Questions

    A "be honest" prompt relies on the model judging itself. This skill describes rule-based checks that sit outside the model: confidence computed from the evidence actually retrieved, citations checked against what was retrieved, and a pause for a human reviewer under defined conditions. It is guidance and example code for you to implement, not a runtime that enforces anything by itself.

    The worked example uses LangGraph (interrupt, checkpointer, Command resume) and has only been written against LangGraph. The rules themselves are plain logic you can port to another framework, and the skill can be read by any agent that supports SKILL.md files.

    A SKILL.md describing the five-part pattern with a checklist, plus one reference file with example Python for the confidence rules, citation check, a LangGraph approval node, and decision storage. There are no scripts or services, and the skill is free.

    Yes, the confidence scoring uses named constants for bonuses and penalties, allowing you to fine-tune the sensitivity thresholds to match your specific industry risk profile.

    It checks each citation against the set of source IDs retrieved in that run and drops or flags any that are not in it. That catches invented references. It does not catch a wrong claim that cites a real source.

    The reference file shows a LangGraph node that calls interrupt() when review is needed, with a checkpointer saving state, and resumes with Command(resume=...) once a reviewer decides. Use a database-backed checkpointer in production rather than the in-memory one.

    New in Agents & Orchestration

    Free