On Understanding Mutually Beneficial Collaborations between Blockchains and AIs with Dr Praphul Chandra — Founder, KoinEarth, at Genesis DevCon
When it comes to coupling emerging technologies, blockchain and artificial intelligence (AIs) make the proverbial “swipe-right” match made in Tinder heaven…for technologies. However, there’s more to it than just a whimsical pop-cultural reference made to dating apps. The creation of applications based on the blockchain and AI combo can accomplish several spectacular things in today’s data-centric age.
On that note, Dr Praphul Chandra joined us at Genesis DevCon to render an insightful tech talk on using blockchains and AIs to build better tech infrastructures and the opportunities and challenges involved thereof.
Before we delve into the details of the tech talk, let’s get to know our speaker.
Getting to Know Dr Praphul Chandra
Praphul Chandra — Founder & Chief Scientist, KoineArth, is a scholar with a remarkable understanding of blockchain technology, artificial intelligence (AI) and machine learning. He established Koinearth — a startup working at the intersection of blockchains, machine learning and mechanism design. Prior to KoinEarth, he worked for 11 years at HP in several research roles and as the Principal Data Scientist. He has a penchant for learning and sharing his knowledge with the world which brought him to join us at Genesis DevCon.
Given that Blockchain and AIs are technologies that have the potential to streamline data management based on cognitive learning, Dr Chandra shared an elaborate account on how these two technologies can be brought together.
Understanding the Value Proposition of Blockchains and the Multi-entity Networks Within Them
We all know that blockchains are decentralised ledgers that can provide immutability, accountability, and transparency to technological infrastructures. However, to truly understand what they represent, we need to know their value proposition. Therefore, blockchains allow us to achieve the following things:
- Formation of a multi-entity network, where each entity (node) maintains its own copy of the ledger
- The synchronisation of the ledgers is taken care of by the underlying technology. — A synchronised multi-party network.
- Creation of an auditable synchronised network — any information/transactions recorded on the network is non-repudiation and immutability, creating accountability.
- The enforcement of contracts.
The term smart contracts is a misnomer. In terms of ML and AI, there is nothing “smart” about smart contracts. A more accurate term would be an auto-enforcing contract. Once the terms of a contract are written in a certain programming language, it is guaranteed to execute whatever is in it without the intervention of any single party. This is what a contract enforcing auditable synchronised network represents.
Contract enforcing ledgers can go a step ahead of this. On assuming that you have cryptocurrencies, parties can automate payments based on the completion of these terms and conditions. However, this comes with a fork in the road.
In unfriendly-crypto regulations, when the terms of the contract have been enforced and we can balance account payables and account receivables. In crypto-friendly regulations, you can go ahead and balance the payments within the ledger because the contract controls the currency.
Given that these are the points of value derived from blockchains, they are effectively derived by the entities in a blockchain. In a public blockchain, the entities are individual people or nodes. In a B2B permission blockchain network, the entities are enterprises, regulatory parties like governments would be entities.
However, with reference to context, can an AI agent (an AI algorithm) be an entity in a blockchain network and what does that enable? To begin to understand this, Dr Chandra clarified what AIs really are.
What is Artificial Intelligence (AI)?
No matter how straightforward it seems, AI has several interpretations. Science fiction has depicted several effigies of AIs from H.A.L 9000 in Stanley Kubrik’s 2001: A Space Odyssey to Iron Man’s Jarvis in the Marvel Cinematic Universe. All these AIs demonstrate machine intelligence resembling the natural intelligence that humans show to aid in processing real-time data to provide solutions in life-threatening circumstances.
However, in the realm of computer science, AI’s have a wider range of specificities functions. An AI perceives its environment and carries out certain functions to create a certain impact or achieve a certain outcome, mimicking certain cognitive functions based on the human mind to “learn” and “solve problems”.
Banking on these perceptions, Dr Chandra delved deeper into the subject of AIs. Broadly speaking, there are three types of AI algorithms out there:
Supervised learning
Dr Chandra illustrated this with an example. Imagine that there is a spread with several fruits — apples, oranges, bananas, etc. You have identified the fruits as apples, oranges, and bananas. When you teach the same to a machine — that is, if you share an image of an apple to the machine and call it an apple, the machine imbibes this data via supervised learning. Supervised learning helps a machine learn from historical (label) data to identify the said fruit in the image as an apple.
Unsupervised Learning Algorithms
Let’s consider Dr Chandra’s spread of fruits again — the apples, oranges, bananas. This time, however, when the machine receives images of these fruits, it is not told how to identify the fruit with its corresponding name. In such a case, the machine will relate the image of the fruit to another familiar image and term it as the same.
Reinforcement Learning Algorithms
In this case, when you give the machine a bunch of images of these fruits, the machine doesn’t know what they are or how to identify them, except it derives value from them. For example, from the image of one of the fruits, the machine would identify that (for example) this fruit is good for consumption. It works on a value-action paradigm.
AIs as Oracles for Smart Contracts
A smart contract is fundamentally a piece of code which automates the payment between multiple entities as per the terms programmed in it. If you have given the authority of transferring payments to a piece of code between different entities, that piece of code holds a vital responsibility of distinguishing the amount of money that needs to be transferred in a certain circumstance from one party to another. In the blockchain literature, such an entity that informs a smart contract with data from the real world, helping it make decisions on when to transfer value and when not to transfer value is called an oracle. One of the most significant value propositions of AIs is to act as oracles to smart contracts.
Let’s take a look at some real-world examples — consider an insurance policy for crops based on a smart contract. This is a contract between two parties — the one who sells the insurance and the one who buys it. The release for payment is automated within the smart contract. The conditions under which the value can be transferred needs to be determined by the smart contract.
So, how does a smart contract determine if the crops in a certain location have failed in order to release payment? In this case, a solution that can be implemented via satellite images. An AI system can act as an oracle where it supplies the smart contract with real-time images of the crops to the smart contract to make a decision.
Similarly, this application can be used across several industry verticals. In the logistics sector, a similar application involving satellite images can ensure that automated payments are released when the transporters are required to follow a certain route. With the inclusion of devices like sensors that collect. Data on temperature, climate conditions, etc., AI systems can help smart contracts determine the quality of the goods-in-transit and release payments accordingly. This will automate several areas within the logistics side of supply chains and create efficient processes.
However, AI systems enabling blockchains is one side of the coin; let’s take a look at the other.
How Blockchains can Enable AI Systems
In the figure above, the red dots represent state-of-the-art AI algorithms, and the blue dots represent biological beings. The biological beings rank higher than the AI algorithms based on social criteria, however, the AI algorithms rank high based on their computational and autonomous capabilities. This might seem like a rhetorical fact. However, there is more to it and here is what it signifies.
In reinforcement learning (RL), a machine processes data and makes conclusions based on a value-action paradigm; that is, eating an apple is good. Now, let’s consider ten individual RL algorithms that have to learn to tell us if eating an apple is good or not. In such a case, if one of the algorithms has understood that eating apples is good, and if the algorithm has the potential to propagate the same information to the other nine algorithms, then it creates something known as a social collaborative AI.
Within this problem statement, blockchains can provide AIs with the necessary deployment architecture for the real-world collaboration of AI algorithms.
Presently, companies are becoming cognisant of the value of the data they own and they secure their privacy and confidentiality accordingly. Therefore, the challenge lies in enabling AI algorithms to perform shared learning functions with private data. Blockchains can solve this by providing the infrastructure to enable individual AI algorithms to process private data in their respective networks, and in maintaining the privacy of the data, collaborate with each other.
Challenges to Adopting a Mix of Blockchain and AI
There are several discrepancies and challenges that lie in adopting and implementing AI and blockchains. It is important that we are aware of these challenges to arrive at certain desired outcomes.
Robustness of AIs
AIs need to be robust agents fitted into platforms. There are instances where the data fed into AIs can be manipulated. Given how AI agents are responsible for the transfer of value between two entities, AI agents need to be robust and the external data coming in needs to be untampered and true. Any (unethical) vested interests will influence processes that are meant to arrive at a certain outcome, making the entire ordeal counter-productive.
Accountability for Errors
Even though technology brags of reducing error rates in processes, they are not invincible. The challenge here lies in identifying accountability to the errors that AIs can commit. So, it is difficult to hold a certain party liable for the errors.
Determining Incentives
It is difficult to understand how the incentives are distributed when an AI algorithms being used as a commercial entity.
Building Trust between AIs
We have discussed how AIs can communicate with aechothelr and share a learning process. However, building trust between AI algorithms has not been determined even with the blockchain fabric.
Real-world Applications of Blockchains and AIs
There are several challenges that arise in implementing blockchain and AIs. Nonetheless, there pros outweigh the cons significantly. One of the leading areas that derives the most from the implementation of blcokcahins and AIs in the Supply chain industry.
Take a look at these data points.
Given how blockchains are built to manage and supplement multi-entity networks with efficiency, supply chains are a jig-saw fit. However, on surveying supply chains, you will see that they are vastly convoluted. Real-world supply chains operate within complex networks where information is distributed among different entities. Additionally, supply chains are dynamic with several agents working within it, and there are several decision-makers within the network and within companies that provide these services.
The need for the distribution of information in supply chains between its various parties is vital to its success. To understand this, Dr Chandra broke down supply chains into three fundamental flows:
- flows of goods and services
- flow of information
- flow of money
These flows operate intricately in very complex structures and this is where blockchains bring in value. If information is not shared efficiently within these structures, the implications can result in out-of-stock situations to over-stocked situations. To put this into perspective, these situations cost an estimated $1.1 trillion in loss across the world.
This poses a challenge; the fundamental problem is that we’re in a dynamic situation with dynamic optimisation based on local decisions. There are several entities trying to solve the same problems without the presence of a connected, communication network where information is shared.
How marketsN is addressing this challenge
Dr Chandra went on to share marketsN — a solution that he worked on that addresses this issue. It is a product that was built for enterprise-level supply chains. It executes three important things:
- The blockchain layer enables information sharing
- Smart Contracts align incentives of multiple entities
- Org-level marketbots™ collaborate for multi-agent learning — an AI agent that acts on behalf of the organisation that deploys the marketbot™.
As we already know AIs in blockchains becomes oracles for smart contracts and blockchains can enable AIs with collaborative capabilities. A marketbot™ for a particular organisation will recommend certain actions and ascertains the value derived from those actions. However, to bring the AI agents to collaborate, Dr Chandra posits that the multi-agent reinforcement learning (MARL) algorithm can provide a solution to this issue. He found that, in such a case, the following challenges arise:
- Is each one of these market bots going to optimise each organisation independently?
- Can they collaborate with each other to work more efficiently?
- Do they share state information with each other?
- Are actions co-ordinated between these entities?
- Are their rewards aligned?
Currently, marketsN is still in the process of developing this MARL solution. However, they have used blockchain and AIs to support business network creation with permissioned blockchains and enable the transparent sharing of information. marketsN has also pre-built smart contracts work within existing ERPs and they are aligned with incentives to optimise supply chains.
Stay tuned to learn more about more tech talks from Genesis DevCon.