Files
openclaw/docs/hooks/soul-evil.md
Seb Slight 929a3725d3 docs: canonicalize docs paths and align zh navigation (#11428)
* docs(navigation): canonicalize paths and align zh nav

* chore(docs): remove stray .DS_Store

* docs(scripts): add non-mint docs link audit

* docs(nav): fix zh source paths and preserve legacy redirects (#11428) (thanks @sebslight)

* chore(docs): satisfy lint for docs link audit script (#11428) (thanks @sebslight)
2026-02-07 15:40:35 -05:00

1.7 KiB
Raw Permalink Blame History

summary, read_when, title
summary read_when title
SOUL Evil hook (swap SOUL.md with SOUL_EVIL.md)
You want to enable or tune the SOUL Evil hook
You want a purge window or random-chance persona swap
SOUL Evil Hook

SOUL Evil Hook

The SOUL Evil hook swaps the injected SOUL.md content with SOUL_EVIL.md during a purge window or by random chance. It does not modify files on disk.

How It Works

When agent:bootstrap runs, the hook can replace the SOUL.md content in memory before the system prompt is assembled. If SOUL_EVIL.md is missing or empty, OpenClaw logs a warning and keeps the normal SOUL.md.

Sub-agent runs do not include SOUL.md in their bootstrap files, so this hook has no effect on sub-agents.

Enable

openclaw hooks enable soul-evil

Then set the config:

{
  "hooks": {
    "internal": {
      "enabled": true,
      "entries": {
        "soul-evil": {
          "enabled": true,
          "file": "SOUL_EVIL.md",
          "chance": 0.1,
          "purge": { "at": "21:00", "duration": "15m" }
        }
      }
    }
  }
}

Create SOUL_EVIL.md in the agent workspace root (next to SOUL.md).

Options

  • file (string): alternate SOUL filename (default: SOUL_EVIL.md)
  • chance (number 01): random chance per run to use SOUL_EVIL.md
  • purge.at (HH:mm): daily purge start (24-hour clock)
  • purge.duration (duration): window length (e.g. 30s, 10m, 1h)

Precedence: purge window wins over chance.

Timezone: uses agents.defaults.userTimezone when set; otherwise host timezone.

Notes

  • No files are written or modified on disk.
  • If SOUL.md is not in the bootstrap list, the hook does nothing.

See Also