ArchitectureSystem Overview

System Overview

Skyflo is built from four main components: the Engine (Python, FastAPI, LangGraph), the MCP Server (FastMCP, typed tools), the Command Center (Next.js UI), and the Kubernetes Controller (Go operator). Each runs in your cluster and communicates over internal APIs.

Component Flow

User → Nginx Proxy → Command Center (chat UI) / Engine (FastAPI, SSE streaming) → MCP Server (tool execution) → Kubernetes cluster

An Nginx reverse proxy sidecar runs alongside the Command Center (ui service). It routes /api/v1/* requests to the Engine (port 8080) and all other traffic to the Command Center (port 3000). SSE streaming is supported with buffering disabled. The Engine streams responses via Server-Sent Events (SSE) and invokes the MCP Server (port 8888) for tool execution. The MCP Server runs kubectl and helm as async subprocesses and talks to Jenkins via httpx. The Kubernetes Controller manages Skyflo's own lifecycle via a CRD (SkyfloAI custom resource).

Internal Communication

  • Engine ↔ MCP Server: Streamable HTTP transport. Tool calls and results flow through typed MCP protocol.
  • Engine internal: Redis pub/sub for streaming events, PostgreSQL for persistence (conversations, messages, token usage).
  • Controller: Watches the SkyfloAI CRD and reconciles deployments, scaling, and configuration.

Tech Stack

LayerTechnologies
BackendPython 3.11+, FastAPI, LangGraph, LiteLLM, Tortoise ORM, Redis, PostgreSQL
MCPFastMCP, httpx, Pydantic, Streamable HTTP
FrontendNext.js 14, TypeScript, Tailwind CSS, Radix UI, Zustand
InfrastructureKubernetes, Argo Rollouts, Helm
CommunicationSSE, Redis pub/sub
SecurityJWT + refresh token rotation, RBAC, HttpOnly cookies

Component Details

  • Engine: LangGraph workflow, LLM orchestration, approval gates, SSE streaming
  • MCP Server: Typed tools for kubectl, Helm, Argo Rollouts, Jenkins
  • Command Center: Chat UI, real-time streaming, approval UI
  • Kubernetes Controller: CRD-based deployment and lifecycle management