Tech blog: Effect Account System

Jesse Eisses
Effect Network
Published in
5 min readJul 29, 2021

Read in 中文

A Multi-Chain Decentralized Account System

We’re very excited to introduce the new Effect account system in this technical update. This is an important feature of the upcoming release of Effect Network, which will improve the user experience and ease of task placement. The account system affects almost every part of the network, including the registration process, the posting and completion of tasks, and the publication of campaigns. It also enables workers and requesters to interact with the platform using non-EOS wallets such as MetaMask, among other advantages.

This post is the first in a three-part series where we dive into new technical components of the network. Together, they form the basis of a decentralized network for human intelligence that will make it extremely simple for companies to publish tasks and for workers to complete them and earn EFX.

Why a new account system?

Each user on Effect Network has a private key that they use to interact with the network. The account system’s job is to identify and authorize the interactions by a user. A big problem for our growth has been the requirement for an EOS account to use the platform. Although EOS accounts are powerful, they are complicated and expensive to set up for newcomers. They also make it difficult to perform cross-chain transactions because of EOS’s advanced permission model.

The Effect account system is designed to overcome these issues. It’s simple, composes well with other systems, and integrates with the existing EOS system. Some other advantages of this system include:

  • Interact with Effect Network without an EOS account.
  • Support for more wallets, such as MetaMask and TrustWallet.
  • Pay transaction fees in EFX, no CPU required!
  • It’s backwards compatible: if you have an EOS account, you can just keep using it.

How does it work?

The Effect account system tracks virtual user balances using a multi-index table on the EOS blockchain. Transactions on virtual balances can be performed by either an EOS account or by providing a plain ECDSA signature. The key concept here is that virtual token transfers and the sending of EOS transactions are treated separately. To perform a transaction without an EOS account, the user must provide a valid ECDSA signature and add an EFX fee. A relayer can then process the transaction to collect the fee.

Effect account Smart-Contract

We are implementing the Effect account smart contract on the EOS blockchain. The smart contract checks and verifies if the ECDSA signature provided with a transaction is valid and that its address is allowed to make transactions for an Effect account. At the same time, the contract keeps track of EFX balances. It will only allow the owners of an Effect account, either with an EOS account or a BSC address, to withdraw their EFX funds to either an EFX account or their BSC address through the Effect Bridge.

Integration with Binance Smart Chain

The Effect account system allows for two ways to control your account:

  1. Use an EOS account (no relayer necessary to make transactions)
  2. Use an Elliptic-Curve Public Key Address (relayer necessary)

The first option is useful if you already have an EOS account or know how to create one.
You can use this option to send your own transactions to the blockchain in order to perform tasks, publish campaigns, withdraw tokens, and so on.

The second option allows users to control their account with a non-EOS account, for example, through MetaMask with a Binance Smart Chain key-pair.

You can create transactions and sign them with your MetaMask account. After you have signed the transaction, a relayer can push this transaction to the EOS blockchain.

Relayer network

The multi-chain feature of the decentralized Effect account system is powerful, but it also poses a challenge: when you sign a transaction with your BSC private key, it still needs to be pushed to the EOS network by an EOS account with enough resources. This can be solved with a relayer network, where relayers push the already signed transactions to the blockchain in exchange for a small EFX fee. Anyone who has an EOS account with resources could act as a relayer and earn the fee rewards from pushing signed transactions from BSC addresses to the EOS blockchain. The diagram above shows the flow of a user interaction with an Effect account and MetaMask:

  1. User creates an EOS transaction through a frontend, e.g. the Effect Force website. (for example, to publish a new task)
  2. Part of the transaction is sent to the wallet to retrieve a signature, e.g. MetaMask.
  3. User creates the signature in the wallet.
  4. The transaction, including the signature and an EFX fee, is sent to the Relayer Network.
  5. A Relayer pushes the signed transaction to EOS and receives the fee reward

What’s next

The Effect account system will make Effect Network easy and more fun to use. Initially, the implementation will be geared towards the worker and requester side of Effect Force, but we envision the system to have many more applications, such as the EffectDAO, Effect Staking, and integrations with 3rd party dApps.

The first version of the account system is being actively developed, and the smart contract has been deployed on testnet. It’s also being integrated into the Effect SDK, which will support all of the above-mentioned features. The code can be reviewed on GitHub. To keep up to date on the development, it’s best to join our Discord server and follow @effectaix on Twitter.

In the next tech blog, we will discuss important improvements to Effect Force, including decentralized fee collection and campaign creation. Thanks a lot for reading!

Written by Laurens Verspeek & Jesse Eisses, July 29th 2021

--

--