惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

G
Google Developers Blog
有赞技术团队
有赞技术团队
WordPress大学
WordPress大学
博客园 - 司徒正美
D
Docker
B
Blog
V
Visual Studio Blog
Blog — PlanetScale
Blog — PlanetScale
U
Unit 42
S
SegmentFault 最新的问题
小众软件
小众软件
J
Java Code Geeks
美团技术团队
腾讯CDC
MyScale Blog
MyScale Blog
爱范儿
爱范儿
H
Help Net Security
宝玉的分享
宝玉的分享
Microsoft Azure Blog
Microsoft Azure Blog
A
About on SuperTechFans
Google DeepMind News
Google DeepMind News
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 三生石上(FineUI控件)
博客园 - 【当耐特】

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Hermes-Crew Hybrid: A Hybrid Architecture for Secure Mult...
Fenix · 2026-06-15 · via DEV Community

Fenix

Hermes-Crew Hybrid: A Hybrid Architecture for Secure Multi-Agent AI Workflows

I built a hybrid system that combines a central orchestrator (Hermes) with temporary CrewAI micro-crews, protected by 3 layers of security. Here's what it does and why it matters.

The Problem

Multi-agent AI systems are powerful but dangerous. When you chain multiple agents together, a single compromised agent can poison the entire workflow. Existing solutions are either too heavy (enterprise PKI infrastructure) or too light (basic regex filters).

The Solution: 3-Layer Security

Layer 1 — Pre-execution (MCP Tool Auditor): Before any agent can register a tool, it's audited for malicious instructions.

Layer 2 — Runtime (Agent Fixer Stage): Every output from every agent passes through a 3-stage pipeline (normalization → pattern matching → embeddings) in under 1ms.

Layer 3 — Pre-commit (Code Safety Hook): Before any git commit lands, the diff is analyzed by CrewAI + Ollama local. Malicious code gets rejected automatically.

Architecture

Hermes (Director)
    │
    ├── MCP Tool Auditor → verifies tools before registration
    │
    ├── Execution: venv (fast) / Docker (isolated) / auto (smart)
    │       ├── Agent 1: Researcher
    │       ├── Agent 2: Analyst
    │       └── Agent 3: Writer
    │
    ├── Security Gateway (Agent Fixer Stage) → filters output (<1ms)
    │
    └── Consolidator → parses output + generates Obsidian notes

What Makes It Different

1. Portable by design. Zero hardcoded paths. Every user configures their own .env.

2. Multi-model via LiteLLM. Works with Ollama local, OpenAI, Anthropic, Gemini, Groq, OpenRouter — any provider.

3. Local-first. Everything runs on the user's machine. No cloud dependencies required.

4. Obsidian integration. Every analysis generates a structured note with YAML frontmatter.

Code Safety Hook in Action

When you run git commit with malicious code:

[COMMIT RECHAZADO] Code Safety detected risks:
  → CrewAI detected vulnerabilities: VERDICT: FAIL
  → Agent Fixer Stage detected anomalies: High threat score: 1.05

For clean code:

[COMMIT APPROVED] Code verified by CrewAI + Agent Fixer Stage.

Tech Stack

  • Orchestration: Hermes Agent (local) + CrewAI (micro-crews)
  • LLM: Ollama local (default: gemma4-e2b:q4) via LiteLLM
  • Security: Custom 3-layer pipeline (<1ms overhead)
  • Integration: Obsidian vault for reports

Try It

git clone https://github.com/amurlaniakea/hermes-crew-hybrid.git
cd hermes-crew-hybrid
cp .env.example .env
# Edit .env with your Ollama model and paths
pip install crewai crewai-tools langchain litellm

# Install Code Safety hook (optional)
cp pre-commit-hook.sh /path/to/your/repo/.git/hooks/pre-commit
chmod +x /path/to/your/repo/.git/hooks/pre-commit

What I Learned

  1. Quick scan + LLM is the right approach. Pure regex misses too much. Pure LLM is too paranoid. Together they work.

  2. Output capture from CrewAI is tricky. Use PYTHONUNBUFFERED=1 and python -u.

  3. Portability matters. Hardcoded paths kill adoption. .env configuration is essential.

  4. Local LLMs are enough. You don't need GPT-4 to build effective AI security tools.

Links


AGPL-3.0-or-later — Built by Pedro Sordo Martínez (OWL / Hermes Agent) — 2026