Skip to main content

Environment Variable Configuration

PlantPulse AI configuration starts from a single /etc/kopens/plantpulse-ai.env file.

sudo vi /etc/kopens/plantpulse-ai.env
The authoritative configuration lives under /etc/kopens/

The path is /etc/kopens/plantpulse-ai.env. It is not inside the installation directory (/opt/kopens/plantpulse-ai-docker) but outside the repo tree, with permissions 0600. All three products — platform · ai · studio — use /etc/kopens/plantpulse-<product>.env under the same convention.

compose/.env is the old path. Nothing reads it any more, so editing it will not change the stack. Even if the old file is still present, after migration it serves only for comparison.

Do not edit passwords and API keys directly

For *_PASSWORD · *_API_KEY in the table below, editing the file alone does not complete the change. For values whose authoritative source is the server account — such as Neo4j — the server side must be changed as well, and getting the order wrong leaves authentication broken. Use the dedicated tool — Changing Passwords and API Keys.

After changing a value, the service must be recreated (docker restart does not re-read the env).

cd /opt/kopens/plantpulse-ai-docker
bin/restart.sh

PlantPulse IIoT Server Connection

Information about the PlantPulse IIoT platform server that PlantPulse AI integrates with.

VariableDescriptionDefault
PP_SERVER_HOSTPlantPulse IIoT server IP100.68.69.41
PP_SERVER_PORTServer port7443
PP_SERVER_SSLWhether SSL is usedtrue
PP_SERVER_USERNAMEAPI authentication userapi
PP_SERVER_PASSWORDAPI authentication passwordapi123!

System Paths

VariableDescriptionDefault
PP_MODEOperating modeMASTER
PP_HOMEHome directory/home/kopens
PP_DATA_DIRData storage path/data1/pp-data
PP_TEMP_DIRTemporary file path/data1/pp-temp
JAVA_HOMEJDK path$PP_HOME/tools/java/jdk-21

AI Inference Server

All AI services access the LLM through the LiteLLM proxy.

VariableDescriptionDefault
PI_INFERENCE_SERVER_BASE_URLLLM API endpointhttp://127.0.0.1:4000/v1
PI_INFERENCE_SERVER_API_KEYAPI keychange-at-install

Unified MCP (Platform)

MCP and ontology tools are provided by the PlantPulse Platform server-web unified MCP (/api/v5/mcp). Connection information is managed in web/config/application.properties of AI Chat Web.

ItemDescription
mcp.api.urlUnified MCP base URL (Platform server-web)
mcp.api.tokenapi_key authentication token
mcp.tools.enabledWhether unified MCP tools are used
info

With the 2026-07 revision, Langflow has been removed. Chat and agent orchestration are handled by the agent built into AI Chat Web, and the LLM is reached via the LiteLLM (inference server) described above.


RAG (LightRAG)

The RAG engine is the LightRAG 1.5.4 server. The items below are the LLM, embedding, and retrieval settings used by LightRAG, and are managed in the deployment environment (compose/env).

LLM Settings

VariableDescriptionDefault
LLM_MODELLLM model in usegpt-4o
VISION_MODELVision modelgpt-4o
LLM_TEMPERATUREGeneration temperature0.7
LLM_TOP_PTop-P sampling0.8
LLM_TIMEOUTLLM timeout (seconds)600

Embedding Settings

VariableDescriptionDefault
EMBED_MODELEmbedding modeltext-embedding-3-large
EMBED_DIMEmbedding dimensions2560
EMBED_MAX_TOKENSMaximum tokens8192

Reranker Settings

VariableDescriptionDefault
ENABLE_RERANKERReranker enabledtrue
RERANK_MODELRerank modelrerank-multilingual-v3.0
TOP_KNumber of final results returned5
RERANK_TOP_KNumber of rerank candidates10

Retrieval Settings

VariableDescriptionDefault
RAG_CONTEXT_MODEContext modechunk
RAG_MAX_CONTEXT_TOKENSMaximum context tokens3200
RAG_CONTEXT_FILTER_TYPESFilter typestext,image,table
ENABLE_MULTIMODALMultimodal enabledtrue
DOC_PARSERDocument parserdocling

Chunking Settings

VariableDescriptionDefault
CHUNK_SIZEChunk size512
CHUNK_OVERLAP_SIZEChunk overlap50

Databases

PostgreSQL

VariableDescriptionDefault
POSTGRES_HOSTHost127.0.0.1
POSTGRES_PORTPort5432
POSTGRES_MAX_CONNECTIONSMaximum connections12

Cassandra

VariableDescriptionDefault
TS_CASS_HOSTCassandra host192.168.0.41
TS_CASS_USERUsercassandra

Qdrant

VariableDescriptionDefault
QDRANT_URLQdrant URLhttp://127.0.0.1:6333
QDRANT_API_KEYAPI keyqdrant-key-123
QDRANT_DISTANCEDistance metricCosine

Neo4j

VariableDescriptionDefault
NEO4J_URINeo4j URIbolt://127.0.0.1:7687
NEO4J_USERNAMEUserneo4j
NEO4J_PASSWORDPasswordneo4j123

Valkey (Redis)

VariableDescriptionDefault
REDIS_URIRedis URIredis://:redis123@127.0.0.1:6379/0

MinIO

VariableDescriptionDefault
MINIO_ROOT_USERAdministrator IDminio
MINIO_ROOT_PASSWORDAdministrator passwordminio123!

TimeSeries

VariableDescriptionDefault
TS_CASS_HOSTCassandra host192.168.0.41
TS_PG_HOSTPostgreSQL host100.68.69.41
TS_PG_DBDatabasepp
TS_EMBED_URLEmbedding API URLhttp://127.0.0.1:4000/v1/embeddings
TS_EMBED_MODELEmbedding modeltext-embedding-3-large
TS_EMBED_DIMEmbedding dimensions2560

Ontology (Migrated to Unified MCP)

info

The ontology has been separated from its standalone service (formerly plantpulse-ontology) and absorbed into the platform unified MCP (server-web /api/v5/mcp). Since the DB↔Neo4j synchronization settings are managed in the platform server-web, the AI stack env.sh no longer contains ontology-specific variables. Neo4j continues to be used as the LightRAG graph store (see NEO4J_* above).


CUDA (GPU)

When using a GPU, uncomment and configure the following:

export CUDA_VISIBLE_DEVICES="0,1,2,3"
export CUDA_MANAGED_FORCE_DEVICE_ALLOC="1"
export PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True,max_split_size_mb:128
info

In environments without a GPU, the system automatically falls back to CPU mode. For the TimeSeries service, a CPU-only build is also possible with Dockerfile.cpu.