Generate from source

Generate an architecture diagram from Kubernetes manifests.

Kubernetes YAML contains the whole topology and presents it as several hundred lines in which none of it is visible.

Download for macOS
v0.1.33 · .dmg · Apple Silicon & Intel
Signed & notarized by Apple · opens without a Gatekeeper warning
sha256 698955a0187bc039f4c74f5d05a9f10fbb27376a45788a0a241d1326b73873c7
Download for Windows instead
$curl -fsSL https://lucidtrain.com/install.sh | sh

What it reads

Every manifest in the tree: Deployments, StatefulSets, DaemonSets and Jobs for workloads, Services and Ingress for how traffic reaches them, ConfigMaps and Secret references for what they talk to, and PersistentVolumeClaims for what holds state. Kustomize overlays and Helm charts are followed so the diagram reflects a rendered environment rather than a template with placeholders in it.

How manifests become components

Each workload is a component, named from its labels rather than from the file it lives in. A Service becomes the edge between whatever selects it and whatever targets it, which is the relationship the YAML expresses through label selectors and which is precisely the part that is hard to see by reading. Ingress rules put a real edge at the front of the diagram. StatefulSets with volume claims land in the data tier, so stateful workloads are visually distinct from the ones you can restart freely.

Why the layout can be trusted

The agent reads the files listed above and emits a semantic graph: components, the tier each belongs to, and the edges between them, with no coordinates anywhere. The ELK layout engine then computes positions and orthogonal edge routing. This is why the output cannot come back with boxes overlapping or arrows crossing through cards, which is the usual failure when a language model is asked to place things on a canvas itself.

Selectors are the interesting part

The connection between a Service and its pods is expressed as a label match, and label matches are exactly what humans get wrong when reading manifests: a selector that matches nothing looks identical to one that matches correctly. Drawing them makes an orphaned Service visible immediately, which is a debugging use rather than a documentation one and is often the more valuable half.

Your manifests stay on your machine

It runs on your machine. With a local Ollama model nothing leaves the laptop at all, and with your own API key the file contents go to the provider you chose and never through us. For a source that is your actual codebase, that distinction is usually the deciding one.

Kubernetes to diagram

ResourceIn the diagram
Deployment, StatefulSet, DaemonSetApplication tier component
Job, CronJobWorker component
ServiceThe edge between selector and target
Ingress, GatewayEdge tier entry point
PersistentVolumeClaimData tier attachment
ConfigMap and Secret referencesEdges to external dependencies
NamespaceGrouping, when the diagram spans several
HorizontalPodAutoscalerA note on the component it scales

The prompt

shell
$ Read the Kubernetes manifests here and diagram the workloads, the services connecting them, and how traffic enters through the ingress.
FAQ

Questions

Does it connect to my cluster?

No. It reads YAML from disk and needs no kubeconfig and no cluster access, which means it works against a repository you have checked out and against environments you cannot reach.

Does it handle Helm charts?

Yes, by working from rendered output. Templates full of unresolved values produce a diagram of the template rather than of the deployment, so rendering first gives a much better result.

What about multiple namespaces or environments?

It handles them, and one namespace at a time is usually more readable. Diagramming staging and production together mostly illustrates that they differ, which a diff shows better.

Can it show the service mesh?

It draws mesh resources where they are declared as manifests. Runtime routing decisions made by the mesh control plane are not in the YAML and are therefore not in the diagram.

Related