Meet Zügel – An MCP Server Giving Your AI Coding Agent An Architectural Conscience

How Zügel keeps agent-written code inside your intended architecture — and helps you dig out of the debt you already have.

This article covers the version 26.3.4 (released on Aug 11th 2026) of Zügel.

AI coding agents have changed the economics of writing code. They have not changed the economics of structure. An agent will happily add the fifteenth dependency from your persistence layer back into your UI, import an internal class from a subsystem that was never meant to expose it, or close a dependency cycle that fuses two modules into one inseparable blob — all while the tests stay green. Architecture erosion used to happen at human speed. Now it happens at machine speed. Zügel – the German word for rein – is designed to stop that from happening. It puts you back in control and directs the coding agent to write architecturally and structurally sound code.

The traditional answer — periodic architecture reviews, static-analysis gates in CI — catches the damage after it is written. That is too late for agent workflows: by the time CI complains, the agent has already built three features on top of the illegal dependency.

Zügel moves the check to the moment that matters: before the agent writes the dependency. It is an MCP (Model Context Protocol) server that any MCP-capable agent — Claude Code, or anything else that speaks the protocol — connects to like any other tool provider. Under the hood it:

  • parses your sources itself (Java only Today with more languages coming soon),
  • maintains architecture rules based on Sonargraph’s architecture DSL (optional),
  • computes violations and dependency cycles from the resolved model,
  • tracks every change against baselines, so progress and regressions are visible per edit, and
  • answers precise dependency questions the agent would otherwise (badly) approximate with grep.

Zügel is a companion to Sonargraph, and can be used independently from it. Using it together with Sonargraph will still provide extra benefits like CI integration, dependency visualization and a powerful environment to design architecture rules based on the Sonargraph architecture DSL.

Read More

Major Changes to our C/C++ System Model

When we added C/C++ to Sonargraph our work was heavily influenced by John Lakos famous book “Large Scale C++ Design”. In this book Mr. Lakos presented a solid system to define the architecture of C++ systems based on components. A component in the most simple case is the combination of a header file and a source file, e.g. User.h and User.cpp. The header declares all elements that can be used from outside of the component, while the source file contains the implementation of the functionality. This unites the header and the source file into a logical component, that is better suited for dependency analysis.

Read More