Version v0.1.1 extends the decoupled Model Context Protocol (MCP) server architecture from v0.1.0 with specialized upgrades designed to enable fully autonomous, safe, and successful recursive self-improvement.
-
Decoupled Mutable Tool Payload (
dynamic_mcp_server.py):- Acts as the dynamic mutable registry target for self-evolution.
- Defines two entry points:
get_tool_manifest()andexecute_tool(name, arguments). - v0.1.1 Decoupling: Tool computations (
read_skill_source,mutate_mcp_infrastructure,execute_sandbox_test) are extracted into standalone helper functions. The mainexecute_toolacts as a simple lookup router, isolating side-effect boundaries and simplifying self-mutation targets.
-
Static Host Controller (
orchestrator.py/StaticMCPHost):- Houses the protected, immutable engine layer.
- Features a dynamic hot-reload system via
importlib.reloadto safely pull in mutated tool versions without interrupting the main host process. - Implements strict framework protection protocols by blocking tool calls to elements defined in
EXCLUDED_SKILLS. - Enforces
frozensetconstant-time lookup for infrastructure security boundaries to optimize AST walk iterations. - v0.1.1 AST Pre-Checks: Enforces automatic AST syntax parse validation on all proposed code modifications and adversarial tests prior to launching the sandbox, optimizing token execution loops.
-
Sandbox Isolation Engine (
sandbox.py):- Executes code mutations inside isolated, resource-constrained environments.
- v0.1.1 Typeless/Auto-Import injection: Automatically prepends typing import headers (e.g.
from typing import List, Dict, ...) to Python scripts to prevent common NameError exceptions on type annotations during sandboxed tests.
- Run the structural MCP verification test:
python3 orchestrator.py --mode shadow_test
- Run standard unit testing to verify orchestrator database registry, discovery, and self-patching integrity:
python3 test_hermit.py
- Start the background daemon:
export GEMINI_API_KEY=<your_key> python3 hermit_daemon.py
- Run concurrent integration tests:
python3 test_integration.py
- Monitor evolution:
python3 monitor_evolution.py