Skip to main content
Welcome — this lesson explains the KAgent architecture, how its parts interact, and what each component is responsible for. KAgent brings together large language models (LLMs), a library of cloud-native tools, and an extensible framework so autonomous agents can plan, execute, and analyze operational tasks. At a high level, KAgent converts LLM reasoning into concrete actions by running autonomous agents that chain tool calls, inspect results, and produce actionable outputs. This makes KAgent well suited for DevOps automation, debugging, and observability workflows. Common use cases
  • Diagnose multi-hop connectivity problems across services
  • Troubleshoot application performance degradations
  • Automate alert generation from Prometheus metrics (Prometheus course)
  • Debug gateway and HTTPRoute configuration with a kgateway-specialized agent (kgateway course)
  • Orchestrate progressive rollouts using progressive deployment tools
KAgent’s architecture is organized into three high-level areas:
  • Tools: MCP-style functions agents call to interact with cloud-native systems. KAgent includes pre-built tools for progressive deployment, Kubernetes, and Helm.
  • Agents: Autonomous units that plan multi-step operations, invoke tools, and produce results.
  • Framework: A flexible runtime and control plane (built on the Google ADK) that exposes a UI, CLI, and declarative management for agents and tools.
A dark-themed slide featuring the "kagent" logo and the heading "Main Components." Below it are three labeled columns — Tools, Agents, and Framework — each with short bullet points describing features.
Runtime architecture — four core components Now let’s dig into the runtime architecture. You will typically see four main components: Controller, Engine (App), CLI, and Dashboard (kagent-ui). Each plays a specific role in managing and executing agents. Controller
  • KAgent’s controller is a Kubernetes-native controller implemented in Go.
  • It owns and reconciles the custom resource definitions (CRDs) that declare agents, tools, and their configurations.
  • Key responsibilities:
    • Manage agent lifecycle: create / update / delete agent resources.
    • Create and maintain Kubernetes resources required by agents (Jobs, Deployments, ConfigMaps, etc.).
    • Ensure cluster state converges to the declared resources.
  • Future extensions may include an MCP server for centralized tool management and distribution.
Engine (App)
  • The engine is the core execution runtime, implemented in Python.
  • It runs agent conversation loops, executes the agent’s plan-action cycles, and orchestrates tool invocations.
  • Built on the Google ADK, the engine leverages abstractions for agents, tools, and context propagation so ADK-compatible agents/tools interoperate with KAgent.
  • Because of ADK compatibility, you can bring existing ADK agents/tools into KAgent with minimal changes.
A dark-themed diagram titled "Component Details" showing boxes for Controller, App/Engine, CLI, and Dashboard (UI), plus a flow from "kagent" to "Kagent Engine" above a Python logo. Below that is an "ADK Framework" box.
Agent responsibilities (summary)
  • Run the agent conversation loop and manage agent state.
  • Produce plans, execute actions, and iterate based on tool outputs.
  • Invoke, monitor, and manage tool executions required to complete tasks.
  • Return structured responses to callers, the CLI, or the UI.
  • Be extensible by adding controllers, custom agents, or new tools through ADK integration.
A dark-themed slide titled "Component Details" showing four top-level components (Controller, App/Engine, CLI, Dashboard) and four info columns listing Responsibilities, Framework Foundation, ADK Framework Information, and Key Points with brief bullet items. The Responsibilities column notes things like running the conversation loop, executing agent logic, and managing tool calls.
CLI
  • The KAgent CLI provides a command-line entry point for the platform.
  • It connects to the engine to manage resources, invoke agents, and inspect runs programmatically.
  • Use cases:
    • Deploy and manage KAgent resources from CI/CD pipelines or scripts.
    • Invoke agents for ad-hoc troubleshooting and automation.
    • Integrate agent operations into automation tooling.
A presentation slide titled "Component Details" showing four component boxes (Controller, App/Engine, CLI — highlighted, Dashboard (UI)) and three panels below labeled Purpose, Use Case, and Key Points. The panels describe the CLI as a command-line alternative to the UI that connects to the engine, manages resources, and interacts with agents.
kagent-ui (Dashboard)
  • The kagent-ui dashboard is the web-based management and monitoring interface.
  • Provides visual onboarding, run histories, agent configuration views, and operational telemetry.
  • After installing KAgent in-cluster, you can port-forward the kagent-ui service to access the dashboard locally for management and debugging.
A dark-themed diagram titled "Component Details" with labeled boxes for Controller, App/Engine, CLI, and Dashboard (UI). Below, a "kagent Dashboard" feeds into a "Web Interface" that branches to "Manage" and "Work" boxes next to a small robot icon.
KAgent’s ADK foundation standardizes how agents, tools, and context are modeled. This interoperability allows you to run any ADK-compliant agent on KAgent with minimal adaptation — accelerating reuse across environments.
Component summary table
ComponentPrimary roleImplementationTypical responsibilities
ControllerDeclarative resource managementGo, Kubernetes-nativeManage CRDs, reconcile resources, lifecycle management
Engine (App)Agent execution runtimePython, Google ADKRun agent loops, orchestrate tools, propagate context
CLIScriptable access and automationCLI clientDeploy resources, trigger agents, integrate with CI/CD
kagent-uiVisual management & monitoringWeb dashboardOnboarding, run history, operational views
In summary, KAgent combines:
  • A Kubernetes-native Go controller for declarative resource management,
  • A Python-based engine built on the Google ADK to run agent logic and orchestrate tools,
  • A CLI for automation and scripting, and
  • A web dashboard (kagent-ui) for visual operation and monitoring.
This architecture enables flexible, extensible, LLM-driven automation for cloud-native operations and DevOps tasks. Links and references

Watch Video