Skip to main content
The dynamic-classifier service trains and runs the machine-learning models behind Document Classifiers. Integration Designer calls it in two ways:
  • Over REST, to classify document pages when a workflow runs a Document Classifier.
  • Over Kafka, to train a model version and to pre-label pages uploaded without labels. The pre-labeling uses an LLM judge.

Dependencies

  • Kafka: training and judge jobs from Integration Designer
  • PostgreSQL: job store for those jobs (see Job store)
  • S3-compatible storage (MinIO or AWS S3): trained model versions (see Object storage)
  • A persistent volume: 20Gi ReadWriteOnce, for the service’s own data and model cache (see Persistent volume)
  • organization-manager: resolves the model and credentials for the judge from the organization’s EVAL capability in AI providers

Turn on the service

dynamic-classifier is in the runtime group of the flowx-ai Helm chart. To deploy it, set groups.runtime.enabled: true. The runtime group also needs the AI base, so set groups.base.enabled: true as well. See Service groups for the valid group combinations.

Configuration

The chart sets every variable this section needs from its values. The tables list the variables so you can check a running pod or override a value.

Persistent volume

The chart creates the PersistentVolumeClaim dynamic-classifier-data (20Gi, ReadWriteOnce) and mounts it in three places: Your cluster needs a storage class that can provision this claim. Because the volume is ReadWriteOnce and the service keeps its database on it, run one replica and keep GUNICORN_WORKERS at 1. The deployment uses the Recreate strategy, so an upgrade stops the old pod before the new one starts.

Job store (PostgreSQL)

Integration Designer’s training and judge jobs run through a durable job queue that keeps each job’s state in PostgreSQL. Create the dynamic_classifier database and the dynamic_classifier user before you deploy: the chart connects to the database but doesn’t create it. The chart reads the password from the flowx-postgres-dynamic-classifier secret, key password.
If POSTGRES_PASSWORD is not set (and POSTGRES_DSN is not used), the job consumer fails at startup with a postgres_dsn is required error.

Object storage

When Integration Designer trains a model version, the service uploads it to object storage as a zip, under dynamic-classifier/artifacts/ in the bucket. Set the bucket in services.dynamic-classifier.component.s3.applicationFileStorage.bucketName. The chart ships it empty.
Training a Document Classifier from FlowX needs the bucket. If APPLICATION_FILE_STORAGE_S3_BUCKET_NAME is empty, every training job fails after the model is built, with an artifact store disabled error. Importing a model still works without the bucket: the imported version stays on the persistent volume only.
The chart takes the access key from global.flowx.s3.credentials.dynamicClassifier.accessKey (default flowx-dynamic-classifier-accesskey) and the secret key from the flowx-dynamic-classifier-s3 secret, key SecretAccessKey.

Kafka configuration

The chart sets TRAINING_QUEUE to kafka, which starts the job consumer for Integration Designer’s training and judge jobs. With any other value, the consumer doesn’t start and Integration Designer’s jobs are never picked up. Create the topics before you deploy the service if your Kafka cluster doesn’t create topics automatically. For the shared Kafka connection settings, see Kafka in AI Platform setup.

LLM judge

Judge jobs from Integration Designer use the model bound to the organization’s EVAL capability. To change it, assign EVAL to another model in Settings → AI Providers → Models. If the organization has no EVAL model, judge jobs fail. The service can also call an OpenAI model directly for its own judge and label refinement calls. The chart reads that key from the dynamic-classifier-openai secret, key OPENAI_API_KEY. The secret is optional: without it, the service skips those calls and classification keeps working.

Text encoder model and egress

The first time the service needs its text encoder (prithivida/Splade_PP_en_v1), it downloads the model from Hugging Face and caches it on the persistent volume, under /tmp/fastembed_cache. Later restarts reuse the cached copy.
Air-gapped environments must allow the Hugging Face download once, or copy the model into the fastembed subpath of the volume before the first training or classification.

Server configuration

The API listens on port 8080. The port isn’t configurable.

Integration Designer connection

Integration Designer reaches the service through the chart’s dynamic-classifier Service (port 80). Change these Integration Designer variables only if you expose the service under another name:

Verify your setup

The pod is running: kubectl get pods -l app.kubernetes.io/component=dynamic-classifier
The volume claim is bound: kubectl get pvc dynamic-classifier-data
The health endpoint returns HTTP 200: curl http://dynamic-classifier-mngt:8081/manage/actuator/health
Training works end to end: train a Document Classifier version in FlowX and check that it finishes, then look for its zip under dynamic-classifier/artifacts/ in the bucket

Troubleshooting

Symptoms: The pod never starts and kubectl describe pod shows an unbound volume claim.Solutions:
  • Check that a storage class can provision a 20Gi ReadWriteOnce claim for dynamic-classifier-data
  • If you scaled the deployment above one replica, scale it back to one: a second pod can’t mount the same ReadWriteOnce volume on another node
Symptoms: A training job fails and the pod logs show artifact store disabled (APPLICATION_FILE_STORAGE_S3_BUCKET_NAME unset).Solutions:
  • Set services.dynamic-classifier.component.s3.applicationFileStorage.bucketName and redeploy (see Object storage)
  • Check that the bucket exists and the access key can write to it
Symptoms: Integration Designer sends jobs, but the service never answers.Solutions:
  • Check that TRAINING_QUEUE is kafka on the pod
  • Check that the three job topics exist and the service can consume the request topic
  • Check that the job store connection works: the logs show postgres_dsn is required when the password is missing
  • Review the pod logs for Kafka connection or authentication errors
Symptoms: Pages uploaded without labels aren’t pre-labeled, and the logs show No EVAL llm-config capability configured for this organization.Solutions:
  • Assign a model to the EVAL capability in Settings → AI Providers → Models for the organization
Symptoms: The logs show a failed model download for prithivida/Splade_PP_en_v1.Solutions:

Document classifiers

Train or import models and use them in workflows

AI Platform setup

Deploy the AI Platform services and their shared configuration

Integration Designer setup

Configure Integration Designer, which sends the classification and training requests

Configure the flowx-ai Helm chart

Point the chart at your PostgreSQL, S3, and Kafka
Last modified on November 26, 2026