본문으로 건너뛰기
cccskills
무료GitHub에 공개

action-validator

Pre-action boundary checking — validates agent tool calls against declared capabilities and task contracts

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(1)

  • SKILL.md5.5 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Action Validator Skill

Purpose

Advisory pre-action validation layer that checks agent tool calls against declared capabilities, file access scope (R002), and task contracts before execution. Inspired by AutoHarness (Google DeepMind) — enforcing action-space legality at agent boundaries.

This skill does NOT block actions (R021 advisory-first model). It emits warnings when agents attempt operations outside their declared scope.

Validation Checks

CheckWhatAgainst
Tool scopeTool being calledAgent's tools frontmatter list
File scopeFile path in Write/EditR002 file access rules
Domain scopeTarget file extensionAgent's domain frontmatter
Task contractOperation typeTask description constraints

Advisory Format

--- [Action Validator] Scope warning ---
  Agent: {agent-name}
  Tool: {tool-name}
  Target: {file-path}
  Issue: {description}
  Declared scope: {agent's declared tools/domain}
  💡 Suggestion: {recommended action}
---

Integration Points

SystemHow
PreToolUse hooksOptional hook to check tool calls (advisory only)
pipeline-guardsComplements pipeline stage gates
adversarial-reviewProvides action-space-legality criterion
R002 (Permissions)Validates against declared file access rules
R010 (Orchestrator)Orchestrator validates subagent scope claims

Policy Cache Pattern

For high-repetition agents (e.g., mgr-gitnerd commit workflows), capture validated decision paths as reusable policies:

policy_cache:
  agent: mgr-gitnerd
  action: git-commit
  validated_steps:
    - tool: Bash
      pattern: "git add *"
      verdict: allow
      hints: { safety: normal, parallel: false, approval: auto }
    - tool: Bash
      pattern: "git commit *"
      verdict: allow
      hints: { safety: normal, parallel: false, approval: auto }
    - tool: Bash
      pattern: "git push *"
      verdict: warn_confirm
      hints: { safety: low, parallel: false, approval: needs_approval }

Policy caching reduces redundant LLM calls for well-understood workflows. Policies are advisory — the orchestrator may override.

Capability Hints (Opus 4.7+)

When agents target Opus 4.7 (opus47 model alias), tool capability hints improve batched tool-call planning. Declare per-tool metadata in policy cache entries:

FieldValuesEffect
safetynormal, lowlow triggers confirmation advisory
paralleltrue, falsetrue allows concurrent scheduling
approvalauto, needs_approvalMaps to R002 permission tier

Example: Enhanced Policy Cache with Capability Hints

policy_cache:
  agent: mgr-gitnerd
  action: git-commit
  validated_steps:
    - tool: Bash
      pattern: "git add *"
      verdict: allow
      hints: { safety: normal, parallel: false, approval: auto }
    - tool: Bash
      pattern: "git push *"
      verdict: warn_confirm
      hints: { safety: low, parallel: false, approval: needs_approval }
    - tool: Read
      pattern: "*"
      verdict: allow
      hints: { safety: normal, parallel: true, approval: auto }

Hints are advisory — they inform model scheduling but do not enforce. Inspired by ouroboros PR #353 capability graph pattern.

Code Harness Integration (AutoHarness)

When a synthesized harness exists for an agent (.claude/outputs/harnesses/{agent-name}-*.yaml), action-validator can use it for enhanced validation:

Tool: Writing artifacts under .claude/outputs/

CC sensitive-path check inspects tool target paths and triggers permission prompts on .claude/ regardless of bypassPermissions and allow rules (refs: #960, #961, #978, #981, #1016).

To write action-validator results under .claude/outputs/sessions/:

  1. Write the artifact body to /tmp/action-validator-$(date +%H%M%S).md first (Write tool target = /tmp, no sensitive-path trigger)
  2. Use a /tmp/*.sh Bash script to move/copy the file under .claude/outputs/sessions/$(date +%Y-%m-%d)/ (Bash target = /tmp, script-internal cp to .claude/ is not audited)
  3. Read-only Bash on .claude/outputs/ (e.g., cat, head, wc) is allowed for verification

Reference: feedback_sensitive_path_tmp_bypass.md, R006 sensitive-path handling, #1016, #1045.

ModeSourceBehavior
Advisory (default)Prompt-based checksEmit warnings only
Code-verifiedharness-synthesizer outputRun harness validation code, emit advisory results
Hard-enforce (opt-in)harness-synthesizer --hard-enforceBlock invalid actions (requires explicit opt-in, see R021)

To generate a harness for an agent: /harness-synthesizer --agent {name} --mode verifier

Code harness validation is additive — it supplements prompt-based checks, not replaces them.

Scope

This skill is an advisory layer, not a hard enforcement mechanism:

  • Does: Emit warnings, log scope violations, suggest corrections
  • Does NOT: Block tool execution, modify agent behavior, override R021
  • Future: May integrate with PreToolUse hooks for automated checking (see R021 promotion criteria)

Related Guide

  • guides/harness-engineering/ — 하네스 엔지니어링 통합 가이드 (Behavior Control Layer 관점에서 action-validator 위치)

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Auto-detect project context and optimize harness — deactivate unused agents/skills, suggest missing experts, generate project profile

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

baekenough/second-brain152026년 10월 8일 업데이트

Adversarial code review using attacker mindset — trust boundary, attack surface, business logic, and defense evaluation

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

baekenough/second-brain152026년 10월 8일 업데이트

Apache Airflow best practices for DAG authoring, testing, and production deployment

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

baekenough/second-brain152026년 10월 8일 업데이트

Alembic migration patterns for naming conventions, safety checks, expand-contract, env.py configuration, and CI integration

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

baekenough/second-brain152026년 10월 8일 업데이트

Pre-routing ambiguity analysis — scores request clarity and asks clarifying questions when needed (inspired by ouroboros)

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

baekenough/second-brain152026년 10월 8일 업데이트

AWS patterns from Well-Architected Framework

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

baekenough/second-brain152026년 10월 8일 업데이트

baekenough의 스킬 모두 보기

이 스킬의 문제 신고