Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chain abstraction overview update #2420

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
85 changes: 60 additions & 25 deletions docs/2.build/1.chain-abstraction/what-is.md
Original file line number Diff line number Diff line change
@@ -1,61 +1,96 @@
---
id: what-is
title: What is Chain Abstraction?
title: What is Chain Abstraction?
---

import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
import {CodeTabs, Language, Github} from "@site/src/components/codetabs"
import {CodeTabs, Language, Github} from "@site/src/components/codetabs";

The idea behind `chain abstraction` is quite simple: **blockchain** technology should be **abstracted away** from the user experience. In other words, people should **not realize** when they are **using a blockchain**, nor **which blockchain** they are using.

![img](/docs/assets/welcome-pages/chain-abstraction-landing.png)

To help on this task, NEAR Protocol provides services that allow to **create** and **recover accounts** using **email addresses**, use the account **without acquiring funds**, and **control accounts** in **other chains**. All in the most **seamless** way possible.
To help on this task, NEAR Protocol provides services that allow to **create** and **recover accounts** using **email addresses**, use the account **without acquiring funds**, and **control accounts** in **other chains**. The combination of these services allows to create a **seamless** user experience, in which users can use blockchain-based applications without realizing they are using a blockchain.

---
As an example, this would allow users to collect NFTs across different chains, without ever needing to explicitly create an account or acquire crypto. All with just a single login.

## Relayers: Cover gas fees
Allowing users to start using a dApp without having to acquire funds is a powerful tool to increase user adoption. NEAR Protocol provides a service that allows developers to subsidize gas fees for their users.

This concept, known as "Account Abstraction" in other chains, is a **built-in feature** in NEAR. User can wrap transactions in messages known as **meta-transaction**, that any other account can relay to the network.
## Chain Abstraction: The Holistic View

:::tip
In NEAR the relayers simply attach NEAR to cover gas fees, and pass the transaction to the network. There, the transaction is executed as if the **user had sent it**.
:::
NEAR's ecosystem vision is to facilitate interactions across all blockchain networks and the larger internet. This transformative approach aims at enhancing the user experience and developer capabilities through advanced technologies, specifically in the realm of decentralized finance (DeFi) and artificial intelligence (AI).
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This sounds like another intro, maybe we don't need it, or we need to merge it above


<hr subclass="subsection" />
Central to this vision is the concept of **chain abstraction**, which is designed to provide seamless access to a wider range of crypto assets, smart contracts, and blockchain states. This is achieved through a trio of key technologies: the intent layer, [chain signatures](chain-signatures/chain-signatures.md), and the [omnibridge](#).
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This also reads like introduction, and more importantly, here we say that chain abstraction is:

  • intent layer
  • chain signatures
  • omni bridge

But above we say that chain abstraction is:

  • email login
  • relayers (covering gas)
  • chain signatures

So we need to either remove it, or change what is above, or merge it


![Chain Abstraction Stack](/docs/assets/chain-abstract-1.png)

- The intent layer serves as a foundational framework for user requests.
- [Chain signatures](chain-signatures/chain-signatures.md) empower smart contracts to sign transactions across different assets and chains.
- [Omnibridge](#) facilitates communication and state transitions between various blockchains, ensuring that transactions are executed smoothly.

---

## Multi-chain signatures: One account, multiple chains

## Multi-chain signatures: One account, multiple chains
Currently, users and applications are siloed in different chains. This means that a user needs to create a new account for each chain they want to use. This is not only cumbersome for the user, but also for the developer who needs to maintain different codebases for each chain.

NEAR Protocol provides a multi-chain signature service that allows users to use their NEAR Account to sign transactions in **other chains**. This means that a user can use the same account to interact with **Ethereum**, **Binance Smart Chain**, **Avalanche**, and **NEAR**.

![Chain Signatures](/docs/assets/chain-abstract-2.png)

:::info
Multi-chain signatures work by combining **smart contracts** that produce signatures, with indexers that listen for these signatures, and relayers that submit the transactions to other networks. This allows users to hold assets and use applications in **any** network, only needing to have a single NEAR account.
:::

<hr subclass="subsection" />
---

## Fast-Auth: Email onboarding
One of the first barriers that new users face when entering the world of Web3 is the need to create a crypto wallet. This generally implies the need to choose a wallet, create and store a recovery phrase, and obtain deposit funds to start using the account.
## Applications

With FastAuth, users only need to provide an email address to create a NEAR account. Using the same email address the user will be able to use their account across applications and devices.
Thanks to significant advancements in the cryptocurrency space, including cross-chain interactions, account management, and the raise of AI applications, truly innovative projects are being developed in the NEAR ecosystem:

:::warning
FastAuth is being deprecated, stay tuned for updates
### Bitcoin Use Cases
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we have links for all of these use-cases, I'm afraid right now it sounds super "marketing", and not oriented to helping devs learn something

Otherwise maybe we make a blog post?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting, Proximity has actually made a blogpost that I think talks about all of this https://medium.com/@ProximityFi/building-bitcoin-native-dapps-with-nears-abstraction-stack-fb4aeb448eee


- **Bitcoin Lending**: improve the ability to borrow against Bitcoin held on the Layer 1 blockchain through chain signatures, making it easier to connect wallets and interact with lending protocols.
- **Trading**: enable issuing and trading assets on Bitcoin, though current experiences are limited. The integration of chain signatures aims to streamline this process.
- **Restaking**: support liquid stake tokens and restaking capabilities.

### Cross-Chain Protocols

- Designing protocols that are agnostic to different blockchain environments. This enables users to swap assets between chains without needing to deploy multiple versions of a protocol.
- Examples include projects like **Omnilane** and **Thesis**, which allow flexible asset swaps and margin-based protocols across various chains, enhancing liquidity and capital usage.

### Account Abstraction

- The development of account abstraction has led to the creation of wallet systems, like those integrated into applications such as **HOT Wallet**, which can manage assets across multiple blockchains.
- An example is a wallet that enables users to conduct transactions and swaps, showcasing seamless interaction with various decentralized applications (dApps) through unified balance management.

### AI-Driven Autonomous Agents

- The potential for creating persistent AI agents that leverage decentralized technologies, which can operate independently on the blockchain.
- These agents would utilize multi-party computation technology to interact with users and the network in a secure, decentralized manner.

### Relayers: Cover gas fees

Allowing users to start using a dApp without having to acquire funds is a powerful tool to increase user adoption. NEAR Protocol provides a service that allows developers to subsidize gas fees for their users.

This concept, known as "Account Abstraction" in other chains, is a **built-in feature** in NEAR. User can wrap transactions in messages known as **meta-transaction**, that any other account can relay to the network.

:::tip
In NEAR the relayers simply attach NEAR to cover gas fees, and pass the transaction to the network. There, the transaction is executed as if the **user had sent it**.
:::

---
<!--

## Chain Abstraction: The Holistic View
### Fast-Auth: Email onboarding

The combination of these services allows to create a **seamless** user experience, in which users can use blockchain-based applications without realizing they are using a blockchain.
One of the first barriers that new users face when entering the world of Web3 is the need to create a crypto wallet. This generally implies the need to choose a wallet, create and store a recovery phrase, and obtain deposit funds to start using the account.

Users will simply login with an email, and a **zero-fund** account will be created for them. No seed phrases to remember, no private keys to safe keep, and no need to acquire funds.
With FastAuth, users only need to provide an email address to create a NEAR account. Using the same email address the user will be able to use their account across applications and devices.

Once having their account, apps can ask the user to create meta-transactions and send them to any relayer. The relayer will pass the transaction to the network, attaching NEAR to pay for the execution fees. The transaction will then be executed as if the user had sent it, since the relayer is only there to attach NEAR to the submission.
:::warning
FastAuth is being deprecated, stay tuned for updates
:::

If the user wants to interact with other blockchains, they can use their account to interact with a multi-chain signature relayer, which will relay the transaction to the right network, covering GAS fees.
<hr subclass="subsection" />

As an example, this would allow users to collect NFTs across different chains, without ever needing to explicitly create an account or acquire crypto. All with just a single email login.
-->
9 changes: 2 additions & 7 deletions website/sidebars.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,14 +88,9 @@ const sidebar = {
]
},
{
"type": "category",
"label": "Chain Signatures",
"link": {
"type": "doc",
"id": "build/chain-abstraction/chain-signatures/getting-started"
},
"items": [
"Chain Signatures": [
"concepts/abstraction/chain-signatures",
"build/chain-abstraction/chain-signatures/getting-started",
'build/chain-abstraction/chain-signatures/chain-signatures',
// 'build/chain-abstraction/nft-chain-keys',
]
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading