We are thrilled to announce that Celer has formed a strategic partnership with Chainlink bringing real-world information to our layer-2 scaling platform.
Over the course of last year, we’ve witnessed numerous developers naturally chose to use Chainlink with Celer Network in their applications building and made excellent achievements. Today, in addition to the announcement, we’d like to share with the community an invaluable design pattern we identify from such various attempts, a pattern we propose as a combination of off-chain conditional state transition with an on-chain oracle dependency. Or put it simply, introducing the capability to combine real-world information and layer-2 scalability.
The Design Pattern
To understand the design pattern of combining Celer and Chainlink in use cases, we start with the simple case of an off-chain conditional payment with an on-chain oracle dependency. Celer Network’s cChannel construct supports generalized state channel for not only accelerate simple payments but also smart contracts, in terms of which, the off-chain conditional payment is the most straightforward example. Take the simplest example of a boolean condition, Alice can pay Bob off-chain through a network of Off-chain Service Providers of Celer Network. That payment is conditionally dependent on some future condition being true or not.
The pattern has been applied in our generalized state channel gaming, where “Alice” and “Bob” will both conditionally pay each other at the beginning of the game, depending on who finally win a chess game. You can try it out today on CelerX. In this particular case, the conditional payment is depending on the off-chain state of the game.
Chainlink comes in the picture when the dependency of the conditional payment is not off-chain states, but real-world events. Figure 1 shows this design pattern where Celer users send each other conditional payments while relying on the Chainlink nodes’ oracle input. Compared with writing a smart contract to realize the same logic, the main advantages of using this design pattern include:
- Significantly reduced cost. If we perform the same simple two-party bi-directional betting with an oracle logic on-chain, we need at least four on-chain transactions: two deposits, one check to the oracle and then one payments distribution. With Celer’s layer-2 conditional payment capability, we reduce those FOUR on-chain transactions to ONE oracle related transaction.
- Drastically improved UX. The latency of user interaction is significantly reduced by tens of thousands of times. For traditional on-chain approaches, a full cycle of the conditional payment may take minutes if not tens of minutes to complete. With the support of Celer Network, things can complete in milliseconds. Such low latency renders a new kind of real-time and interactive users experience that was never possible before for this conditional payment semantic.
- Strongly enhanced privacy. Since most of the transactions and condition resolutions in cooperative case will happen off-chain, there will be little to zero permanent on-chain traces to track the amount, senders and recipients of these conditional payments. Therefore, this provides another layer of privacy for deploying conditional payment uses cases.
To elaborate a bit, the aforementioned technical advantages are anticipated to smooth and fuel the use case expansion for both Chainlink and Celer:
The lower cost makes micro-conditional-payment possible. Normally, to execute a fraction of conditional payment upon a $1 small order could cost the developer a painful 20% — 80% of the total amount depending on the gas price. Now, if applying the new design pattern, that cost can be easily reduced by 100X with Celer’s percentage-based fee-charging model.
The improved UX makes real-time interaction use cases indee functionable. For example, Chainlink-powered decentralized prediction/derivative trading market, which looks to achieve the same level of real-time user experience of centralized exchanges on blockchain, has been suffered from the liquidity shortage due to low interaction rates. Yet, things are going to change. With the support of Celer, market participants are now allowed to submit and cancel orders instantly. It also represents a possibility of performing real-time payment in pay-per-use services with SLAs verified by Chainlink.
Lastly, the enhanced privacy meets the confidentiality requirement in situations of private prediction/derivative market trading, insurance and countless other use cases relying on oracles. This privacy enhancement makes manipulation of the real-world events data less likely. As long as involved parties can cooperate in the off-chain resolution protocol, there will be no trace on-chain to track past trading activities.
As Celer Network supports generalized state channels with conditional dependency graph between states, this design pattern can be extended to more flexible version of off-chain conditional state transition with on-chain oracle dependency, where not just simple payment, but any kind of off-chain smart contract execution in Celer can also be conditionally depending on real-world events from Chainlink’s decentralized oracle network. This design pattern combines the power of Chainlink and Celer to bridge real-world information with layer-2 scaling platforms for the first time, enables endless possibilities and uses cases.
Projects using this Design Pattern
Developers are building their works using the above mentioned pattern. At ETHSF 2018, we saw several teams apply the combined pattern of Celer Network and Chainlink, for example, AirPrediction and Micro-Subscription.
AirPrediction is aimed to address the UX challenge of blockchain prediction market via the pattern. With the launch of Augur, everyone had his/her eyes set on the renaissance of prediction market. However, the user experience of Augur today is far from ideal: order books are on-chain and every order takes a painfully long time to confirm. Unless the UX issue is solved, we won’t see mass adoption. In addition, this slowness makes market making close to impossible and results in a large market spread, shallow market depth with low market efficiency. Without an efficient market, we cannot possibly hope to achieve the collective intelligence vision promised by the prediction market. Celer Network naturally helps on the prediction market case with the clear abstraction of conditional off-chain payment, where the “condition” in this case is an on-chain Chainlink oracle.
Micro-Subscription uses this design pattern to build a micro cloud hosting service with SLA guarantee. With this service, users can subscribe to cloud service in minute increments with micropayment and still have guaranteed SLA because while users are paying for the service provider, the service provider is also conditionally paying the user with SLA guarantees. If Chainlink oracles declare the service is down, the conditional payment instantly evaluates to be true and users will be compensated immediately for the loss as an insurance mechanism. This expands the horizon of hosting to not only “trust-brand” but incentive aligned decentralized hosting with instant insurance and SLA.
Want to get started?
Chainlink and Celer Network will co-host a Meetup on Thursday, February 14th at 5:30PM before 2019 ETHDenver. Expose to expert talks, meet the team, ask questions by RSVPing here.
You can check out Celer Network’s SDK here and Chainlink’s SDK here. We will continue to provide more developer materials, joint blog posts and also example codes to showcase this new design pattern. Please stay tuned.
Chainlink is a decentralized oracle network that enables smart contracts to securely access off-chain data feeds, web APIs, and traditional bank payments. Chainlink is consistently selected as one of the top blockchain technologies by leading independent research firms such as Gartner. It is well known for providing highly secure and reliable oracles to both large enterprises (SWIFT) and leading smart contract development teams.
Start your own Chainlink by visiting their website. To learn more about Chainlink’s latest developments, join them on Telegram or Twitter.
About Celer Network:
Founded by four PhDs from MIT, Princeton, UC Berkeley and UIUC, Celer Network is a leading layer 2 scaling platform that enables fast, easy and secure off-chain transactions for not only payment transactions, but also generalized off-chain smart contract. It enables everyone to quickly build, operate, and use highly scalable decentralized applications through innovations in off-chain scaling techniques and incentive-aligned cryptoeconomics. Celer Network is on a mission to fully unleash the power of blockchain and revolutionize how decentralized applications are built and used.
For more information, visit celer.network and try out layer-2 highly interactive and scalable dApps built on Celer’s testnet at http://celerx.app/. To learn more about Celer latest developments, welcome to join on Telegram or Twitter.
To stay updated, follow us via:
- Download here: http://celerx.app/index.html
- Website: https://www.celer.network/
- Telegram: https://t.me/celernetwork
- Twitter: https://twitter.com/CelerNetwork
- Github: https://github.com/celer-network
- Discord: https://discord.gg/Trhab5w
- Meetup: https://www.meetup.com/Celer-Network-Meetup/
- Medium: https://medium.com/celer-network