> For the complete documentation index, see [llms.txt](https://docs.sat20.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sat20.org/english/learn-understanding-satoshinet/smart-contracts-and-gas.md).

# Smart Contracts and GAS

The SatoshiNet smart contract framework has been implemented and entered public testnet testing. STP + indexers solve how assets are identified, verified, safely entered, and safely exited. Smart contracts solve what assets can do after entering SatoshiNet.

With smart contracts, SatoshiNet can evolve from an asset circulation network into an application network.

## Why Smart Contracts Matter

Bitcoin L1 is suitable as a final settlement layer, but not for directly carrying complex applications. SatoshiNet smart contracts support the following while preserving Bitcoin-native asset facts, entry paths, and exit capability:

1. AMMs and asset trading.
2. Stablecoins and payments.
3. Asset issuance and composition.
4. Games, DePIN, RWA, and other applications.
5. AI Agent-triggered and AI Agent-managed automated contracts.

## Role of GAS

GAS is the resource metering and fee entry point for the contract network. It is not merely "an asset"; it serves three purposes:

1. Preventing cost-free occupation of network resources.
2. Pricing contract execution, verification, storage, and transaction processing.
3. Creating an economic connection among developers, nodes, applications, and users.

The public GAS narrative focuses on utility, consumption paths, risks, and limitations. It can attract ecosystem attention, but long-term value comes from real applications and real resource consumption.

## Contract Roadmap

SatoshiNet smart contracts are progressing along several paths:

| Phase                        | Goal                                                                                                                                                  |
| ---------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| Template contracts           | Currently testing AMM and limit order in PWA `Tools -> Smart Contracts`, using deterministic templates for common trading scenarios                   |
| EVM compatibility            | Currently testing `ConstantProductAMM` and `LimitOrderBook` samples in PWA `Tools -> Smart Contracts`, reusing the Solidity / EVM developer ecosystem |
| Agent / Prediction contracts | First Agent contract scenario prioritized on public testnet                                                                                           |
| Natural language contracts   | Explore new interaction patterns between AI Agents and contracts                                                                                      |

Ordinary users can start from [Prediction Contract Test](/english/use-satoshinet/prediction-contract.md). Template contracts and EVM samples are accessed through PWA `Tools -> Smart Contracts`. Protocol design docs: [Smart Contract Protocol](/english/protocol-and-security/smart-contracts/contracts.md).
