An experiment in combining structural and behavioural architecture models for AI-assisted reasoning.
Why combine C4 and DCL?
Architects rarely work with one complete representation of a system.
A C4 model can show systems, containers, relationships, and dependencies. It is excellent at answering questions such as:
- What exists?
- What talks to what?
- Where does responsibility sit structurally?
But structural diagrams do not always explain the business behaviour moving through those structures.
DCL, the Declarative Capability Language, approaches architecture from the other direction. It describes capabilities, outcomes, effects, events, policies, and lifecycle. It is intended to answer questions such as:
- What is this system responsible for?
- What business outcomes matter?
- What happens when something fails?
- How does a business I progress over time?
That led to a simple question: What happens if an LLM is given both models of the same architecture?
This experiment was not about replacing C4, nor about forcing DCL into a structural modelling role. It was about testing whether the two models could become complementary sources of architectural knowledge.
The complete experiment -> C4 DSL, DCL source, prompts, findings, and diagram source is available in the DCL Repository
The experiment
The scenario is a fragment of an enterprise media content-management architecture that I worked on more than a decade ago, reconstructed from memory. It is not a complete production architecture, but it contains enough behaviour and structure to make the experiment meaningful.
Users upload batches of video, images, audio, and microsite packages through a web portal. They assign attributes to content and later approve it for publication.
Uploaded media is analysed and routed into the appropriate processing path. Video is analysed, transcoded, and thumbnailled. Images are thumbnailled. Approved content is matched to playlists using its attributes, and digital signage players poll for new playlist versions before downloading the required media. Playback events are sent to analytics.
The original architecture used CQRS and event sourcing, with asynchronous processing across several services.
The models
The C4 model describes the structural architecture:
- portal and content-management application
- media-processing services
- playlist publishing and serving services
- digital signage players
- analytics
- storage, eventing, event sourcing, and read models
C4 system context

C4 Container diagram

The DCL model describes the behavioural architecture:
- UploadContentBatch
- AnalyseMediaFile
- GenerateThumbnail
- TranscodeVideo
- ApproveContent
- PublishContentToPlaylist
- ServePlaylistToPlayer
- RecordPlaybackAnalytics
It also includes a supervising lifecycle for a media item:
Uploaded
→ Analysed
→ Processing
→ ReadyForApproval
→ Approved
→ Published
or
→ Rejected
→ Failed
The lifecycle is deliberately business-oriented. It is driven by declared outcomes and events, rather than by service calls. That keeps DCL focused on behavioural progression while C4 remains responsible for structural orchestration.
DCL architecture view
Generated from the DCL code in the VS Code extension (architecture view)

DCL event flow
Generated from the DCL code in the VS Code extension

Method
I created a C4 DSL model and a DCL model for the same scenario. I then used Codex with both the C4 and DCL MCP servers available.
The prompts did not use a hand-authored mapping file. Instead, the LLM had to correlate the models through shared vocabulary, responsibilities, effects, events, lifecycle transitions, and C4 relationships.
The experiment asked five questions:
| Question | What it tested | Most useful result |
| Correlate the models | Can DCL capabilities be related to C4 containers without a mapping file? | High-confidence correlation where vocabulary and responsibilities aligned |
| Find fragmented capabilities | Which capabilities span multiple containers? | Distinguished intentional distributed workflow from possible responsibility leakage |
| Architectural consistency review | Where do the structural and behavioural views disagree or leave gaps? | Found role, event, lifecycle, and ownership ambiguities |
| Impact analysis | What does a container outage mean in business terms? | Connected dependency failure to capabilities, outcomes, and lifecycle states |
| Explain a capability | How is one capability realised structurally? | Produced a useful explanation of one business capability across the architecture |
The complete prompt outputs and findings are available in the repository rather than reproduced in full here.
What the experiment showed
The first result was encouraging but not surprising: correlation was high where names and responsibilities aligned.
For example, AnalyseMediaFile correlated strongly with the File Analyser Service. GenerateThumbnail correlated with the Thumbnail Service. TranscodeVideo correlated with the Video Transcoding Service. PublishContentToPlaylist correlated with the Playlist Publisher.
That is not magic. It is the result of consistent business vocabulary appearing in both models.
The more interesting result was that the models contributed different kinds of evidence.
C4 showed that the Playlist Publisher reads playlist projections, publishes events, and sends playlist versions to the Playlist Service.
DCL explained why those relationships mattered. PublishContentToPlaylist produces a business outcome, emits PlaylistUpdated, applies reliability and audit policy, and advances the media-item lifecycle from Approved to Published.
C4 gave the architecture implementation gravity. DCL gave the relationships business meaning.
Fragmentation became visible
The second prompt asked which capabilities were implemented across multiple containers.
Most capabilities were not owned by a single container. That was expected.
UploadContentBatch involved the portal, content-management application, media storage, eventing, event sourcing, and read-model projection. PublishContentToPlaylist involved the Playlist Publisher, query/read model, eventing, event store, and Playlist Service.
This did not automatically indicate poor architecture. In many cases, it reflected intentional separation between user interaction, command handling, asynchronous processing, event sourcing, and query models.
The useful distinction was between:
- a capability with one clear primary business-logic owner and supporting technical dependencies
- a capability split across several business services
- a cross-cutting lifecycle that has no single container-level implementation
The media-item lifecycle was the clearest example of the last category. It spans analysis, processing, approval, and publication. It is not a service. It is a behavioural view over a business journey.
That is something C4 does not normally express directly.
Consistency review was more useful than expected
The consistency review did not reveal major contradictions, but it found useful architectural questions.
For example:
- C4 described a Content User who could review and approve content, while DCL separated
ContentUserandContentApprover. - DCL modelled rejection as an outcome and lifecycle state, but not yet as a first-class event.
DownloadMediaAssetsappeared as part of the DCL serving capability, while the C4 model showed the digital signage player downloading assets directly from storage.- The lifecycle had no explicit structural owner. The Content Management Application was the likely candidate, but the lifecycle could also be interpreted as an event-sourced behavioural projection.
These are exactly the sort of questions that often remain implicit in architecture documentation.
Impact analysis was the strongest operational result
The impact-analysis prompt produced the most interesting result.
C4 can show that an Event Bus, Event Store, Query Store, or Media Storage component is central to many dependencies. But DCL allowed the analysis to go further:
If this component fails, which business capabilities become unavailable?
Which outcomes are no longer achievable?
Which lifecycle transitions are blocked?
Which actors are affected?
For example, failure of the Event Bus did not simply break a technical dependency. It interrupted the chain from upload to analysis, processing, playlist publication, lifecycle progression, and analytics propagation.
Failure of Media Storage affected upload, analysis, thumbnail generation, transcoding, and player asset download.
This is the beginning of a more useful form of blast-radius analysis:
C4 identifies structural dependencies.
DCL translates dependency failure into business impact.
The next refinement should return this analysis in a structured format, including a transparent blast-radius score. That would allow diagrams and heat maps to be generated from evidence rather than from free-form prose.
What did not work as hoped
I initially expected the LLM to turn its findings directly into useful Mermaid or PlantUML diagrams.
That was the wrong abstraction.
The LLM could produce reasonable explanations, but prose findings are not a diagram model. Asking it to jump directly from analysis to a generic graph produced diagrams that were technically correct but not particularly useful as architecture communication.
The missing step is a structured derived projection.
For example:
Business area: Publish Content
Capability: PublishContentToPlaylist
Primary business-logic owner: Playlist Publisher
Supporting business-logic containers: Playlist Service
Evidence: PublishPlaylistVersion, PlaylistUpdated, C4 publication relationship
Confidence: 0.96
Fragmentation: primary owner plus serving responsibility
That is not a manual mapping file. It is derived analysis output: a capability-allocation projection built from C4, DCL, and the LLM’s evidence-based reasoning.
Diagrams should be rendered from that projection, not directly from a paragraph of findings.
The real discovery: a functional architecture view
The most useful outcome was not an AI-generated explanation. It was the beginning of a functional architecture view.
Architects often need a view that answers:
Which systems, services, or containers contain the business logic for this capability?
That view should be built in two layers.
The first layer is a pure capability map. It contains only business capabilities and their relationships. It should be readable without knowing the technology landscape.
The second layer is an implementation overlay. It adds the applications, services, and containers that contain or directly execute business logic for each capability.

Shared infrastructure is deliberately excluded from this overlay. Databases, queues, event buses, event stores, and object storage are important, but they make the functional view noisy. They belong in dependency, reliability, and impact views.
This distinction matters.
A functional architecture view should show where business responsibility lives.
An impact view should show the shared infrastructure and technical dependencies that can affect that responsibility.
Where C4 and DCL each matter
C4 remains the structural source of truth.
It describes systems, containers, relationships, dependencies, and the technical landscape in which the software operates.
DCL remains the behavioural source of truth.
It describes capabilities, outcomes, effects, events, policies, and lifecycle progression.
Neither model should be forced to become the other.
The value comes from using both as complementary evidence. With disciplined vocabulary, an LLM can correlate them and derive useful projections:
- capability-to-container allocation
- functional architecture views
- fragmentation analysis
- structural and behavioural consistency checks
- business-aware blast-radius analysis
- capability implementation explanations
Conclusion
This experiment did not produce an automatic mapping engine between C4 and DCL.
It produced something more credible: two complementary sources of architectural evidence.
C4 explains what exists and how it connects. DCL explains what the system is responsible for and what business behaviour is affected when things change or fail.
The most promising output is a derived functional architecture view: a capability map first, followed by an implementation overlay showing where business logic lives.
The next step is to make the analysis more structured, especially for impact analysis. If a C4 failure can be expressed not only as broken dependencies but as affected capabilities, outcomes, actors, and lifecycle progression, architecture knowledge becomes much more useful to both humans and AI.

