Skip to main content

blackwall-hermes-plugin

Pre-action risk check for Hermes Agent (NousResearch). Hooks pre_tool_call so STOP-rated tool calls abort before they run — without modifying any of your other plugins or skills.

Powered by BLACK_WALL. Get a free key at blackwalltier.com/dashboard/keys.

Install

pip install blackwall-hermes-plugin

Enable the plugin in ~/.hermes/config.yaml:

plugins:
  enabled:
    - blackwall

Set the API key (env var, ~/.hermes/.env, or your launcher):

export BLACKWALL_API_KEY=bw_live_xxx
export BLACKWALL_MODE=observe        # or 'enforce' once you trust the verdicts

That's it. Every tool the agent tries to call goes through pre_tool_call → BLACK_WALL forecast → verdict.

What you get back per tool call

  • GO / CAUTION / STOP
  • risk score 0–100
  • reversibility class (REVERSIBLE / RECOVERABLE / IRREVERSIBLE)
  • named red flags — e.g. SQL_NO_WHERE, PROMPT_INJECTION_LIKELY, IRREVERSIBLE_NO_BACKUP
  • an Ed25519-signed Decision Receipt — verifiable offline against the published public key

Latency: ~4–8 seconds.

Modes

Mode Behavior
observe (default) Score every tool call and log to BLACK_WALL; never block. Zero behavior change — safe to drop in.
enforce STOP → hard block (returns {"action": "block", "message": "..."}). CAUTION → configurable (default: block; set BLACKWALL_CAUTION=allow to let it proceed). GO → proceeds.

Start in observe for a few days to see what the verdicts look like on your real traffic. Switch to enforce once you trust the scoring.

Why pre_tool_call?

Hermes Agent exposes pre_tool_call as a documented plugin hook with {"action": "block", "message": "..."} return semantics — exactly the shape a pre-action guardrail needs. The plugin does not monkey-patch the dispatcher; it uses the documented extension surface.

That means:

  • Multiple plugins can register pre_tool_call — first valid block directive wins
  • Companion post_tool_call hook fires after the tool runs (or after a block), so we can auto-report outcomes via BLACK_WALL observe()
  • The plugin is opt-in — users must add blackwall to plugins.enabled in their config

Config reference (env vars)

Variable Default Notes
BLACKWALL_API_KEY (required) Free key at https://blackwalltier.com/dashboard/keys
BLACKWALL_MODE observe observe (log only) or enforce (block STOP)
BLACKWALL_CAUTION block block (treat CAUTION as STOP) or allow (let CAUTION proceed)
BLACKWALL_BASE_URL https://blackwalltier.com Override for self-hosted/staging

How it works

                     ┌──────────────────────────────┐
                     │ Hermes agent decides to       │
                     │ call tool X with args Y       │
                     └─────────────┬────────────────┘
                                   │
                          pre_tool_call
                                   │
                                   ▼
            ┌──────────────────────────────────────────┐
            │ blackwall plugin: forecast(X, Y)          │
            │ ↓                                          │
            │ STOP    → return {"action": "block",       │
            │            "message": "..."}               │
            │ CAUTION → block or allow (env-configured)  │
            │ GO      → return None                      │
            └──────────────────┬───────────────────────┘
                               │ (if not blocked)
                               ▼
                       tool actually runs
                               │
                          post_tool_call
                               │
                               ▼
            ┌──────────────────────────────────────────┐
            │ blackwall plugin: observe(forecast_id,    │
            │   outcome_class)                          │
            │ matched / diverged / aborted              │
            └──────────────────────────────────────────┘

Fail-open: if BLACK_WALL is unreachable, the hook logs a warning and lets the tool proceed. A BLACK_WALL outage will never take down your agent.

Architecture

┌──────────────────────────────────────────────┐
│ BLACK_WALL HTTP API (stable, versioned)      │
└──────────────────────────────────────────────┘
              ▲
┌──────────────────────────────────────────────┐
│ blackwall-sdk  (shared Python client)        │
│   forecast()  observe()                       │
└──────────────────────────────────────────────┘
              ▲
┌──────────────────────────────────────────────┐
│ blackwall-hermes-plugin (this package)       │
│   pre_tool_call  post_tool_call               │
└──────────────────────────────────────────────┘
              ▲
            Hermes Agent

When Hermes ships breaking changes to its plugin contract, only this package needs to update. The HTTP API, the blackwall-sdk client, and every other BLACK_WALL integration remain insulated.

License

MIT

Metadata

Release files for blackwall-hermes-plugin 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for blackwall-hermes-plugin 0.1.0
File Size Uploaded Provenance
blackwall_hermes_plugin-0.1.0.tar.gz 10.7 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for blackwall-hermes-plugin 0.1.0
File Interpreter ABI Platform
blackwall_hermes_plugin-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 20.2 kB

Release files / blackwall_hermes_plugin-0.1.0.tar.gz

Download URL blackwall_hermes_plugin-0.1.0.tar.gz
Size 10.7 kB
Tags Source
SHA-256 checksum
How to use checksums
579296c532377b90366434571cc3703b4e638ec30d073a5a6a9619963f3f8b76
BLAKE2b-256 checksum
How to use checksums
ab200a73c2f08446c2adebaadb8cc3c7a7502ac0af2e1d440ff8350543dd40d3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.8

Release files / blackwall_hermes_plugin-0.1.0-py3-none-any.whl

Download URL blackwall_hermes_plugin-0.1.0-py3-none-any.whl
Size 9.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
32b90016d4ea953b025698c483e7f8ab0a126fb7478ed4adb5adaacd42e42810
BLAKE2b-256 checksum
How to use checksums
08b04f3eb56c0f6cc0ea5364a00fb5193aabe0976fd375f411cc44d485c45c85
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.8

Security for blackwall-hermes-plugin 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page