Loader
logologo
Alpha Zone
Analysts
My Reading List
Log in
DeFiGaming & MetaverseInfrastructureMarketsNFTs
Agoric Introduction: the JavaScript Hub of the Interchain
Jake Kennis
main

TLDR

  • Agoric is a layer-1 blockchain built on the Cosmos stack that aims to bring a compelling new VM to the world of DeFi using JavaScript to bring in the ~12 million JavaScript programmers to DeFi.

  • They will launch as a permissioned smart contract chain with the Inter Protocol already integrated with a native AMM, vaults and liquidators.

  • As the chain develops, they will instill gas fees and open the chain to permissionless smart contract deployment. They already have many sample codebases for developers to replicate such as AMMs, lending, vaults and much more.

  • The Inter Protocol brings forward its own stablecoin IST, which has a similar model to DAI, using an overcollateralized model from 3 sources of collateral: USDC via a price stability module, ATOM and other SDK coins for overcollateralized minting of IST and finally the BLD (Agoric’s governance/staking token) stakers can mint IST against their staked collateral.

  • Agoric will be interoperable with other IBC chains and its assets can flow freely throughout the Cosmos Ecosystem.

  • The team is very experienced having co-developed IBC and are pioneers in the crypto space more generally. Outside of crypto, the team members come from a diverse set of backgrounds including distributed systems, smart contracts dating back over 20 years, JavaScript Standards Committee, financial services and a broad spectrum of Web2 companies.

Key Terms

TermDescription
App-chain (application specific blockchain)A layer 1 blockchain focused on a specific vertical. For instance, Osmosis is an app-chain focused on creating a DeFi chain focused around its core DEX.
Virtual Machine (VM)There are many VMs such as the Ethereum Virtual Machine (EVM) which is a computation engine for many of executable projects to use it as a ‘decentralized computer’. The VM allows the various smart contracts to interact with one another.
ZoneA Zone is an app-chain on Cosmos that has enabled IBC
HubRefers to a Zone that gets sufficiently popular where it becomes integral in cross-chain interoperability - any Zone can become a Hub. Examples include the Cosmos Hub (ATOM)
Cosmos HubRefers to the layer 1 blockchain that is home to ATOM, does not reflect the broader ecosystem. This is confusing naming and should not be misconstrued with the entire ecosystem
Shared SecurityCosmos chains do NOT have shared security by default. Some shared security features in development: Interchain Security - shared security for Cosmos SDK chains to rent out security from the Cosmos Hub validator set (v1 scheduled for September 2022). Interfluid Staking - shared security for Cosmos SDK chains using liquidity pools on Osmosis. Celestia - shared security for rollups
Inter Blockchain Communication (IBC)A generalized messaging protocol that allows for any Cosmos Zone to be interoperable with each other. Made up of many parts: 1) Base layer - Tendermint BFT consensus chains, 2) Transport layer - permissionless relayers from source to destination chain, 3) Authentication layer - light client verification, 4) Interface layer - IBC Data packets
Interchain AssetsAny asset that is a native Cosmos SDK coin such as OSMO, SCRT, ATOM, JUNO, etc. This is different from CW-20 tokens (ERC-20 equivalent on CosmWasm). CW-20 is to Cosmos SDK coins as ERC-20 is to native ETH
ENDO / Hardened JavaScriptHardened JavaScript is a more secure version of JavaScript but with reduced vulnerabilities
Electronic Rights Transfer Protocol (ERTP)Agorics token standards for tokens and NFTs. It defines how digital assets are transferred and traded with the same security properties.
ZoeProvides a safety net for smart contracts on Agoric
CapTPA It is the transport protocol for distributed code to run across chains and computes in a secure way.

Agoric Overview

Agoric is a layer-1 blockchain that brings a new and compelling VM that utilizes JavaScript to attract millions (~12 million) of active JavaScript developers into the broader crypto markets. It is built out on the Cosmos SDK and secured via Tendermint BFT consensus. So far, the Ethereum Virtual Machine (EVM) has been the most dominant VM in crypto, however, greater diversity is desirable for the design space of crypto. In the Cosmos ecosystem, there are a few competing VMs, all which are interoperable over IBC:

  • CosmWasm
    • Rust
      • Chain(s): Osmosis, Juno Network, Stargaze, Injective, Secret Network, and more
  • EVM
    • Solidity
      • Chain(s): Evmos and Cronos
  • Agoric’s VM
    • JavaScript
      • Chain(s): Agoric

At this point in time, CosmWasm is the fastest growing VM of the Cosmos ecosystem. It comes in 2 forms on each chain it's deployed on:

  • Permissioned
    • Permissioned contracts = app-chain
    • Example: Osmosis, Stargaze and others
  • Permissionless
    • Permissionless contracts = general-purpose blockchain
    • Example: Juno Network

The advantage of building a chain on Cosmos is the ability to be an application- specific chain (app-chain). There are many benefits to being an app-chain which can be described more in detail here, but the long term edge cases of being a generalized smart contract chain on the Cosmos stack are still very early and unclear; in particular, Ethereum and other chains might be a better home for some of these apps who want permissionless contract deployment.

Further, Agoric will initially launch as a permissioned chain in the beginning and slowly transition to a permissionless smart contract chain by the end of the year. Given app-chains have structural advantages on Cosmos, why would Agoric choose to pursue this path? The answer to this boils down to their design which allows for all of their contracts to communicate asynchronously. In simpler terms, if the chain becomes congested due to higher network activity, they will be able to scale horizontally where they have multiple independent validator sets of validators who validate subsets of the contracts.

Takeaway: Agoric aims to become a permissionless smart contract chain that can scale horizontally by having multiple chains where they all communicate asynchronously.

Agoric Key Components

Agroric is made up of many key components that align incentives across the protocol layer (validators), the application layer (dApps), and ultimately the end users. Below is an overview of the Agoric stack.

Agoric
Source: Agoric

ENDO / Hardened JavaScript

Understandably, many developers may raise concerns about the security implications of building smart contracts using JavaScript. Many JavaScript apps in the Web 2.0 world have many code dependencies given they use/rely on 3rd party code and even user-provided code for certain plugins and extensions. These types of dependencies often lead to vulnerabilities, whether they are currently known vulnerabilities or potential vulnerabilities that have yet to be discovered. However, Agoric has built around these security features and built out Hardened JavaScript. It is still JavaScript but it allows a securable platform by running arbitrary and untrusted JavaScript in a confined environment.

Within this confined environment, additional security measures are taken to ensure that smart contracts can be designed and run with mitigated risks. The primary security measure invoked is the Principle of Least Authority. This limits the potential damage from a bug exploit as each object within the smart contract is only allowed/given permission to do its legitimate job.

In addition, Hardened JavaScript is always in “strict mode”. The key difference between “strict mode” and regular JavaScript is the ability to redefine built-in functions. For example, in regular JavaScript, an individual can redefine a change password function to include certain arrays which run the risk of stolen passwords. This would not be possible on Hardened JavaScript as the standard built-in objects are immutable.

Endo is the equivalent of Node.js for JavaScript. Endo allows Hardened JavaScript to run guest programs and limits the access these programs have. Endo is responsible for connecting and establishing Node.js packages in Hardened JavaScript compartments and restricting access to the host’s resources. For example, an Agoric smart contract is an example of an Endo program that runs in an Endo host.

Electronic Rights Transfer Protocol (ERTP)

The Electronic Rights Transfer Protocol (ERTP) is Agoric’s token standard for digital assets in JavaScript. It enables the creation of various digital assets which feature the same security properties and the same method of transfer.

New assets that are minted with ERTP are stored in a “payment” or a “purse”. Payments store assets that are intended to move between purses or to other destinations. Purses store assets until withdrawal into a payment for use. Each individual purse or payment can only hold one specific type of asset, meaning that if a purse holds ETH, it cannot hold ATOM as well.

The process for depositing assets to a purse is checked for genuineness and that the asset and purse match. If that is successful, ERTP guarantees that the payment is burned and the purse contains what it held prior to the payment and the full content of the payment. If unsuccessful, ERTP guarantees that both the alleged payment and the purse are in the same state before the call.

Minting using the ERTP makes new digital assets as payments and mints can only make one kind of asset. The kind of asset is referred to as a “brand”. For every brand, there is a specific mint, and specific issuer associated with that brand. That specific mint can only create assets of that brand and the specific issuer can only create new purses and payments for that brand.

Zoe

Zoe is Agoric’s smart contract framework environment that provides developers with safe and secure smart contracts. For users, it guarantees that the user gets what they desire or a full refund of all assets deposited to the smart contract - even if the smart contract is buggy or malicious. For developers, Zoe provides accessibility through JavaScript and peace of mind knowing that users’ assets are secure regardless of a buggy contract.

This is achieved through “offer security enforcement”. Offers are a structured way of describing a user’s intent, an example offer would be: “I’ll give you three IST for two XYZ tokens”. The offer does not specify how the exchange occurs- that is the responsibility of Zoe. The smart contract managing the swap only has to determine what articles are being exchanged and how much of it is exchanged.

Essentially, this works by having both users' assets held in escrow by Zoe until either of two outcomes is accomplished:

  1. Both users’ offers are in agreement and match, allowing the swap to complete, or

  2. The contract is buggy/offers do not match and thus assets are returned to both users respectively. When a user escrows with Zoe, they receive a JavaScript promise for a future payout.

Inter Protocol

The Inter Protocol is an integrated economic layer on top of the Agoric chain, which serves as the central point of focus for Agoric’s economic activity and adoption. The Inter Protocol's stable token, IST, is an overcollateralized stablecoin soft-pegged to the US Dollar. One of Agoric's visions is to provide users on its blockchain with a stable and non-volatile means of transaction and fee payment while also operating as a store of value. Moreover, following the debacle of the Terra blockchain and the UST stablecoin, the IBC ecosystem finds itself without a dominant, secure, and overcollateralized stablecoin. Hence, Agoric can leverage its integration with IBC to provide stablecoin accessibility and availability throughout the IBC ecosystem, driving further adoption and activity back towards Agoric.

There are 3 collateral types that can be used to mint IST - each of which has varying arbitrage speeds and parity with USD.

  1. Deposit whitelisted Cosmos SDK coins as collateral to mint IST
  2. Deposit high-quality stablecoins such as USDC
  3. Use your staked BLD tokens to mint IST against your stake

Specifically, the Inter Protocol allows users to mint IST from whitelisted assets, including some interchain assets such as ATOM, OSMO, and SCRT. It is important to note that there is an additional risk that comes with allowing volatile assets as collateral, even in an over-collateralized stablecoin model. This feature is the primary differentiator to other stablecoins because it allows users from any IBC chain to seamlessly and easily access IST by providing their native assets as collateral and significantly reduces the friction of engaging in cross-chain DeFi. Thus, allowing the IST liquidity to expand across the entire IBC ecosystem and enhancing the use-case of each chain's native token. Note that supported assets are voted on by the Inter Protocol governance.

The success of the Agoric chain partially depends on the adoption of IST since Agoric is a stablecoin-centric blockchain, comparable to Terra. However, the two critical differences between Agoric and Terra are that IST is over-collateralized with multiple layers of collapse-protection mechanisms, and Agoric directly benefits from IST's adoption and economic activity via its revenue accrual model compared to Terra’s mint/burn mechanism. Agoric stakers and validators receive stable USD-denominated revenue from IST’s growth, which is much more sustainable. In short, the native staking token BLD which is used to secure the chain is not tied to any unsustainable tokenomics that are dependent on the success of its native stablecoin.

The Inter Protocol and Agoric accrue revenue in four main ways:

  • First, IST is the fee token and unit of account on the Agoric platform. Transaction fees are settled in IST and paid to BLD stakers and validators as compensation for securing the network via the Reward Pool.
  • Additionally, users can mint IST by depositing their collateral into their vault but are subject to a stability fee (calculated daily), minting fee (upon minting), and interest rate to retrieve their assets. The fee revenue is split between the Reserve Pool and the Reward Pool. The Reserve Pool functions as a stability mechanism for IST and funds the pools on Kinetic, Agoric's AMM, to handle loan liquidations.
  • Agoric also accrues revenue fees from trading fees from their DEXes. The team has mentioned that they are in progress to develop a native AMM DEX as well as a stableswap for stable pairs.
  • Lastly, like other PoS networks, BLD is issued to stakers and validators as a reward for securing the network.

The demand for IST translates to increased revenue for Agoric, which, in turn, enhances the protocol's security and assists in its adoption. This design essentially creates a positive feedback loop where stakers and validators succeed along with the adoption of the stablecoin, which brings more interest to the protocol and further drives up the revenue generated.

Frame_42.png

The Inter Protocol is governed by BLD holders (BLDer DAO), who elect a designated economic committee to oversee various parameters of the protocols to ensure its stability. The committee proposes changes to these metrics as necessary, which are subject to approval by the BLDer DAO. These parameters include acceptable assets as collateral for IST minting, collateralization ratio, stability fee, debt limit, liquidation penalty, minting fee, and interest rate.

Further, IST and BLD tokenomics will be covered later in the report which includes the multiple layers of protection to ensure parity with USD.

Agoric Ecosystem and Future Roadmap

Why would a project deploy on Agoric?

Projects deploying on Agoric enjoy the familiarity of working within the JavaScript environment. In addition, the security guarantees that the Zoe framework provides enable and encourage developers to rapidly produce applications with reduced fear or risk of severe smart contract bugs and exploits leading to devastating asset loss.

Furthermore, an app deploying on Agoric means that the app will be able to tap into the billions of liquidity already within the Cosmos ecosystem. Additionally, trustless interoperability and composability will be handled over IBC. Wherever IBC goes, Agoric’s apps can compose with the connected chains. Currently, IBC is mainly limited to Tendermint chains but that is quickly changing as IBC is directly expanding to the Polkadot/Kusama ecosystems via Composable Finance, potentially NEAR via these proposals. There is also speculation that Avalanche may integrate IBC for its subnet architecture as well as Polygon which happens to be built out on the Cosmos SDK and Tendermint stack.

Outside of direct IBC connections, Agoric can take advantage of trusted cross-chain messaging protocols such as Axelar, which connects all other EVM chains and layer-2s to Cosmos which IBC cannot currently reach. Some of these chains include Ethereum, Avalanche, Optimistic Rollups, and more. Of course, using Axelar means you are trusting the security of the given bridge, we wrote extensively on the cross-chain messaging protocols here. Thus, building on Agoric does not force developers to select which chain to deploy on and fragment liquidity across multiple deployments on separate chains. Rather, developers can deploy on Agoric and access every other ecosystem, either through trustless ‘bridges’ over IBC or more trusted solutions such as Axelar or any other bridge that Agoric chooses to integrate such as the Gravity Bridge and many others.

So how will Agoric attract developers and users to its chain?

For developers, Agoric offers the familiar environment of JavaScript and the security of the Zoe framework. This allows developers to rapidly develop their products without focusing significantly on the risk of bugs and exploits leading to asset loss. Due to Agoric’s security design, components of certain applications can be trusted and implemented widely. This allows for applications to be rapidly developed given the extensive availability of components. Dean Tribble (CEO of Agoric) stated that an analogy for this could be “DeFi Legos”, plug-and-play components for developers. One example of a “DeFi Lego” could be a liquidation or oracle mechanism that a developer wants to implement into their application. By simply implementing the battle-tested mechanisms, development should be rapidly accelerated.

For users, Agoric aims to offer security and safety. Typically, smart contracts always bear a risk of asset loss when interacting with them. By design, Agoric should ensure that a user will always get what they desire or a full refund of their assets- a user should not leave a smart contract empty-handed.

BLD and IST Tokenomics

IST

The IST stablecoin is soft-pegged to the US dollar using an overcollateralized model similar to DAI. Users can borrow against their collateral (approved assets) by depositing it into their vaults to mint IST. The supply and growth of IST depend on the demand for its utility within Agoric, the Cosmos ecosystem, and any other ecosystem that incorporates IST. The Inter Protocol utilizes the over-collateralization model to ensure IST's stability and security, which gives IST holders confidence in a sufficient treasury balance of assets in times of severe volatility or other unknown factors. Furthermore, BLD holders determine parameters such as the collateralization ratio and debt limit. The IST peg stability is maintained by three main arbitrage mechanisms that work synchronously:

  • Parity Stability Module

    • Instead of depositing their collateral into a vault, users can mint or burn IST by providing or redeeming high-quality stablecoins like USDC to the protocol. Similar to DAI’s structure, having a significant portion of the backing in a basket of low-risk, stable assets reduces some risk and promotes safety.
  • Vaults

    • As mentioned above, the vaults are used by users who wish to mint IST by providing over-collateralized collateral to a loan. Users pay interest and stability fees upon loan repayment. If the dollar value of the collateral falls below the collateralization ratio (measured via oracle), the loan is subject to liquidation. If the borrower is liquidated, the protocol will sell the collateral on its AMM to cover any bad debt plus a liquidation fee and return the remainder (if any) to the user.

    • The Inter Protocol prioritizes its liquidation mechanism by implementing a rate-limiting procedure and ensuring that the collateralization ratio is functioning correctly to prevent shortfalls, incurring bad debt, minimizing sudden loss of value, and limiting price impact upon liquidation cascades.

  • BLD Boost

    • BLD stakers can also mint IST by locking up a small portion (<10%) of their stake, repaid by the future IST staking reward, while the staked BLD accrues yield. However, the locked-up BLD cannot be redeemed or withdrawn until the user repays the IST loan. In contrast to minting through a vault, locked up BLD is not subject to liquidation.
Arbitrage mechanismCollateral typeArbitrage speedParity with USD
Parity stability mechanismHigh quality stablecoinsfastNarrow spread
VaultsWhitelisted asset (approved by the BLDer DAO)MediumMedium spread
BLD BoostStaked BLDSlowWide spread

Source: IST Whitepaper

In addition to these arbitrage mechanisms as the initial defense line against a de-pegging event, the protocol also has a Reserve Pool, which serves two purposes.

  • The Reserve Pool provides liquidity to the Kinetic AMM for liquidation swaps. This is much different from MakerDAO’s model where liquidations require off-chain components of liquidators for bad debt; whereas on Inter Protocol, their contracts communicate asynchronously, allowing liquidations to dynamically liquidate on the Kinetic AMM. This limits the sudden loss of value and price impact during a liquidation event.
  • The Reserve Pool also functions as a backstop/emergency fund to cover any outstanding shortfalls in case of a major liquidation event and when the liquidation mechanism parameters (speed, effective over-collateralization ratio for an efficient market) are wrong.

These two functionalities play a critical role in maintaining the stability of IST during times of high volatility. The Reserve Pool accrues value from the Agoric chain execution fees and liquidation penalty.

BLD

BLD, the native staking token of the Agoric chain, serves two purposes. BLD is the staking token used to secure the network and serves as the governance token of Inter Protocol. Unlike other layer-1 chains which use their native token as the settlement currency, BLD is not used for transaction fees on the Agoric chain. Instead, BLD accrues value from increased economic activity on the network as IST from the Reward Pool is distributed to stakers on top of BLD rewards. Thus, helping to secure the network and promote growth is beneficial to BLD stakers and network validators.

A total of 70m BLD tokens, or approximately 7% of the initial supply, were sold during Agoric's public sale on CoinList in December of last year, raising over $50m for the project. The tokens are subject to a minimum of a 6-month locking period, followed by a 12-month linear release schedule. Tokens for options 1 and 2 buyers are locked until June and November, respectively. While the BLD received is not yet transferrable, holders can stake for future yield when the staking reward mechanism turns on after the launch of Mainnet Phase 1, as well as vote on governance proposals.

SegmentTotal Supply in %Release Schedule
Network Decentralization17.00%Liquid as of distribution date on 11/1/21. Tokens may be subject to a lockup and release schedule.
Foundation12.50%Liquid as of distribution date on 11/1/21. Tokens may be subject to a lockup and release schedule.
Community & Ecosystem5.50%Liquid as of distribution date on 11/1/21. Tokens may be subject to a lockup and release schedule.
Core Contributors18.60%12-month cliff starting on 11/1/21, followed by a 12-month linear unlock. Note - tokens are subject to additional 4 year employee vesting schedules, which vary by employee.
Advisors3.00%12-month cliff starting on 11/1/21, followed by a 12-month linear unlock.
Early Backers11.40%12-month cliff starting on 11/1/21, followed by a 12-month linear unlock.
Operations12.50%Liquid as of distribution date on 11/1/21.
Private Sales - 2 year lockup8.60%12-month cliff starting on 11/1/21, followed by a 12-month linear unlock.
Private Sales - 4 year lockup3.90%12-month cliff starting on 11/1/21, followed by a 36-month linear unlock.
Public Sale7.00%Option 1: 2.5% token supply at a price of $0.65/BLD with the first unlock on 11/1/21, followed by a 12-month linear unlock. Option 2: 4.5% token supply at a price of $0.8/BLD with first unlock on 6/29/22, followed by a 12-month linear unlock

Source: CoinList Agoric Sales

Note that a 24-month vesting schedule for many of the investor segments in Agoric is arguably short for building a long-lasting project since financial incentives from availability to realize profits may delay the team from making as much progress. Once some vesting schedules terminate by the end of next year, there may be significant incoming selling pressure.

Risks and Other Considerations

IST Centralization

Given there are 3 collateral types to mint IST and it is not yet live, the breakdown of the collateral types is still unknown. However, looking at DAI as an example, we have seen how USDC has increasingly become the predominant asset backing DAI, rendering it as a wrapped version of USDC. This introduces centralization and regulatory risks given USDC is highly centralized. Depending on the assets backing IST, the same risk of its collateral backed assets apply. Additionally, depending on the bridged versions of the USDC or other highly trusted stablecoins, the backing will inherit the security of these bridges given there can be multiple canonical versions of USDC. Thus, security of the collateral in the vaults are not created equal.

Competing VMs

Agoric brings forth a new and compelling VM to the crypto space. Given its total addressable market of developers, it is a very promising solution to bringing crypto to the masses. However, there are still competing solutions who are ultimately pushing forward the design space of smart contract development. As we have seen, the EVM has become the dominant VM in terms of user activity on most chains. It has been incorporated on:

  • Polkadot Parachains
  • Polygon
  • Avalanche
  • Cosmos Zones

Given the tooling and infrastructure associated with the EVM architecture, it makes sense why many layer-1s choose to integrate it to bring forward the masses given the network effects of the EVM. Given this, Agoric offers a compelling solution but still faces a competitive landscape with the more proven and tested EVM. Additionally, CosmWasm is another VM discussed earlier that is gaining lots of popularity within Cosmos for its cross-chain features.

Final Takeaways

  • Agoric taps into the ~12m JavaScript developers to build safe and secure smart contracts.

  • Agoric enables horizontal scaling through multiple independent validator sets of validators who validate subsets of the contracts.

  • Agoric can avail of cross-chain interoperability over IBC, as well as trusted cross-chain interoperability with other ecosystems via Axelar and other bridges.

  • Its roadmap is to initially have permissioned smart contracts with a transition to becoming a fully permissionless chain for anyone to deploy apps on Agoric.

You might also like
Article cover
Ethereum’s Pectra Upgrade - What To Expect
Ethereum’s Pectra upgrade, set for May 2025, focuses on scalability, usability, and validator efficiency. Pectra doubles blob data capacity per block,
Disclosure: The authors of this content and members of Nansen may be participating or invested in some of the protocols or tokens mentioned herein. The foregoing statement acts as a disclosure of potential conflicts of interest and is not a recommendation to purchase or invest in any token or participate in any protocol. Nansen does not recommend any particular course of action in relation to any token or protocol. The content herein is meant purely for educational and informational purposes only and should not be relied upon as financial, investment, legal, tax or any other professional or other advice. None of the content and information herein is presented to induce or to attempt to induce any reader or other person to buy, sell or hold any token or participate in any protocol or enter into, or offer to enter into, any agreement for or with a view to buying or selling any token or participating in any protocol. Statements made herein (including statements of opinion, if any) are wholly generic and not tailored to take into account the personal needs and unique circumstances of any reader or any other person. Readers are strongly urged to exercise caution and have regard to their own personal needs and circumstances before making any decision to buy or sell any token or participate in any protocol. Observations and views expressed herein may be changed by Nansen at any time without notice. Nansen accepts no liability whatsoever for any losses or liabilities arising from the use of or reliance on any of this content.