dym-harness-sdk-interventions

dym-harness-sdk-interventions is a skill for Claude Code from Rheinmir/setup. It costs 62 tokens per session (719 once invoked), scanned A, original, MIT.

A guide for adding decision checks around tool calls made by a Strands agent. The checks can ask a person, classify risk, or apply Cedar authorization policies.

In plain words
What is it for?
Use it to add human approval, risk-based approval, custom handlers, or Cedar policy files to an agent's tool calls.
Why use it?
It helps prevent risky tool actions from running automatically and provides defined outcomes such as allowing, denying, changing, or interrupting a call.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter. Also seen: mentions subagents.

Good fit Use it to add human approval, risk-based approval, custom handlers, or Cedar policy files to an agent's tool calls.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/rheinmir/setup/dym-harness-sdk-interventions
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Rheinmir/setup --skill dym-harness-sdk-interventions
Clone the repo
git clone --depth 1 https://github.com/Rheinmir/setup

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for dym-harness-sdk-interventions

README.md
[![agentmods](https://agentmods.dev/badge/skills/rheinmir/setup/dym-harness-sdk-interventions/github.svg)](https://agentmods.dev/skills/rheinmir/setup/dym-harness-sdk-interventions)
Your own site
<a href="https://agentmods.dev/skills/rheinmir/setup/dym-harness-sdk-interventions"><img src="https://agentmods.dev/badge/skills/rheinmir/setup/dym-harness-sdk-interventions/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for dym-harness-sdk-interventions

Your own site · 80×15
<a href="https://agentmods.dev/skills/rheinmir/setup/dym-harness-sdk-interventions"><img src="https://agentmods.dev/badge/skills/rheinmir/setup/dym-harness-sdk-interventions.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 62 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 719 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00062 $0.00719
Opus 5.5 $0.00025 $0.00288
Sonnet 5.5 $0.00012 $0.00144
Haiku 4.5 $0.00006 $0.00072

Measured yesterday against content hash 53af11d9a9f6, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

dym-harness-sdk-interventions scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.overstack/doyourmagic/harness-sdk/skills/dym-harness-sdk-interventions/SKILL.md · 41 lines

How it starts

The opening of the file, as written. The whole thing — 41 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Skill: dym-harness-sdk-interventions — chốt chặn tool call

When to use

  • Cần agent hỏi người trước khi chạy tool nguy hiểm, hoặc tự phân loại rủi ro, hoặc tuân policy Cedar.
  • Khác hook chặn thường: handler trả về QUYẾT ĐỊNH có kiểu (Proceed · Deny · Guide · Interrupt · Transform), registry gộp theo ưu tiên Deny > Interrupt > Transform > Guide > Proceed; Deny cắt ngắn chuỗi, Guide cộng dồn phản hồi, có audit log chung (design team/designs/0007-intervention-primitive.md).

Steps

  1. Grammar chuỗi là TẤT ĐỊNH, không đoán nội dung (harness-py/src/strands_harness/interventions.py):
    giá trị thành
    "off" / None không có handler
    "ask" HumanInTheLoop(ask=...) — hỏi người mỗi call
    "smart" HumanInTheLoop(classifier=True) — LLM phân loại rủi ro, chỉ hỏi call bị cờ
    chuỗi kết thúc .cedar CedarAuthorization(policies=<file>) — cần pip install 'strands-agents[cedar]'
    chuỗi khác chính sách chữ → prompt của bộ phân loại rủi ro
    instance InterventionHandler đi thẳng, không đổi
  2. Ghép nhiều lớp khác loại:
    create_harness(interventions=["policies/tools.cedar", "smart"])
    
  3. Kiểm hành vi lỗi (đo 2026-09-28, rc 0):
    create_harness(session=False, memory=False, interventions=["ask", "ask"])
    # ValueError: Two interventions share the handler name 'strands:human-in-the-loop' ...
    create_harness(session=False, memory=False, interventions=123)
    # ValueError: Invalid interventions value 123; expected a preset name, ...
    

Rules

  • Hai handler CÙNG loại → raise (SDK chỉ giữ một handler mỗi name); ghép KHÁC loại (Cedar + một preset người duyệt) thì được.
  • Policy Cedar viết inline KHÔNG được tự nhận diện (trông như văn xuôi) → truyền CedarAuthorization(policies=...) trực tiếp.
  • Subagent con kế thừa interventions của cha; lời gọi tool bên trong programmatic_tool_caller vẫn đi qua interventions — không lách được bằng cách gọi gián tiếp.
  • Xếp handler rẻ trước (Cedar → dịch vụ → LLM) vì Deny cắt ngắn chuỗi.
  • "ask" với ask=None dùng stdio — chạy headless/CI sẽ kẹt chờ input; truyền callback hoặc dùng interrupt/resume.

Read the full file on GitHub · 41 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 41 lines · 62 tokens per session scan A 53af11d9a9f6

Subscribe to this mod's changes

dym-harness-sdk-interventions is a skill published in the GitHub repository Rheinmir/setup (11 stars, last pushed 20d ago), licensed MIT. It adds 62 tokens to every session and 719 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-07.

Related

dym-harness-sdk-interventions compared with skills from other repositories

dym-harness-sdk-interventions next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
dym-harness-sdk-interventionsRheinmir/setupSkill1120d agoMITA62Claude Code
imagegenopenai/codexSkill134ktodayApache-2.0A113Codex
local-ai-agentsmicrosoft/ai-agents-for-beginnersSkill79kyesterdayMITA200Claude Code, Codex
playwright-climicrosoft/playwrightSkill100kyesterdayApache-2.0A19Claude Code
browser-automationopenclaw/openclawSkill394ktodayMITA36Claude Code
systematic-debuggingobra/superpowersSkill314k4d agoMITA21Claude Code
next-cache-components-adoptionvercel/next.jsSkill143ktodayMITA95Claude Code