AI Advanced course

Advanced use · Automation · Agents

AI Advanced
Course

Advanced use of Security
Ops Agents · Automation

Advanced use of AI, automation, agents.

Developing and securing Security Ops agents

In this advanced course, you’ll build your own Security Ops agent over two days: from context and cost optimisation, through custom skills and MCP servers, to secure, event-driven agents. A hands-on course for anyone who wants not only to use AI agents within their organisation, but also to extend, harden and operate them responsibly.

Developing, securing and operating AI agents in production

AI agents are easy to get started with – but difficult to operate properly. In this two-day online advanced course, you’ll make the transition from user to operator: you’ll take a look under the bonnet of Hermes, build your own tools and automate event-driven workflows. At the same time, you’ll learn how to target and harden your agent, and bring it into production via a robust governance process. Running through all the exercises is the common thread of creating a practical Security Ops agent.

What you’ll learn

  • How context windows, system prompt composition, compression and prompt caching really work – and how to use model routing to control costs effectively
  • Skill engineering: from a scrap of paper to a production-ready component, including testing, versioning and distribution within a team
  • Write your own MCP servers using the Python SDK, test them locally and operate them securely remotely via HTTP
  • Building event-driven agents: integrating webhooks, intervening in the agent loop using hooks, and extending the system with your own Python plugins
  • Set up local and hybrid model architectures, compare inference servers and objectively evaluate models using your own test set
  • Clearly separate multi-agent architectures using roles and profiles
  • Attack your agent via red teaming and then secure it using sandboxes, egress control and supply chain hardening
  • Establish observability (logs, alerts, costs) and integrate an agent into the governance framework using a profile and an operating manual

Target group

IT specialists, security engineers, automation specialists and system administrators who already have a basic understanding of Hermes or AI agents (having completed a beginner’s course or possessing equivalent experience) and now wish to take their skills to a professional level.

IThe benefits for you

Nach dem Kurs koennen Sie KI-Agenten nicht nur sinnvoll einsetzen, sondern mit eigenen Skills und MCP-Servern erweitern, in bestehende Monitoring- und Ticket-Prozesse integrieren und mit nachvollziehbaren Sicherheits- und Betriebsstandards verantworten. Sie nehmen einen lauffaehigen Security-Ops-Agenten, ein belastbares mentales Modell und eine klare Checkliste fuer den produktiven Betrieb mit.

What is this training course about?

The beginner’s course demonstrated how a Hermes agent is created: installing the server, setting up Hermes, connecting a model, working with skills and implementing initial security measures. This two-day online advanced course picks up exactly where the beginner’s course left off and answers the critical questions that arise as soon as an agent is intended to be more than just an interesting experiment: How do I teach the agent about our knowledge and systems – in a reliable, testable way that can be maintained by the team? How does it respond autonomously to events from monitoring, tickets or security systems? How do I distinguish between sensitive and non-critical tasks whilst protecting company data?

The central theme is a continuous hands-on project: over the course of both days, you will build a fully-fledged Security Ops agent for your environment – complete with your own skills, your own MCP server, webhook integration, audit logging, a hardened runtime environment and a formal governance profile for IT management. By the end, you’ll not only have a fully functional agent, but also a well-thought-out operational concept.

The training programme is based on four pillars: technology (context optimisation, skill engineering, MCP server), automation (webhooks, hooks, plugins), security (red teaming, hardening, multi-agents) and governance (compliance, documentation, operations). You will not only learn the theory, but also apply each topic directly within the project.

Contents at a glance

The training course is structured over two days. Day 1 focuses on expanding and optimising your agent; Day 2 focuses on safe, responsible operation within the organisation. Each module combines theory with practical labs and forms part of your final project.

  • Hermes under the bonnet: Understanding and optimising context windows, system prompt composition, compression and prompt caching
  • Measuring rather than guessing: Use `hermes prompt-size` to view memory usage; `/context` commands for real-time monitoring
  • Compression strategies: Gateway hygiene and agent compression with high context; manual compression via `/compress`
  • Configuring prompt caching and maximising cache hit rates through stable system prompts and model consistency
  • Model routing: auxiliary models for secondary tasks (compression, title generation, approvals), fallback chains and failover scenarios
  • Mixture of Agents (MoA) for difficult questions: query multiple reference models in parallel, aggregate results
  • Sub-agents and delegation: cost-optimised operation using cost-effective models for sub-tasks
  • Analysing and optimising costs: hermes insights for evaluation; prioritising optimisation measures
  • Skill engineering for production operation
  • From a scrap of paper to a production-ready skill: clear structure, tests, versioning and review, just like with real code
  • Anatomy of a skill: front matter (metadata), docstrings, pitfalls and verification criteria
  • Extract deterministic parts from scripts: calculations, parsing and validation are more reliable than the mode
  • Reveal knowledge progressively: load `references/` only when needed, rather than cramming everything into the system prompt
  • Specify output format with `templates/`: consistent, readable reports
  • Skill tests with three types of cases: happy path, edge cases, known bugs; automate regression tests
  • Team workflow: version control for skills in Git, review via pull requests, dual-control principle for agent permissions
  • Distribution: Taps (external repositories), external_dirs (shared directories), Snapshots (documentation and recovery)
  • The Curator: automatic archiving of unused skills, consolidation, pinning important skills
  • Building your own MCP servers
  • MCP as a security boundary: whatever the server does not offer, the agent cannot do – not even with prompt injection
  • The Python SDK FastMCP: a standard function with a decorator becomes a tool
  • Minimal, secure servers: open in read-only mode, parameterised queries, set hard limits in the code, not in the prompt
  • Preventing SQL injection: prepared statements, length limits, type hints for validation
  • Small, clear tools instead of universal tools: two precise functions instead of a generic `sql_execute`
  • Testing with mcp dev: use MCP Inspector in the browser before integrating Hermes
  • Integration with Hermes: config.yaml, hermes mcp test, check Toolset size
  • Remote operation via HTTP: Streamable HTTP, TLS via reverse proxy, token authentication or OAuth
  • Authorisation on the server: Which agent is permitted to use which tool; identity via `identity_header`
  • Audit logging for every call: time, agent, tool, parameters
  • Event-driven agents
  • From conversation partner to event processor: webhooks for monitoring alerts, tickets, Git events, SIEM messages
  • Setting up webhooks: Gateway port 8644; configuring routes with prompts, filters and toolsets
  • Payload templates: Placeholders in brackets (dot notation for nested fields), for the entire payload
  • Authentication: HMAC secret generated via CLI or statically in config.yaml; GitHub, GitLab, or generic V2 format
  • Filter out noise before it costs money: scripts in ~/.hermes/scripts/ with [SILENT] output
  • Hooks: four types (pre_model, post_model, pre_tool, post_tool) and two levels (shell and gateway)
  • Guard hooks: block tool calls in the event of suspicious commands; return exit code 2 to deny
  • fail_closed: true is mandatory for security hooks – block on error, do not allow through
  • Audit logs: Gateway hooks write JSON lines for each event (session:start, agent:step, session:end)
  • Plugins: custom tools, commands and hooks directly within the process without a separate server; faster than MCP
  • Plugin schema: plugin.yaml + __init__.py with the register() function; use `hermes plugins enable` to activate
  • Plugins must never crash: error handling is mandatory; return JSON responses to `stderr`
  • Local and hybrid models
  • When is local processing worthwhile: data classification (BPD, confidential data), high volume, availability without an internet connection, data sovereignty
  • Hardware costs vs. functionality: local models are cheaper for high volumes, but often less powerful when using complex tools
  • Inference server comparison: Ollama, vLLM, LM Studio, LocalAI with OpenAI-compatible interface
  • Critical settings: sufficiently large context window (32k+ tokens), tool calling enabled, VRAM reserve for KV cache
  • Hybrid architecture with profiles: separate profiles for internal (local models) and public tasks (cloud)
  • hermes profile create: Separate profiles with their own model, tools and configuration
  • Security for local use: auxiliary models also stored locally; no web toolset in the internal profile; no cloud fallbacks
  • Your own test suite: small, relevant test cases rather than relying on benchmarks; compare objectively
  • Multi-agent architectures and separation of roles
  • Why multiple agents: separation of duties (who is authorised to do what), data classification (internal vs. public), uninterrupted specialisation
  • Role profiles: Admin agent with sudo, Research agent with web search only, Security agent with admin tools
  • Handover between roles: clean interfaces, structured results, audit trail
  • Delegation and sub-agents: assigning a subtask to another agent, optionally using a more cost-effective model
  • Kanban and projects: organising work spanning several days, tracking progress, maintaining persistent status
  • Security Deep Dive: attacking and hardening agents
  • Why agents need their own threat analysis: new attack vectors (prompt injection, tool misuse)
  • OWASP Top 10 for agent-based applications: from prompt injection to supply chain integrity
  • Creating a threat model: assets (data, systems), roles (users, admins), attacker profiles (internal, external)
  • Red-teaming: attacking your own agent using jailbreak techniques to identify vulnerabilities
  • Defence in depth: multiple layers rather than a single silver bullet
  • Sandbox environment: VM or container with the minimum necessary privileges; egress control; restricting the terminal toolset
  • Supply chain hardening: hooks check tool calls; whitelisting rather than blacklisting; blocking suspicious patterns
  • Agent in Active Directory: tiering model (T0 core, T1 services, T2 clients); agent as a service account with minimal privileges
  • Advanced hardening checklist: central governance document detailing current measures
  • Operations and observability
  • What to monitor: available roles, costs, error rates, security events
  • Data sources: agent logs, hermes insights, hook events, audit logs, SIEM integration
  • To the SIEM: export structured logs, set up alerts for anomalies (e.g. unexpected shell commands)
  • Keeping costs under control: hermes insights with time-based and profile-based filters
  • Deploying updates securely: testing in Lab, activating staging approval, fallback chains for rollback
  • High availability and emergency response: multiple agent instances, load balancing via gateway, failover scenarios
  • Practical workshop: use cases for IT and security
  • Daily health and patch report: an automated skill that checks systems and generates reports
  • Certificate monitoring (PKI): expiry tracking, automatic renewal triggers
  • Analysing the PingCastle report: understanding and prioritising AD risks in real time
  • Log triage: classifying, aggregating and routing incoming logs to the correct teams
  • Automatically generating documentation: system settings in Markdown, checklists, runbooks
  • Governance and compliance
  • Why governance isn’t a hindrance: clear rules build trust and enable scalability
  • Legal framework: AI Act (high-risk AI), GDPR (data protection), BetrVG (co-determination), NIS-2 (critical infrastructure)
  • The use case profile: What does the agent do, what data is involved, who monitors it, and where are the risks?
  • The Agent Policy: internal rules on authorisation, operational obligations, escalations, compliance checks
  • External transparency: documenting who is affected by AI; audit trail for compliance auditors
  • Final project: guiding your Security Ops agent through the entire governance process – from the initial concept to approved live operation

Methodology & Practical Component

This training course is deliberately structured around a project. Rather than following a series of theory slides, you will spend both days building a continuous Security Ops agent. This allows you to gain hands-on experience of each topic straight away: you will develop real-world skills, programme an MCP server, configure webhooks and set up governance profiles.

All exercises take place in the Lab VM – an Ubuntu instance with the Hermes Agent running (from the beginners’ course). You will also be provided with an Ansible playbook that automatically installs the necessary additional components (MCP packages, inference server, monitoring simulator).

The trainer will guide you through each module. Difficult sections (e.g. red teaming in Module 7) will first be worked through together, after which you will practise independently. Questions are not only welcome, but essential – agent-based applications are still in their infancy, and there are plenty of surprises.

By the end of the first day, you will already have a working agent with its own skill and MCP server. Day 2 then focuses on security and documents the operation. The final governance exercise combines technical understanding with the latest compliance requirements.

Practical lab sessions for each module

Lab 1: Use the hermes prompt-size command to measure the system prompt and identify opportunities for optimisation
Lab 2: Write a production-ready skill (including tests, documentation and a description of potential pitfalls)
Lab 3: Develop your own MCP server in Python (read-only database queries, parameterised security)
Lab 4: Connecting webhooks from the monitoring system, filtering events and configuring prompts with placeholders
Lab 5: Writing hooks and plugins – Shell guard and Python extension
Lab 6 (Homework if short of time) Set up Ollama as a local model, configure the profile, test the hybrid scenario
Lab 7: Create a threat model, attack the agent, document hardening measures (red teaming)
Lab 8: Setting up observability – logs, metrics, first alerts
Lab 9: Implement a real-world IT use case (Health Report, PingCastle, certificate check)
Lab 10 Governance Fact Sheet, Operating Manual, Approval Process

Background information and references

Course materials: detailed explanations, command references, glossary, knowledge questions
Sample solutions for selected labs, for self-study or as a guide when stuck
Further resources: links to Hermes documentation, OWASP guidelines, best practices for multi-agent systems
Checklists for hardening, deployment and governance – to tick off and document

Who is this training course suitable for?

  • IT administrators: who wish to set up and take responsibility for the AI-powered automation of routine tasks (patches, reports, health checks)
  • Security engineers and SOC analysts: who wish to use an agent as a tool for log triage, alerting and incident analysis
  • IT architects and consultants: who plan multi-agent systems, define governance and liaise with compliance teams
  • Automation specialists and scripting experts: who wish to supplement and extend their shell scripts using AI agents
  • Prerequisite: Completion of the Hermes beginners’ course or equivalent experience (self-installed, running agent)
  • Confidence in using the Linux command line and SSH is required
  • Basic knowledge of Python is required (functions, installing packages) – for MCP servers and plugins
  • Basic understanding of HTTP, JSON and YAML
  • Helpful but not essential: experience with monitoring systems (Prometheus, Grafana), SIEM (Splunk, ELK) and Active Directory

The benefits you’ll experience after your workout

  • You will understand the inner workings of Hermes: context windows, system prompt composition, prompt caching and model routing
  • You will be able to measure and optimise costs in a targeted manner – rather than making savings blindly
  • You will build agents like professional software: with testing, version control, documentation and code reviews
  • You design your own MCP server and securely integrate it with your organisation’s systems (ticketing, monitoring, CMDB)
  • You automate event processing: monitoring alerts, new tickets and other system events automatically trigger agent runs
  • You make informed decisions between cloud-based and on-premises models and implement hybrid architectures
  • You identify security risks in agent-based systems, carry out red teaming and systematically harden your agents
  • You securely deploy agents in your Active Directory according to the tiering model
  • You monitor and document agent operations in a traceable manner – for audit, compliance and troubleshooting
  • You guide an agent through the entire governance process (AI Act, GDPR, works council, information security)
  • You’ll take home a fully functional Security Ops agent – complete with its own skill set, its own MCP server and comprehensive documentation
  • You’ll receive a hardening checklist and a governance template – ready for immediate use within your organisation

How we work

  • Hermes Agent v0.21 or later (provided within the VM)
  • Lab VM: Ubuntu Server 26.04 LTS with Hermes Agent installed (from the beginners’ course)
  • Additional components are deployed via an Ansible playbook: MCP SDK, Ollama (optional), simulators for monitoring and tickets
  • Python 3.9+ on the VM (for MCP server development and plugins)
  • venv or uv support for isolated environments
  • Basic knowledge of the Linux terminal: SSH, paths, simple shell commands
  • Text editor or IDE (VS Code, PyCharm, vim) for Python and YAML files
  • Access to the online course materials and GitHub repository containing sample code
  • No access to real production systems or data is required during the labs – work is carried out in sandbox environments
  • Important: Do not use any real personal data or production login credentials in the labs

Let’s talk about your AI needs

This post is also available in: German