-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathREADME.txt
More file actions
24 lines (13 loc) · 1.11 KB
/
README.txt
File metadata and controls
24 lines (13 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
Decentralized Exchange (DEX) - Solidity
A peer-to-peer automated market maker (AMM) built on Ethereum.
This protocol allows users to swap ERC-20 tokens, provide liquidity to earn fees, and maintain a trustless environment without a central intermediary.
## Core Features
Automated Market Making (AMM): Uses the Constant Product formula $x \cdot y = k$ to determine asset prices.
Liquidity Provision: Users can deposit token pairs into the pool to receive Liquidity Provider (LP) tokens.
Token Swaps: Instant execution of trades between supported ERC-20 pairs.
Fee Mechanism: A percentage fee (e.g., 0.3%) is collected on every trade and distributed proportionally to LP holders.
## Technical Architecture:
The system is designed with modularity and security in mind:
Factory Contract: Responsible for deploying and indexing individual exchange pairs.
Pair Contract: The core logic engine that holds the reserves, manages the k value, and executes the swap, mint, and burn functions.
Router Contract:A wrapper that simplifies user interactions, handles multi-hop swaps, and manages "safety" checks like slippage tolerance.