hivemind-mcp
π§ Sanctify-Hivemind
A multi-agent orchestration framework for autonomous operations on live systems.
Hivemind lets a swarm of specialized AI agents take a one-line goal, decompose it into a task graph, execute tool calls against a real production environment, independently verify every action, and roll back on failure β with a full, replayable audit trace.
WordPress is the first environment adapter (and a demanding one: live sites, credentials, no room for "oops"). But the framework is environment-agnostic β the interesting part is the architecture, not the CMS.
The website is the proving ground. The product is the agent system.
Why this exists
Letting an LLM act on a live system is easy to demo and terrifying to run. The hard problems aren't "call an API" β they're:
Coordination β how do you decompose a fuzzy goal into ordered, parallelizable work and delegate it to the right specialists?
Safety on production β how do you let an agent write to a live system without a bad step causing an outage?
Reliability β how do you know an action actually worked, and recover when it didn't, without a human watching every step?
Hivemind is an opinionated answer to those three, learned the hard way from real incident-response and site-operations work.
Architecture
ββββββββββββββββββββββββββββββββ
goal ββββββββΊ β Orchestrator β
"harden + audit β goal β task DAG β schedule β
this site" βββββββββββββββββ¬βββββββββββββββ
β dispatch (parallel where independent)
ββββββββββββββββββββββββββΌβββββββββββββββββββββββββ
βΌ βΌ βΌ
ββββββββββββββ ββββββββββββββ ββββββββββββββ
β Recon β β Security β ... β SEO β βββ specialist agents
β Agent β β Agent β β Agent β
βββββββ¬βββββββ βββββββ¬βββββββ βββββββ¬βββββββ
β tool calls (typed, capability-scoped) β
βΌ βΌ βΌ
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Tool Registry + Capability / Permission model β
β read-only vs write Β· allowlists Β· human-approval gate β
βββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββ
βΌ
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Environment Adapter (WordPress: REST Β· FTP Β· Browser) β
βββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββ
βΌ every write is wrapped by:
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Safety Engine snapshot β act β health-check β rollback β
βββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββ
βΌ
ββββββββββββββ reject/retry ββββββββββββββββββββββββββββ
β Critic / ββββββββββββββββββββ every action's outcome β
β Verifier ββββ approve ββββββΊβ checked against the goal β
ββββββββββββββ ββββββββββββββββββββββββββββ
Cross-cutting: Memory (world-model + shared blackboard + pattern store)
Audit Trace (every decision + tool call, replayable)
Cognition (pluggable LLM backends / SuperBrain)The six systems
System | Responsibility | Why engineers care |
Orchestrator | Goal β task DAG β parallel/sequential scheduling β delegation | Real task decomposition, not a linear script |
Tool Registry + Capability model | Typed tools with permission scoping (read vs write, allowlists, approval gate) | The "how do you let an agent touch prod safely" answer |
Safety Engine | Snapshot-before-act, post-act health check, auto-rollback, circuit breakers | Responsible autonomy on live systems |
Critic / Verifier | Independent check of each action vs. the goal; retry or roll back | Actorβcritic on real infra β separates agents from LLM wrappers |
Memory | Per-environment world-model, shared blackboard, reusable pattern store | Agents don't start cold; they coordinate + learn |
Audit Trace | Every decision and tool call logged + replayable | Debuggability, trust, post-mortems |
Design principles
Environment-agnostic core. WordPress is an adapter; the orchestrator/critic/ safety layers know nothing about it.
Capability-scoped by default. Agents get the least access needed. Writes are explicit, gated, and reversible.
Verify everything. No action is "done" until an independent critic confirms it against the goal.
Every write is a transaction. snapshot β act β verify β commit or rollback.
Model-agnostic cognition. Reasoning is pluggable (local rules, hosted LLMs, or SuperBrain as the cognition/decision layer).
Credential-free repo. Secrets live in env / a secret manager, per environment, never committed.
Repository layout
Sanctify-Hivemind/
βββ hivemind/
β βββ core/
β β βββ tools.py # typed tool registry + capability/permission model
β β βββ safety.py # snapshot/rollback, health checks, audit trace
β β βββ agent.py # base agent contract
β β βββ orchestrator.py # goal β task DAG β scheduler β delegation
β β βββ critic.py # verification / actor-critic loop
β β βββ memory.py # world-model, blackboard, pattern store
β βββ environments/
β β βββ wordpress/ # the WordPress adapter (first environment)
β βββ agents/
β β βββ recon.py # site reconnaissance specialist
β β βββ security.py # security specialist (malware/CVE)
β βββ cognition/ # pluggable LLM/SuperBrain backends
βββ examples/ # runnable end-to-end demos
βββ traces/ # replayable run logs (gitignored)
βββ tests/
βββ .kiro/ # steering + skill (SuperBrain integration)Status
π§ Vertical slice. The core (orchestrator, tools, safety, critic, memory), the WordPress adapter, and the Security/Recon specialists run a real goal end-to-end. Additional specialists (SEO, Frontend, Content) plug into the same contracts.
The Security agent currently detects:
the self-healing "Smooth Backup Ink" (SCV) file-malware family (IOC scan),
vulnerable plugins/themes via a versioned CVE rules library (ThemeREX Addons, Slider Revolution), and
the Japanese-keyword-hack / cloaked SEO spam class β by fetching the page as Googlebot and diffing against a normal browser, catching spam that is invisible to visitors but indexed by Google (foreign-script titles, counterfeit-goods phrases, spam sitemap URLs).
Use it from any AI assistant (MCP)
Hivemind ships an MCP server (hivemind-mcp) so it plugs in as a native tool for
Kiro, ChatGPT (desktop), Codex, and the Gemini CLI, and as a library/CLI for
Grok or any code-running agent.
pip install -e ".[mcp,wordpress]"
hivemind-mcp # stdio MCP server exposing recon / security_scan / seo_spam_scan / run_goalPoint the target site via the server's env (WP_URL) β the model never supplies
credentials or the target, which prevents prompt-driven SSRF / secret leakage.
π Copy-paste config for each assistant is in USAGE.md.
Tool | Access | Purpose |
| read-only | Fingerprint stack, plugins, exposure |
| read-only | Malware IOCs + vulnerable-plugin CVEs |
| read-only | Japanese/Russian keyword-hack + cloaking |
| varies | Run a natural-language goal end-to-end |
Credits
Built and maintained by Sanctify β Digital Marketing Agency, Goa.
Sanctify-Hivemind was distilled from real-world WordPress security incident response, SEO, and site-operations work. If it helps you, a link back to www.sanctify.in is appreciated.
License
MIT Β© Sanctify