1.8 KiB
1.8 KiB
kuri-skill-gate
A Hermes plugin that blocks gated tool calls and terminal commands until the required safety skill has been read successfully through skill_view(). It keeps high-friction operations aligned with their documented procedures.
How it works
tool_executionmiddleware intercepts every tool call- Gated tools:
patch→ requirespatch-tool-safety;delegate_task→ requiresdelegate-task-best-practices - Gated commands (terminal):
gh→ requiresgh-cli; more patterns addable via_COMMAND_PATTERN_GATES - A skill unlocks a gate only after its main
SKILL.mdread succeeds; failed reads andfile_pathreference reads do not unlock it - Terminal commands containing an independent
ghtoken requiregh-cli, including quoted shell subcommands - The plugin's own existing files may be patched during bootstrap only when their resolved real paths remain inside the resolved plugin directory
- Per-session state is lazily cleaned after 24 hours and capped at 1,024 sessions; process restart also resets it
Installation
Clone to the Hermes user plugins directory:
git clone https://git.xlion.tw/xlionjuan/kuri-skill-gate.git \
~/.hermes/plugins/kuri-skill-gate
Enable
hermes plugins enable kuri-skill-gate
Takes effect after a gateway restart (/restart or restart the Hermes gateway service).
Using in other profiles
mkdir -p ~/.hermes/profiles/<profile>/plugins
ln -s ../../../plugins/kuri-skill-gate \
~/.hermes/profiles/<profile>/plugins/kuri-skill-gate
hermes plugins --profile <profile> enable kuri-skill-gate
Verification
cd ~/.hermes/plugins/kuri-skill-gate
uv tool run ruff check __init__.py tests/
ty check __init__.py tests/
python3 -m pytest tests/ -v
All three (lint, type check, tests) must pass before committing.