Skip to main content

kb — DevOps RAG Assistant CLI. Query docs, check clusters, manage infra.

Project description

── kb — Karabo ML CLI ──

kb is a polished CLI tool for DevOps RAG — query documentation, check cluster health, and manage your infrastructure, all from the terminal.

kb rag query "how to setup ArgoCD"
kb rag chat
kb drift check
kb cluster status
kb config show

Quick Start

pip install

pip install karabo-ml
kb --help

Docker

docker run --rm ghcr.io/dynamickarabo/karabo-ml kb --help

From source

git clone https://github.com/DynamicKarabo/karabo-ml.git
cd karabo-ml
pip install -e .
kb --help

Commands

kb rag query — Ask a DevOps question

kb rag query "How do I set up ArgoCD in a k3s cluster?"
kb rag query --top-k 10 --json "What is the best way to configure Prometheus?"

kb rag chat — Interactive mode

kb rag query
# or
kb rag chat
# Then type questions interactively. /exit to quit.

kb model serve — Start the RAG API

kb model serve                 # via docker-compose
kb model serve --build         # rebuild images first
kb model serve --profile ingest  # include ingestion
kb model stop                  # stop services

kb drift check — System health

kb drift check                 # API + Qdrant health
kb drift collections           # list Qdrant collections

kb cluster status — Cluster monitoring

kb cluster status              # Docker + k3s status
kb cluster status --json       # JSON output
kb cluster logs api            # view API logs
kb cluster logs qdrant --tail 200

kb config — Configuration

kb config init                 # create ~/.kb/config.yaml
kb config show                 # view current config
kb config edit                 # open in $EDITOR

kb completions — Shell completions

kb completions install bash    # add to ~/.bashrc
kb completions install zsh     # add to ~/.zshrc
kb completions bash            # print completions script

Configuration

Config loaded from (in priority order):

  1. ~/.kb/config.yaml (defaults)
  2. Environment variables (KB_API_URL, KB_QDRANT_URL, etc.)

Create your config:

kb config init

Example ~/.kb/config.yaml:

api:
  url: http://localhost:8000
  timeout: 30
qdrant:
  url: http://localhost:6333
  collection: devops_docs
logging:
  level: INFO
  file: ~/.kb/kb.log

Architecture

┌──────────┐     ┌──────────┐     ┌──────────┐
│  kb CLI  │────▶│ RAG API  │────▶│  Qdrant  │
│ (Python) │     │ (FastAPI)│     │(Vectors) │
└──────────┘     └────┬─────┘     └──────────┘
                      │
               ┌──────▼──────┐
               │  OpenRouter │
               │   (LLM)     │
               └─────────────┘

┌──────────┐     ┌──────────┐
│ Web UI   │────▶│ RAG API  │
│(HTMX+FA) │     │ (same)   │
└──────────┘     └──────────┘

Development

pip install -e ".[dev]"
ruff check src/
ruff format src/

Tech Stack

Layer Tool
CLI framework Click + Rich
HTTP client httpx
Config PyYAML + env vars
Backend API FastAPI + Qdrant
LLM OpenRouter (OpenAI-compatible)
Web UI FastAPI + HTMX + Jinja2
Container Docker multi-stage
Orchestration Docker Compose / k3s
CI/CD GitHub Actions
Distribution PyPI + GHCR

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

karabo_ml-0.2.0.tar.gz (12.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

karabo_ml-0.2.0-py3-none-any.whl (17.6 kB view details)

Uploaded Python 3

File details

Details for the file karabo_ml-0.2.0.tar.gz.

File metadata

  • Download URL: karabo_ml-0.2.0.tar.gz
  • Upload date:
  • Size: 12.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for karabo_ml-0.2.0.tar.gz
Algorithm Hash digest
SHA256 0ec54022cdbeea54bc6a3813e59f5c1bc3efca1d306cdab6f73489554891e95a
MD5 6788b579b9823f26748616470e8641e8
BLAKE2b-256 5058d90c04592300733273e3383c13a505085f73c60ca83cc2296a3a263778ca

See more details on using hashes here.

Provenance

The following attestation bundles were made for karabo_ml-0.2.0.tar.gz:

Publisher: publish-pypi.yml on DynamicKarabo/karabo-ml

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file karabo_ml-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: karabo_ml-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 17.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for karabo_ml-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 27512c7892d66578855e7f719c545491e6da429075f2547d1c9548f0b4dbd49c
MD5 8518cb7bc85f02df23d25dd53e62fa37
BLAKE2b-256 1be82c3ae01a1ebdb3578ed3c20efd40c8aa4cdba50e488e195cd6e119def46b

See more details on using hashes here.

Provenance

The following attestation bundles were made for karabo_ml-0.2.0-py3-none-any.whl:

Publisher: publish-pypi.yml on DynamicKarabo/karabo-ml

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page