Commands
Supported intents, what kprompt will not do, prompt examples, and useful flags in the shipped CLI.
Day-0 vs Advanced
kprompt --help groups Day-0 commands first (init, demo, doctor, config, contexts, version). Power surfaces (agent, setup, Team login, recipes, …) are under Advanced — also listed by kprompt advanced. Completion still includes Advanced command names.
| Day-0 | Advanced (examples) |
|---|---|
| init · demo · doctor · config · contexts · version | agent · setup · tools · history · recipe · login · run |
Capability map
kprompt is an intent compiler on an existing kubeconfig: plan → safety → approve → apply. It is not a cluster provisioner, cloud console, or silent remediator.
| Can do | Cannot / will not |
|---|---|
| Day-2 ops on a cluster you already reach (deploy, scale, explain, drift, …) | Create kind / EKS / GKE / AKS clusters (“bana bir cluster kur” → unknown intent) |
| Optional Team /run via kprompt run listen on your laptop | Hold kubeconfig in the control plane or browse the live cluster from the app alone |
| Observe agent: watch → Incident → gated alert / propose-only Autopilot | Silent apply from the agent (Autopilot apply stays gated) |
| BYOK or local Ollama for NL plans | Sell or host LLM API keys as a kprompt product |
Need a disposable cluster first? Run kprompt demo, or kind / kprompt-examples make up, then point kubectl / kprompt at that context. App bridge: App runs & CLI bridge. Observe demo: Observe agent.
Supported intents
| Intent | Examples | Notes |
|---|---|---|
| deploy | "deploy redis" | Deployment ± Service shortcuts |
| scale | "scale api to 10" | Deployment replicas |
| rollback | "rollback payment-api" | Rollout undo |
| delete | "delete deployment redis" | Named Pod/Deployment/Service only |
| get / list | "list deployments" | Read-only; built-ins + discoverable CRDs |
| explain | "explain why api is crashing" | Deployment → ReplicaSet → Pods → Events → Logs; may suggest patch |
| investigate / why / timeline | "investigate checkout" | Multi-hop RCA / causal why / event timeline |
| drift | "check cluster drift" | Read-only GitOps sync/health vs live (RiskLow) |
| learn | "learn my cluster" | Detect tools; save local profile (RiskLow) |
| audit / cleanup / search / score | "score my cluster" | Hygiene, orphans, inventory search, scorecard |
| logs | "logs payment-api" | Tail |
| describe | "describe payment-api" | Compact describe |
| Helm install / upgrade | "install redis" | Template and dry-run preview before approval |
| workflow | "train a yolov11 model" | Argo Workflow generate/submit/status/--wait |
| performance | "why is my api slow?" | Read-only Prometheus-backed diagnosis |
| trace | "trace payment request" | Jaeger/Tempo span tree + bottlenecks |
| dashboard | "show payments dashboard" | Grafana search + panel summary |
| optimize | "optimize my cluster" | Read-only idle / rightsizing / HPA hints |
| graph | "show service dependency graph" | Service graph (+ optional OTel edges) |
| GitOps | "show gitops sync status" | Flux/Argo CD health; approved sync |
| Tekton | "run the build pipeline" | PipelineRun generate/submit/status |
| KEDA | "autoscale api with KEDA" | ScaledObject generate/submit/status |
| Istio | "show traffic for checkout" | VirtualService traffic summary (read-first) |
| Crossplane | "provision a postgres database" | Cloud claims; RiskHigh + strong approval |
| route | "why is api slow then scale api to 4" | Multi-tool chain; one aggregate approval |
Day-2 reads (CLI docs)
Deeper guides live in the product repo: investigate, why, timeline, impact, audit, cleanup, search, score, architecture, learn, drift, watch, remember, session, recipes.
Prompt examples
# Kubernetes day-2
kprompt "list deployments"
kprompt "how many nodes are in the cluster"
kprompt "scale api to 3" -n staging
kprompt "rollback payment-api" --approve --wait
kprompt "explain why redis is crashing"
kprompt "check cluster drift"
kprompt "learn my cluster"
# Observability
kprompt "why is my api slow?" -n production
kprompt "trace payment request"
kprompt "show dashboard"
# North-star reports
kprompt "optimize my cluster"
kprompt "show service dependency graph"
# Ecosystem
kprompt "install redis" -n cache
kprompt "show gitops sync status"
kprompt "provision a postgres database"
# Multi-tool route (one plan, one approval for mutating chains)
kprompt "why is api slow then scale api to 4"
# Not supported — provision a new cluster elsewhere first
# kprompt "create a kind cluster" → unknown intentFlags
| Flag | Description |
|---|---|
| --approve | Apply without interactive confirmation (primary CI flag; also history clear) |
| --wait | After apply, wait for Deployment rollout or Workflow/PipelineRun terminal phase |
| --timeout | Timeout for --wait (default 5m) |
| --output / -o | text (default) or json (PlanResult) |
| --theme | auto, dracula, nord, gruvbox, mono, or none |
| --provider | LLM provider id |
| --model | Model id |
| --context | kubeconfig context |
| --contexts | comma-separated contexts for read fan-out / per-context mutate (aliases ok) |
| --approve-each-context | Apply a mutating plan to every --contexts entry (explicit; not implied by --approve) |
| -n / --namespace | Namespace (wins over prompt phrases) |
| --open | With login: open the browser for device approval |
Interactive confirms use Apply …? [y/N]. Full vocabulary (including rare phrase gates): see CLI docs/approval.md on GitHub.
Subcommands
- kprompt init / demo / doctor / advanced
- kprompt config / config set … / config alias set|unset
- kprompt contexts / contexts --check / contexts --json
- kprompt history / history rerun [n] / history clear [--approve]
- kprompt tools
- kprompt setup — dry-run / approve-gated host+cluster bootstrap (see Setup docs)
- kprompt doctor
- kprompt learn — detect cluster tools, save local profile
- kprompt agent run / agent list — Observe bridge on laptop or fleet inventory
- kprompt run listen — Team app /run CLI bridge
- kprompt dash — local read-only cluster UI (requires kprompt-dash on PATH; not a Lens replacement)
- kprompt login / login --open / logout / whoami
- kprompt policy / policy pull
- kprompt secrets pull
- kprompt version
Bootstrap honesty (what setup installs / does not): Setup bootstrap. Team bridge: App runs & CLI bridge.
Context aliases
Map short names to kubeconfig contexts. Optional require_alias_match refuses mutating apply when kubectl’s current-context does not match the resolved target (wrong-cluster guard). Inventory: kprompt contexts. Read fan-out: --contexts or “across staging and prod” (get/list/explain/logs/describe/optimize). Multi-context mutate asks per context; plain --approve is refused — use interactive confirms or --approve-each-context. PlanResult includes cluster_context on the document and each action; fleet optimize adds fleetSummary.
kprompt config alias set prod gke_myproj_us-central1_prod
kprompt config alias set staging kind-staging
kprompt contexts
kprompt --contexts staging,prod "list deployments"
kprompt --contexts staging,prod "optimize my cluster"
kprompt "list pods across staging and prod"
kprompt --contexts staging,prod "scale api to 3"
kprompt --contexts staging,prod --approve-each-context "scale api to 3"
kprompt --context prod "list deployments"
kprompt config set require_alias_match trueFor the local dash quickstart and security defaults, see the Local cluster dash docs. Full multi-context honesty (what is / is not): Multi-cluster.