ai-agent-audit-specialist — Claude Code subagent: setup and usage
Designs tamper-evident audit trails and compliance mappings for AI coding tools under HIPAA, SOC 2, and EU AI Act rules.
npx claude-code-templates@latest --agent security/ai-agent-audit-specialistWhat ai-agent-audit-specialist does
This subagent translates compliance mandates into forensic logging architectures for AI assistants like Claude Code, Cursor, Codex CLI, and Aider. It organizes event capture around agent lifecycles (UserPromptSubmit, PreToolUse, PostToolUse, session boundaries) and connects them to regulatory requirements such as HIPAA §164.312(b), SOC 2 CC7.2, and EU AI Act Annex IV.
It operates using Read, Grep, Glob, and Bash tools. The resulting design specifies append-only JSONL files, SHA-256 hash chaining, system-level immutability via chattr +a or chflags uappnd, SIEM pipelines (Splunk HEC, Elastic), and re-verification checks for audit teams.
Log files function as legal evidence: any log rotation that severs the hash sequence or any silent hook disabling in settings.json invalidates the entire verification chain.
What it helps with
- design tamper-evident audit pipelines for AI coding agents
- map agent hook events directly to SOC 2 and HIPAA controls
- draft logging architecture documentation for EU AI Act Annex IV
- generate scripts for auditors to verify cryptographic hash chains
Example prompts for the agent
- Design an audit architecture capturing Claude Code tool runs and diffs for HIPAA compliance
- Build a SOC 2 CC7.2 evidence plan with continuous monitoring for coding agents
- Draft an EU AI Act Annex IV logging description covering event taxonomy and retention
How to install ai-agent-audit-specialist
1claude-code-templates
npx claude-code-templates@latest --agent security/ai-agent-audit-specialist2Manually: put the files in place
.claude/agents/ai-agent-audit-specialist.mdFor all projects use ~/.claude/agents/. Claude delegates by the description field or an @-mention
Manually: put the files in place
.codex/agents/ai-agent-audit-specialist.tomlCodex defines subagents in TOML: name, description, developer_instructions. Move the Markdown text into developer_instructions by hand. For all projects use ~/.codex/agents/
Manually: put the files in place
.cursor/agents/ai-agent-audit-specialist.mdCursor also reads .claude/agents/
Step by step, with commands for each platform: Claude Code subagents: how to create one, call it and keep context clean
Questions about ai-agent-audit-specialist
How to install ai-agent-audit-specialist in Claude Code?
Run npx claude-code-templates@latest --agent security/ai-agent-audit-specialist. It places the template at .claude/agents/ai-agent-audit-specialist.md.
What does ai-agent-audit-specialist do?
It drafts audit architectures, hook capture specifications, and integrity-check scripts for AI coding agents in regulated enterprises.
Which tamper-evidence mechanisms does it specify?
It designs systems around SHA-256 line chaining, OS-level append-only flags (chattr +a, chflags uappnd), detached ed25519 signatures, and SIEM streaming.