soul-guardian

Detect and prevent unauthorized drift in agent workspace files using sha256 baselines and tamper-evident audit logs.

Updated Feb 23, 2026
One-click install
npx skills add https://github.com/pohlai88/AFENDA-NEXUS --skill soul-guardian-pohlai88
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: soul-guardian
Source: https://github.com/pohlai88/AFENDA-NEXUS/tree/main/.agents/skills/soul-guardian
Command: npx skills add https://github.com/pohlai88/AFENDA-NEXUS --skill soul-guardian-pohlai88

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Drift in agent workspace files can go unnoticed, leading to corrupted prompts and degraded performance. Soul Guardian provides drift detection, restored baselines, and tamper-evident auditing to protect core files.

Core Features & Use Cases

  • Per-file policy with restore/alert modes and memory exclude patterns.
  • Baseline snapshots and sha256 integrity checks with automatic restoration for critical files.
  • Tamper-evident audit log with hash chaining, patch generation, and quarantine for unauthorized changes.

Quick Start

Initialize baselines with init, then run check to detect drift and automatically restore for restore-mode files or alert for others.

Frequently Asked Questions about soul-guardian

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I detect unauthorized drift in agent workspace files like SOUL.md and MEMORY.md?

You detect unauthorized drift in agent workspace files by enforcing sha256-based baselines and running a check command that compares current file states against saved snapshots to identify any modifications.

How does tamper-evident audit logging work for workspace file integrity?

Tamper-evident audit logging works by using hash chaining to sequentially link audit records, ensuring any unauthorized modification or deletion of past log entries is immediately detectable during verification.

Can I automatically restore baseline files when unauthorized changes are detected?

Yes, you can automatically restore baseline files by assigning a restore-mode policy, which triggers atomic writes to revert the file to its sha256 baseline snapshot upon detecting drift.

What is the best way to manage per-file security policies for markdown files in an agent workspace?

The best way to manage per-file security policies for markdown files is to configure individual rules specifying either restore or alert modes, allowing distinct enforcement actions for different workspace files.

Do I need a state directory to track file baselines and audit logs?

Yes, you need a dedicated state directory to store sha256 baseline snapshots, patch generation data, and the hash-chained audit log records required for tracking file integrity and drift.

Why does the drift detection tool alert instead of restoring for some memory files?

The drift detection tool alerts instead of restoring because those specific files are assigned an alert-mode policy or match memory exclude patterns, intentionally preventing automatic overwrites of unauthorized changes.