%%{init: {'flowchart': {'htmlLabels': false, 'useMaxWidth': false}}}%%
flowchart LR
    subgraph User["User machine"]
        B[Browser]
        KA[kc-agent]
        KC[kubeconfig]
        CFG[AI keys]
    end

    subgraph Console["Console deployment"]
        GB[Backend]
        POD[(Pod SA)]
    end

    subgraph Clusters["Managed clusters"]
        K8S[Kubernetes]
    end

    subgraph AI["AI (optional)"]
        PUB[Public LLM]
        LOCAL[Local LLM]
    end

    B --> GB
    B --> KA
    KA --> KC
    KA --> CFG
    KA --> K8S
    KA -.-> PUB
    KA -.-> LOCAL
    GB --> POD