ML Classifier Deployment Guide
The KloudMate ML Classifier is an AI-powered data security module that natively integrates with your telemetry pipeline. By leveraging advanced Machine Learning engines alongside pattern-matching rules, it automatically inspects database queries in real-time to meticulously detect sensitive information, such as PII (Personally Identifiable Information) and PHI (Protected Health Information). It then dynamically enriches your traces with risk fingerprints before your telemetry ever leaves your infrastructure.
This guide covers two strategies for deploying the KloudMate ML Classifier:
- Standalone deployment via Docker Compose on a simple machine.
- Enterprise deployment via Kubernetes (K8s).
Strategy 1: Standalone Machine via Docker Compose
Section titled “Strategy 1: Standalone Machine via Docker Compose”Prerequisites
Section titled “Prerequisites”- Docker Engine and Docker Compose are installed.
- The
KloudMate Agentis running on the host machine, listening to OTLP HTTP traffic on port4318.
Prepare the Compose File
Section titled “Prepare the Compose File”Create a docker-compose.yaml file on your machine. It is configured to run the classifier with optimized CPU/Memory limits to handle the ML NLP models.
If you need the ML Classifier to reach out to the KloudMate Agent running directly on the host machine, Docker uses the special DNS host.docker.internal to route traffic to the host.
docker-compose.yaml
Start the Classifier
Section titled “Start the Classifier”Navigate to the directory containing docker-compose.yaml and run:
Configure KloudMate Agent
Section titled “Configure KloudMate Agent”Update your host Agent’s configuration to route traces to the classifier container. Since the classifier exposes port 8080 to the host:
Strategy 2: Enterprise Cluster via Kubernetes
Section titled “Strategy 2: Enterprise Cluster via Kubernetes”Prerequisites
Section titled “Prerequisites”- Active Kubernetes cluster with
kubectlaccess. - Helm or standard K8s networking setup.
Deploy the Configuration
Section titled “Deploy the Configuration”The classifier relies on a ConfigMap (configmap.yaml) to define the Presidio patterns and GLiNER labels.
Deploy the Service & Application
Section titled “Deploy the Service & Application”Apply the Kubernetes service and deployment manifests. The deployment automatically allocates 4Gi of memory and spins up 2 HTTP workers for concurrent classification.
service.yaml
deployment.yaml
Verify Deployment
Section titled “Verify Deployment”Verify that the pod has started properly and the GLiNER models have been downloaded into memory.
Configure KloudMate Agent in K8s
Section titled “Configure KloudMate Agent in K8s”In your KloudMate Agent’s config (if deployed as a separate pod in the same namespace), configure the processor to hit the fully qualified internal DNS of the service we just created.
otel-collector-config.yaml
Verifying Classification is Working
Section titled “Verifying Classification is Working”Regardless of the deployment strategy, you can verify the setup by observing the KloudMate Agent logs (ensure level: debug is enabled temporarily). The traced applications will start showing dam.lineage.fingerprint, dam.lineage.risk, and extracted PII/PHI properties dynamically added to the payload before arriving at your backend.