Immunify.life — Smart contracts and Architecture
Each actor in the platform will access the IMM ecosystem using a native mobile app (Android / iOS) with a built-in IMM wallet (multi-crypto) or a web browser connected to the actor’s wallet of choice compatible with Ethereum and Cardano.
The current state of the blockchain tech. stack does not allow us to deliver the vision in a truly DAPP way, hence we define a hybrid architecture to provide a cache layer for real-time access and cost efficient storage of large chunks of information.
We plan to mint the IMM tokens on the Ethereum blockchain and then burn them and clone the copies in the Cardano blockchain which allows for better tech. specs to support the massive flux of information we will be exchanging.
Our architecture also contains cross chain plugins to other potential networks in case we need to connect to other blockchains to leverage some feature that will be standard at the moment we release each iteration of our roadmap.
Immunify.life high level architecture.
Each actor will be uniquely identified via the abstraction of SSI (Self Sovereign Identity), using NFTs (Non Fungible Token) following the ERC721 standard or similar, in Cardano CNFT or any other current industry standard.
The SSI implementation provides the right level of empowerment and incentives for the weaker actors in the ecosystem to become active players by leveraging access to their private information in a secure, fair way arbitrated by market prices.
Each actor will have one or many roles (hence incentives) in the system: Person/Patient, Physician, Clinic, Government, Travel Regulation Agency, Research Lab, NGO (Donor), Insurer.
Smart contracts architecture:
Router Contract
Required to route requests to the right versions of the contracts (all the contracts we will design are upgradeable in order to keep improving them during the project’s lifecycle).
Factory Contract
Template contract containing the base code for the creation and upgrades of all other contracts.
Patient Contract
Contains the pointers to all personal / private information related to the patient, including the list of treatments, vaccines, certificates and future records we will be storing.
Negotiator Contract
Business logic that arbitrates the information flow between actors.
The ‘Negotiator’ Smart contract is where all the key logic happens, making sure that the ‘game theory’ of all the multiple actors in the system align towards the best outcome that maximizes information rewards.
To leverage the impact knowledge of the ecosystem we are connecting it to the centralized backend AI engine which will be powering all the intelligent decisions that once defined will be automatically coded by the engine and persisted in different versions of the Negotiator contracts.
The Negotiator Contract will hence be a truly digital organism, mutating and evolving its code by improving iteratively as the information and power structure change in the complex ecosystem with only one hard-coded non-upgradeable goal: Optimize information rewards for all participants.
A key aspect of how we plan to preserve the privacy of all the information belonging to each actor while making it public ‘on demand’ is by using the private key in the actor’s wallet to encrypt large chunks of data ‘client side’ and persisting it in the decentralized system (IPFS or similar) in a way that will only be able to be decrypted by using the end user’s explicit permission and only storing pointers of aggregated data: ‘hashes’ at the blockchain layer.
At the moment of any exchange between two or more parties, new key pairs will be generated client side and exchanged asynchronously between them using a messaging broker (Whisper alike or centralized RabbitMQ) for the private information to be exchanged securely and decrypted only at client-side endpoints.