Docs Menu
Docs Home
/

Predictive Maintenance Excellence with MongoDB Atlas

Transform equipment maintenance with AI-powered analytics that help predict failures, generate repair plans, and reduce downtime.

Use cases: App-Driven Analytics, Gen AI, IoT, Single View

Industries: Manufacturing & Mobility, Aerospace & Defense, Energy & Environmental

Products: MongoDB Atlas, MongoDB Atlas Charts, MongoDB Atlas Stream Processing, MongoDB Atlas Vector Search

Partners: Cohere, LangChain

Predictive maintenance solutions can allow organizations to achieve significant operational achievements, such as reducing downtime by 15-20%, increasing labor productivity by 5-20%, and cutting maintenance costs by 30-60%, according to Deloitte.

This solution uses MongoDB Atlas to build an end-to-end predictive maintenance system that helps manufacturers prevent equipment failures and optimize maintenance operations. The solution has four stages:

  1. Machine prioritization and criticality analysis: Uses ML and RAG-based analysis to determine equipment to prioritize for predictive maintenance.

  2. Failure prediction: Uses Atlas Stream Processing to process real-time sensor data and detect potential failures before they occur.

  3. Maintenance plan generation: Uses LLMs trained on maintenance manuals, inventory data, and resource information to automatically generate detailed work orders for failure situations.

  4. Maintenance guidance generation: Generates enhanced maintenance guidance and uses Change Streams to deliver instructions directly to technicians' mobile devices.

Predictive maintenance workflow stages

Figure 1. Four stages of predictive maintenance workflow

This section guides you through the architecture of each stage in this solution.

AI system diagram to prioritize machine maintenance

Figure 2. AI system diagram for machine prioritization recommendations

This stage uses RAG to determine which machines require predictive maintenance. The system processes two types of input data:

  • Structured data, such as production parameters and machine breakdown frequency.

  • Unstructured data, such as institutional knowledge stored in PDF documents.

The workflow aggregates and operationalizes both data types as vector embeddings in MongoDB Atlas, then uses Vector Search to semantically search the database. The results of the search provide relevant context to an LLM, via Amazon Bedrock or Cohere, which generates responses to prioritization queries. This helps maintenance teams make data-driven decisions about which machines need attention first.

Real-time sensor monitoring diagram

Figure 3. Real-time sensor monitoring with MongoDB Atlas

This stage processes real-time machine sensor data for failure prediction through six key stages:

  1. Data collection: A prioritized machine captures metrics such as product type, temperature, speed, and tool wear.

  2. Stream processing: The system transforms the raw sensor data.

  3. Data storage: The data is stored in MongoDB Atlas.

  4. Change detection: Change streams monitor the data for significant changes.

  5. ML inference: A trained model predicts potential failures.

  6. Dual output: Atlas Charts visualizes the data, and Change Streams enable mobile notifications.

Work order generator diagram with artificial intelligence

Figure 4. AI-powered work order generation system diagram

This stage automates maintenance work order creation through the following architecture:

  1. Document processing: The solution splits machine manuals and old work orders into chunks and converts them to vectors using Cohere embedding models.

  2. Vector storage: The solution stores embeddings in MongoDB Atlas.

  3. Work order generation: A specialized app uses LLMs to generate work order templates, pulls inventory and resource information through an aggregation pipeline, and creates detailed repair plans.

RAG workflow diagram

Figure 5. RAG workflow enhances technician repair instructions

This stage uses RAG to enhance operator instructions with the following architecture:

  1. Service note processing: Converts multilingual PDF service notes to text.

  2. Translation: Processes non-English content through translation models.

  3. Instruction generation: Uses LLMs to combine translated service notes with original repair plans.

  4. Delivery: Provides updated maintenance instructions to technicians through a mobile app.

For complete implementation details, including code samples, configuration files, and tutorial videos, visit this solution's GitHub repository.

This repository provides a production-ready template for implementing predictive maintenance. Follow the instructions in the repository's README, which guides you through the following steps.

1
  1. Configure your cluster, database, and collections for the stages in this solution's architecture.

  2. Set up MongoDB Atlas Search and Vector Search indexes for the repair_manuals and maintenance_history collections. Use the following document when setting up your search index.

    {
    "fields": [
    {
    "numDimensions": 1024,
    "path": "embeddings",
    "similarity": "euclidean",
    "type": "vector"
    }
    ]
    }
  3. Configure Atlas Stream Processing.

  4. Create Atlas Charts dashboards for monitoring and visualization.

2

Select one of the following services for your LLM implementation:

  • Amazon Bedrock: Configure access to Cohere models, such as cohere.embed-english-v3 or cohere.command-r-10, for embeddings and completions.

  • Direct API access: Integrate a third-party provider of your choice for embeddings and completions.

Additionally, set up Google Cloud Translation API for multilingual support.

3
  1. Configure your environment variables such as your MongoDB connection strings, database settings, and required API credentials.

  2. Deploy the inference script for continuous system monitoring.

  3. Install and configure the alerts application.

  4. Launch the main demo application.

  5. Perform system testing and validation to ensure proper data flow and functionality.

  • MongoDB's flexibility enables predictive maintenance: MongoDB Atlas combines structured sensor data and unstructured maintenance documents, providing both real-time monitoring and AI-powered analysis in one architecture.

  • MongoDB's features power end-to-end predictive systems: The solution integrates multiple MongoDB features, such as Atlas Stream Processing for real-time data, Vector Search for semantic analysis, and Change Streams for mobile alerts.

  • AI enables automation: This solution combines multiple AI technologies with MongoDB's developer data platform capabilities to create an automated maintenance workflow, from machine prioritization to mobile repair guidance delivery.

  • Dr. Humza Akhtar, MongoDB

  • Rami Pinto, MongoDB

  • Sebastian Rojas Arbulu, MongoDB

  • Multi-Agent AI Predictive Maintenance with MongoDB

  • Transforming the Driver Experience with MongoDB & Google Cloud

  • Framework for Rapid AI Agent Deployment

Back

Multi-Agent Predictive Maintenance

On this page