How scottduncanai/industrial-ai-troubleshooting-agent works
This repository is a demonstration industrial troubleshooting assistant: users ask Claude Code questions, which it routes to an MCP server exposing historian, alarm, knowledge-graph, and document-search tools. The server records tool calls and reasoning for auditable investigations, with reports rendered from saved traces. README capabilities also include standalone MSPC and ML fault-detection analyses. Edges reflect the excerpts and explicit README descriptions; analysis command wiring and some data-store connections are not shown in sampled source, so those links are marked unverified or omitted.
Main entry points: historian_mcp_server.py MCP tool server · historian_tools.py Historian queries · boiler_historian.duckdb Time-series store · alarm_tools.py Alarm queries
Components 20
Assistant entry
- Claude Code
- MCP tool server
historian_mcp_server.py
Plant data
- Historian queries
historian_tools.py - Time-series store
boiler_historian.duckdb - Alarm queries
alarm_tools.py - Alarm event store
boiler_alarms.duckdb - Alarm definitions
alarm_metadata.py - Graph queries
kg_tools.py - Graph traversal
knowledge_graph.py - Equipment topology
boiler_kg.json - Document search
rag_tools.py - Plant documents
RAG docs - Tag metadata
tag_metadata.py
Investigation
- Trace capture
audit_trace.py - Audit reports
render_audit.py
Statistical analysis
- MSPC analysis
mspc_analysis.py - ML fault detection
ml_fault_detection.py
Visualization
- Process plots
plot_helpers.py - HMI styling
hmi_style.py
Other components
- Plant user
Connections 20
- Plant user → Claude Code: asks question
README.md - Claude Code → MCP tool server: calls tools
README.md - MCP tool server → Historian queries: routes queries
historian_mcp_server.py - MCP tool server → Alarm queries: routes queries
historian_mcp_server.py - MCP tool server → Graph queries: routes queries
historian_mcp_server.py - MCP tool server → Document search: routes searches
historian_mcp_server.py - MCP tool server → Trace capture: records calls
historian_mcp_server.py - Historian queries → Time-series store: reads data
- Alarm queries → Alarm event store: reads events
- Graph queries → Graph traversal: delegates traversal
kg_tools.py - Graph traversal → Equipment topology: loads topology
- Document search → Plant documents: retrieves passages
- Historian queries → Process plots: draws plots
historian_tools.py - Historian queries → HMI styling: applies styling
historian_tools.py - Process plots → HMI styling: uses palette
plot_helpers.py - Trace capture → Audit reports: renders trace
audit_trace.py - Plant user → MSPC analysis: requests analysis
- Plant user → ML fault detection: requests analysis
- MSPC analysis → Time-series store: analyzes readings
- ML fault detection → Time-series store: analyzes readings