Problem
A small manufacturer with one production line wants a digital twin that reads its sensors and cameras and flags problems, but cannot pay programmers to write one. The authors replace that work with a dialogue: the owner describes the object, and LLM agents produce a working twin. The hard part is checking that the generated JSON configuration and code are valid when there is no single correct answer to compare against.
Example from the article: a conveyor carries freshly quenched bottles past a temperature sensor and a camera. The twin must check that the bottles have the expected temperature, cool at the expected rate and are not visibly broken.
Solution in brief
Four LLM agents build the twin in a chain: requirements chat with JSON output, check against sensor documentation, database schema, twin code. JSON is scored by string similarity plus an LLM judge, code by human assessors against DeepSeek. The finished twin finds anomalies with two unsupervised algorithms, one for cameras and one for sensors.
Questions this case answers
- How to build a monitoring system from a non-expert's dialogue with a chain of narrow LLM agents that produce validated configuration, schema and code
- How to evaluate LLM-generated structured configurations and code when string similarity penalizes valid alternatives and no single correct answer exists
- How to let a small manufacturer get a working digital twin of a production line without hiring programmers
- How to build a multi-agent LLM pipeline that turns a chat with a user into a validated JSON configuration, a database schema and twin code
Tools and methods
- SmolLM3-3B, StructSQL (4B), Qwen Coder (30B) — interaction, database and code agents.
- LLM-as-a-judge and Structural Similarity Score — two metrics for the generated JSON.
- Assessor evaluation — students rate the code on a 1–5 scale.
- CKAAD and M2ADTFT — unsupervised anomaly detection for camera frames and sensors.
Google or a one-time email code. No password.
