Architecture
The services on the edge PC, how data flows through them, and what stays vendor-neutral.
BooleX runs on one edge PC that the site provides, in its own network zone beside the control system. It is a set of containers started with Docker Compose (deploy/compose.yaml).
Services
| Service | Role | Compose profile |
|---|---|---|
db | Postgres: the platform store (code model, documents, work orders, process data, alarm history, audit trail, search index) | always |
migrate | Applies the store's schema and database roles at start-up | always |
ingest | Reads live values and alarms from the plant through read-only adapters (OPC UA, Modbus TCP, MQTT Sparkplug B, BACnet/IP, SNMPv3, DNP3, IEC 61850) and writes them to the store | always (site), bench adds the simulator |
assistant | The Web UI and API, diagnosis, the evidence card, sequence of events, workflows, early warnings | always |
backup | Daily backup of the configuration and the store to site storage | always |
llm | A local language-model server on the internal network, never published | ollama |
watch | Reads a read-only site share in place: indexes new and changed documents without copying them, imports code exports | watch |
cmms | Reads work orders from the site CMMS through a read-only account | cmms |
model-runner | Runs site FMU models with no network, a read-only root, 1 CPU and 512 MB | fmi |
sim, import-code, replay | The bench simulator and demo tooling | bench, replay |
Only the assistant publishes a port (8080/TCP, HTTPS outside development). Every service restarts on exit.
How an answer is made
- Data arrives: live values and alarms through
ingest(or from the site historian, or as imported files); code exports, documents, work orders and parts through the importers. - Code from every vendor is translated into one common code model: programs, rungs and networks, tags, alarms, interlocks and their cause chains. The assistant reasons only over this model and the historian interface, never over a vendor format or a specific database.
- A question, or a stop, starts a diagnostic session. The assistant runs read-only tools (cause chain, sequence of events, trend, documents, work orders, parts, model replay) and builds the evidence card without a language model.
- The language model, behind the provider interface, writes the answer from the tool results. Every statement is checked against its cited sources before it is shown; a statement without a source is dropped.
Language models
The model is configured in deploy/config/llm.json and reached only through the provider interface. In the production and offline-import profiles it must run on the edge PC or the plant network; a cloud model is refused at start-up. See Deployment profiles.
Focused agents (experimental, off by default). With "agents": true in llm.json, a Lead investigator hands each question's sub-questions to specialists by expertise: Process, Control logic, Drawings and documents, Maintenance and, where validated models are on, Behavioural models. One model plays every role; each specialist is offered only its own tools, and every claim it passes back must cite a source the tools returned. Rules choose the first specialists; when none match, the Lead plans with one short model call, and an unclear plan falls back to the normal answer with all tools. Up to challenge_rounds rounds (2 by default) let the specialists dispute each other's claims. Each question is limited to 6 investigation tasks, with the challenge rounds on top, and to agents_time_budget_s seconds of specialist work (20 by default, at most 120). The answer format and every check stay the same, and the audit trail records every task and finding. candidates_shown (3 by default) sets how many causes are shown in full and two_pass turns on the two-pass answer for any model. Leave the agents off until the benchmark shows they help your model.
Where things are kept
| What | Where |
|---|---|
| Site configuration | site.yaml and the tag, alarm and interlock lists in the site's plant folder; deploy/config/ (profile, users, directory, model, integration accounts, TLS) |
| Secrets | deploy/secrets/ (database passwords, demo password, uplink token), files only |
| Plant data, documents, audit trail | The Postgres store (db volume); the audit trail is append-only |
| Feedback, journal, photos | The assistant's data volume |
| Backups | The site storage mounted at BOOLE_BACKUP_DIR |