DEV Community

Memona
Memona

Posted on

How AI, ML, IoT, Blockchain, and RPA Can Work Together

What happens when a physical machine emits data, an ML model finds an anomaly, automated workflow reacts to it, and a trusted record needs to be shared between enterprises?

How can IoT, AI, Machine Learning, RPA, and Blockchain can complement to each other?

Let me try to imagine it as a flow:

Physical Devices → IoT → Data → AI/ML → Decision → Automation → Action

Blockchain can be utilized in such a system if trustworthy and verifiable records are required by one or more parties, The main engineering question at this point is not “How can we use all technologies together?”
but rather “Which technology addresses which problem?”

1. IoT: Collecting Data from the Physical World

Internet of Things connects physical devices and machinery to the software systems. For example, a manufacturing setting can generate a number of relevant signals:

  • Temperature
  • Vibration
  • Device state
  • Power consumption
  • Location
  • Production data

A typical technical stack for IoT can look like:
Sensors
↓
IoT Gateway
↓
Data Platform
↓
Analytics / AI / ML

IoT provides information about the physical world.
That’s why AIoT (AI + IoT) is sometimes a synonym for this stage.
AI/ML can be used for analyzing this data and, therefore, addressing use cases such as predictive maintenance, quality inspection, demand planning, equipment monitoring, etc.

However, it’s important to note that ML is only as good as the data and the model.

2. AI and ML: Interpreting and Finding Value in Data

Once data is ingested into the system, AI/ML can be leveraged to extract value from it. For example, a machine learning model can learn the patterns of a physical device’s behavior and spot anomalies in real time.
This is how an ML powered predictive maintenance can be built:

Sensor Data
↓
Data Processing
↓
ML Model
↓
Pattern / Anomaly Detection
↓
Decision Support

Such a model can be utilized in use cases like predictive maintenance, quality inspection, etc. However, a machine learning model is only one part of a solution: it requires data preparation, feature engineering, training, validation, and testing.

It’s also important to remember that poor quality of input data and/or an incorrectly chosen model will result in mediocre performance.

3. RPA: Automating the Digital Workflow

Robotic Process Automation is a set of tools that allows you to automate rule-based digital processes. For example, an RPA robot can be utilized to perform certain actions in an enterprise application when instructed to do so.

In this scenario, the robot is essentially an automation engine that executes a series of defined steps.
A typical RPA-driven digital workflow looks like:

AI/ML Insight
↓
Business Rule
↓
RPA Workflow
↓
System Update
↓
Notification / Report

In other words, RPA is about executing defined digital tasks.
It is not the same as AI/ML: the latter is usually used for data analysis and decision support, while the former takes these decisions and executes them in digital systems.

For physical processes, other automation tools may have to be used.

4. Blockchain: Making Important Events Immutable

Blockchain is different in that it serves a different purpose: it allows you to build a shared source of truth about important events. For example, a supply chain involves many manufacturers, suppliers, and logistics companies.

Sometimes, certain events should be captured and verified by multiple stakeholders.

A blockchain layer would look like:

Business Event
↓
Validation
↓
Blockchain Record
↓
Shared Verification

However, you should always remember that a traditional database is often a better solution than a blockchain. Whenever performance, flexibility, and fine-grained access control are important, a standard database management system will be a better fit. A similar consideration applies to using blockchain: use it when you need it.

There are cases when a shared source of truth and verification is required by multiple independent parties.

In such situations, a blockchain can be worth considering.

Putting Everything Together

Here’s how all of the above can be combined in a connected manufacturing system:

Physical Equipment
↓
Iot Sensors
↓
Data Platform
↓
AI / ML
↓
Decision / Recommendation
↓
Automation / RPA
↓
Action

Here’s how a blockchain can be added to this system:
Physical → IoT → Data → AI/ML → Decision → Automation → Action
↑ ↓
Blockchain: Trusted Record
Keep in mind that this is a very simplified view: there are more steps and supporting systems such as data governance, data quality management, API gateways, edge processing, etc.

The above is just one possible way of building a connected system.

What Should You Implement First?

When you start working on a project, you should never focus on technologies.
Focus on your problem domain first.
Here’s an example:

Step 1: What Is the Use Case?
Let’s imagine that the use case is to avoid unplanned equipment downtime.

Step 2: What Data Do We Need?
We probably want to collect data about temperature, vibration, machine age, state, maintenance history, etc.

Step 3: Let’s Build a Pipeline
We need to make sure that the relevant equipment is connected and monitored.

This could be a very simple pipeline:

Sensors
↓
Gateway
↓
Message Broker
↓
Data Storage
↓
Processing

Depending on requirements and data volume, some processing can be done on the server or at the edge.

Step 4: Let’s Add Some Intelligence
Once you have enough data, you can think about how you can utilize it.
You can process it to gain some operational insights or apply machine learning to find patterns and anomalies.
Make sure that you have a meaningful use case: do not build an ML model just because you can.

Step 5: Turning Insights into Action
Whenever an interesting finding emerges, you will likely want to do something about it.
If the response is deterministic, you can utilize RPA to automate it.
For example:

Anomaly Detected
↓
Maintenance Threshold
↓
Create Work Order
↓
Notify Team

Such a process can be fully automated or involve manual steps whenever the decision has to be made or a human has to review the finding.

Step 6: Do We Need Blockchain?
If there is a need for several independent parties to have access to the same information and verify certain events, you can think about adding a blockchain layer. This may not always be the case: if no such requirement exists, you can skip this step.

Where Does AIoT Fit In?

AI + IoT is often referred to as AIoT.
This concept can be seen as yet another stage in the system:

IoT: What is happening in the physical world?
AI/ML: What does the data mean?
Automation: What should a digital system do?
**Physical Systems: **What should happen in the physical world?

This fits into the larger system as a “loop”:
Sense → Identify → Decide → Act
The decision can be automated (e.g., turn a machine off) or may require human intervention.
This approach fits into manufacturing settings with interconnected, smart equipment that seeks to sense, identify, decide, and act in order to fulfill a larger use case.(https://apertureventurestudio.com/)

Final Notes

When you look at the above, it becomes obvious that the single biggest mistake is to try to apply the technologies in isolation.

The worst approach is to think something along the lines of “We need IoT, AI, blockchain, and RPA because they are cool technologies.”

Instead, you should always design your system around the problem that you have to solve.

You should answer questions such as:

  • What are we trying to achieve?
  • What data do we need to acquire?
  • Where can we get this data?
  • Where will we process it?
  • What analysis do we have to perform?
  • What decisions can be automated?
  • Where do we need humans?
  • Do we need blockchain?
  • What about scalability and security?

The resulting architecture may involve all of the above or may not involve any of these technologies, it all depends on your use case.
Good engineering is not about adding technologies: it is about choosing the right technologies to address the problem at hand.

Top comments (0)