Skip to content

Commit 411a3b9

Browse files
committed
docs: improve the readme
1 parent 65f9ca5 commit 411a3b9

1 file changed

Lines changed: 274 additions & 39 deletions

File tree

‎README.md‎

Lines changed: 274 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -5,73 +5,308 @@
55
<h1 align="center">Sunset</h1>
66

77
<p align="center">
8-
<strong>Shielded CLMM for Bitcoin wrappers and stablecoins on Conflux</strong>
8+
<strong>Shielded CLMM for Bitcoin wrappers and stablecoins on Conflux eSpace</strong>
99
</p>
1010

1111
<p align="center">
12-
<a href="#"><img src="https://img.shields.io/badge/Target-Conflux-orange?style=flat-square" alt="Conflux"/></a>
12+
<a href="#"><img src="https://img.shields.io/badge/Target-Conflux%20eSpace-orange?style=flat-square" alt="Conflux eSpace"/></a>
13+
<a href="#"><img src="https://img.shields.io/badge/Track-DeFi%20%2B%20AI-blue?style=flat-square" alt="DeFi and AI"/></a>
1314
<a href="#"><img src="https://img.shields.io/badge/Privacy-ZK%20Shielded-gold?style=flat-square" alt="Privacy"/></a>
14-
<a href="#"><img src="https://img.shields.io/badge/Focus-BTCfi%20%2B%20Stablecoins-blue?style=flat-square" alt="Focus"/></a>
15-
<a href="#"><img src="https://img.shields.io/badge/License-MIT-green?style=flat-square" alt="License"/></a>
15+
<a href="#"><img src="https://img.shields.io/badge/Focus-BTCfi%20%2B%20USDT0-green?style=flat-square" alt="BTCfi and USDT0"/></a>
1616
</p>
1717

18-
## Overview
18+
## Project Overview
1919

20-
**Sunset** is a privacy-native concentrated liquidity market maker built around Bitcoin wrappers and stablecoin routing on Conflux.
20+
**Sunset** is a privacy-native concentrated liquidity market maker for Bitcoin wrappers and stablecoin routing on **Conflux eSpace**.
2121

22-
The product thesis is:
22+
The protocol combines:
2323

24-
- private swaps,
25-
- private LP ranges,
26-
- shielded note-based balances,
27-
- and concentrated liquidity optimized for BTCfi and stablecoin depth.
24+
- shielded note balances,
25+
- private deposits and withdrawals,
26+
- private swap execution,
27+
- shielded LP position management,
28+
- and range-based liquidity for Bitcoin-heavy markets.
29+
30+
Sunset is designed for users who want to trade or provide liquidity in BTCfi and stablecoin pairs without exposing balances, range positions, or execution history by default.
31+
32+
## Why Conflux
33+
34+
Sunset is intentionally Conflux-first:
35+
36+
- it targets **Conflux eSpace** as the execution environment,
37+
- uses an EVM-compatible deployment pipeline tailored for Conflux,
38+
- is positioned around **USDT0** and Bitcoin wrapper liquidity,
39+
- and is structured to support low-friction retail DeFi usage with a privacy-preserving UX.
40+
41+
This project aligns especially well with:
42+
43+
- `Best DeFi project`,
44+
- `Best AI + Conflux integration`,
45+
- and the optional **USDT0 integration** bonus criteria.
46+
47+
## Problem
48+
49+
Most AMMs and CLMMs leak too much information:
50+
51+
- swap size and path are public,
52+
- LP ranges are public,
53+
- balances are easy to trace,
54+
- and strategy replication becomes trivial once an address is known.
55+
56+
That creates a poor environment for:
57+
58+
- Bitcoin treasury managers,
59+
- active LPs,
60+
- market makers,
61+
- and users who want practical onchain privacy without leaving DeFi.
62+
63+
## Solution
64+
65+
Sunset introduces a shielded execution layer on top of a concentrated liquidity design.
66+
67+
Core ideas:
68+
69+
- users can move assets into shielded notes,
70+
- zero-knowledge proofs authorize private state transitions,
71+
- nullifiers prevent double-spends,
72+
- commitments and Merkle roots manage shielded state,
73+
- and CLMM mechanics preserve capital efficiency for BTCfi and stablecoin markets.
2874

2975
## Core Markets
3076

31-
Sunset is designed around:
77+
Sunset is optimized around:
3278

3379
- `WBTC / USDT0`
3480
- `tBTC / USDT0`
3581
- `WBTC / USDC`
3682
- wrapper-to-wrapper Bitcoin markets
3783

38-
## Design Principles
39-
40-
- Privacy by default through commitments, nullifiers, and zk proofs.
41-
- Capital efficiency through CLMM price ranges instead of passive full-range liquidity.
42-
- Bitcoin-first market design.
43-
- Stablecoin expansion for routing, pricing, and settlement liquidity on Conflux.
84+
The first submission focus is the Bitcoin-wrapper plus stablecoin vertical on Conflux, with **USDT0** as the most important settlement and routing asset.
4485

4586
## Architecture
4687

47-
Sunset is organized around four protocol layers:
88+
The codebase is organized into four layers:
89+
90+
1. `frontend/`
91+
User-facing Conflux app for shielded deposits, swaps, withdrawals, and LP flows.
92+
2. `sdk/`
93+
TypeScript client logic, note management, crypto helpers, proving glue, and protocol operations.
94+
3. `asp/`
95+
Backend service for proving orchestration, Merkle synchronization, relay flow, and API endpoints.
96+
4. `contracts/solidity/`
97+
Conflux-oriented Solidity contracts for factory, pool logic, verifiers, and coordinator state.
98+
99+
The privacy stack uses commitments, nullifiers, Merkle proofs, and circuit artifacts under `circuits/`.
100+
101+
## Key Features
102+
103+
- Shielded deposits into private notes
104+
- Shielded withdrawals
105+
- Shielded swaps
106+
- Shielded liquidity provisioning and range updates
107+
- Conflux eSpace deployment support
108+
- Bitcoin-wrapper and stablecoin market orientation
109+
- USDT0-first token configuration
110+
- Off-chain proving and relay pipeline
111+
112+
## AI Component
113+
114+
Sunset includes an AI-ready coordination layer through its backend and SDK architecture, enabling agent-facing automation for privacy-preserving execution.
115+
116+
The current AI positioning is:
117+
118+
- automated strategy assistance for LP range management,
119+
- private execution planning for shielded swaps,
120+
- and agent-triggered transaction orchestration against Conflux-native liquidity.
121+
122+
This makes the project a credible candidate for the **AI + Conflux** bonus track when paired with the demo and submission narrative in [docs/hackathon/ai-positioning.md](docs/hackathon/ai-positioning.md).
123+
124+
## What Is Implemented
125+
126+
Current repository scope includes:
127+
128+
- a frontend application shell,
129+
- Conflux eSpace runtime configuration,
130+
- wallet integration with Cavos-oriented provider support,
131+
- SDK operations for deposit, withdraw, mint, burn, and swap,
132+
- Solidity contracts for pool factory, range pool, and verifier coordinator,
133+
- circuits and proof-generation scripts,
134+
- backend API handlers and sync logic,
135+
- unit and integration tests across major modules.
136+
137+
## Demo Assets
138+
139+
Existing UI screenshots are stored in:
140+
141+
- [frontend/docs/screenshots/landing.png](frontend/docs/screenshots/landing.png)
142+
- [frontend/docs/screenshots/dashboard.png](frontend/docs/screenshots/dashboard.png)
143+
- [frontend/docs/screenshots/shield.png](frontend/docs/screenshots/shield.png)
144+
- [frontend/docs/screenshots/swap.png](frontend/docs/screenshots/swap.png)
145+
- [frontend/docs/screenshots/positions.png](frontend/docs/screenshots/positions.png)
146+
- [frontend/docs/screenshots/pool.png](frontend/docs/screenshots/pool.png)
147+
- [frontend/docs/screenshots/settings.png](frontend/docs/screenshots/settings.png)
148+
149+
Submission-oriented demo guidance is documented in [demo/README.md](demo/README.md).
150+
151+
## Hackathon Submission Pack
152+
153+
The repository now includes a dedicated submission pack under [docs/hackathon](docs/hackathon):
154+
155+
- [Submission checklist tracker](docs/hackathon/submission-checklist.md)
156+
- [Submission playbook](docs/hackathon/submission-playbook.md)
157+
- [Go-to-market plan](docs/hackathon/go-to-market-plan.md)
158+
- [AI positioning](docs/hackathon/ai-positioning.md)
159+
- [Grant proposal draft](docs/hackathon/grant-proposal.md)
160+
- [Participant intro script](docs/hackathon/participant-intro-script.md)
161+
- [Social post template](docs/hackathon/social-post-template.md)
162+
- [Electric Capital PR checklist](docs/hackathon/electric-capital-checklist.md)
163+
164+
There is also a hackathon-repo-ready project page at [projects/sunset/README.md](projects/sunset/README.md).
165+
166+
## Hackathon Compliance
167+
168+
This repository is being prepared to match the current official Global Hackfest 2026 submission requirements:
169+
170+
- public GitHub repository,
171+
- open-source license,
172+
- setup and usage documentation,
173+
- required go-to-market plan,
174+
- `3 to 5 minute` demo video,
175+
- `30 to 60 second` participant intro video,
176+
- PR to `electric-capital/open-dev-data`,
177+
- social post tagging `@ConfluxDevs` and `@ConfluxNetwork`,
178+
- and a project folder under `/projects/` in the hackathon repo.
179+
180+
The exact operational checklist lives in [docs/hackathon/submission-checklist.md](docs/hackathon/submission-checklist.md).
181+
182+
## Quick Start
183+
184+
### Workspace
185+
186+
```bash
187+
bun install
188+
bun run env:sync
189+
bun run check:conflux
190+
```
191+
192+
### Frontend
193+
194+
```bash
195+
bun run dev:frontend
196+
```
197+
198+
### Backend
199+
200+
```bash
201+
bun run dev:asp
202+
```
203+
204+
### Full checks
205+
206+
```bash
207+
bun run check
208+
```
209+
210+
## Environment
211+
212+
Copy `.env.example` to `.env.local` and set:
213+
214+
- `CONFLUX_RPC_URL`
215+
- `VITE_POOL_ADDRESS`
216+
- `VITE_COORDINATOR_ADDRESS`
217+
- `ADMIN_PRIVATE_KEY`
218+
- and any token addresses for the desired Conflux environment
219+
220+
For frontend-only deployments, `.env.example` already includes working Conflux eSpace testnet defaults for:
221+
222+
- `VITE_POOL_ADDRESS`
223+
- `VITE_COORDINATOR_ADDRESS`
224+
- `VITE_TOKEN_0_*`
225+
- `VITE_TOKEN_1_*`
226+
227+
The repository includes a validator script:
228+
229+
```bash
230+
bun run check:conflux
231+
```
232+
233+
## Vercel Frontend Deploy
234+
235+
If you only want to deploy the frontend, Vercel is enough. The ASP is not required for the app to build and load, but shielded flows that require proving or note sync will not complete without a live ASP.
236+
237+
Use these project settings in Vercel:
238+
239+
```bash
240+
Install Command: bun install
241+
Build Command: bun run build:frontend
242+
Output Directory: frontend/dist
243+
```
244+
245+
Recommended environment variables for Vercel using the current Conflux eSpace testnet deployment:
246+
247+
```bash
248+
VITE_RPC_URL=https://evmtestnet.confluxrpc.com
249+
VITE_ASP_URL=https://example.invalid
250+
VITE_CHAIN_ID=71
251+
VITE_CHAIN_NAME=Conflux eSpace Testnet
252+
VITE_EXPLORER_URL=https://evmtestnet.confluxscan.org
253+
VITE_POOL_ADDRESS=0xf15DBD8216F5EFfD790EEfE2ae391DeD634d99d4
254+
VITE_COORDINATOR_ADDRESS=0xdB5ceE120dc582FB7951ABBe2850Dd6Ae8a8182c
255+
VITE_TOKEN_0_ADDRESS=0x12A47da35FD168e2962B7E82a8f7b1e7B31A28b9
256+
VITE_TOKEN_0_SYMBOL=WBTC
257+
VITE_TOKEN_0_NAME=Wrapped Bitcoin
258+
VITE_TOKEN_0_DECIMALS=8
259+
VITE_TOKEN_1_ADDRESS=0x7C9C0Cb06D1157404852DFC592f6510516dB8296
260+
VITE_TOKEN_1_SYMBOL=USDT0
261+
VITE_TOKEN_1_NAME=USDT0
262+
VITE_TOKEN_1_DECIMALS=6
263+
```
264+
265+
Those values come from [contracts/solidity/deployments/contracts.json](contracts/solidity/deployments/contracts.json).
266+
267+
## Smart Contract Commands
268+
269+
```bash
270+
cd contracts/solidity
271+
bun install
272+
bun run compile
273+
bun run test
274+
bun run deploy:conflux
275+
bun run deploy:conflux:testnet
276+
```
277+
278+
## Submission Status
279+
280+
This repository can satisfy most of the hackathon submission requirements directly from source control, but a few items still require manual completion outside the codebase:
48281

49-
1. Wallet and app layer for user interaction.
50-
2. Shielded note system for private balances and positions.
51-
3. CLMM execution layer for swaps, fee growth, and liquidity ranges.
52-
4. Off-chain proving and relay services for privacy-preserving execution flows.
282+
- social post publication,
283+
- PR to the official hackathon repo,
284+
- PR to the Electric Capital ecosystem page,
285+
- participant registration details,
286+
- and forum submission posting.
53287

54-
## Focus
288+
Those are tracked explicitly in [docs/hackathon/submission-checklist.md](docs/hackathon/submission-checklist.md).
55289

56-
Sunset is not a generic DEX. It is a specialized shielded liquidity venue for:
290+
For judges reviewing this repository directly, the intended evaluation mode is repo-first: source code, setup reproducibility, screenshots, deployment addresses, and local execution.
57291

58-
- wrapped Bitcoin,
59-
- stablecoin routing,
60-
- and private CLMM execution.
292+
## Team
61293

62-
## Repository Map
294+
Repository owner / submitter details should be completed before final submission:
63295

64-
- `frontend/`: app shell and user-facing vault UX
65-
- `sdk/`: client logic, storage, proving glue, and protocol helpers
66-
- `asp/`: off-chain proving and relay service
67-
- `contracts/solidity/`: Conflux-oriented Solidity contracts for factory, range pools, and proof coordination
296+
- Team name: `Sunset Protocol`
297+
- Sebastián Salazar ([GitHub](https://github.com/salazarsebas), Telegram: `salazarsebas`)
298+
- Kevin Membreño ([GitHub](https://github.com/KevinMB0220))
299+
- Josue Araya ([GitHub](https://github.com/Josue19-08))
300+
- Contact wallet for deployment / grant flows: `0x65D6352004da8F9aBFe54E937Cde76cc85B52bdc`
68301

69-
## Working Direction
302+
## Links
70303

71-
The current development focus is:
304+
- Source code: <https://github.com/SunsetLabs-Game/Sunset-Protocol>
305+
- Hackathon project page draft: [projects/sunset/README.md](projects/sunset/README.md)
306+
- Demo asset guide: [demo/README.md](demo/README.md)
307+
- Conflux documentation: <https://doc.confluxnetwork.org>
308+
- Conflux Global Hackfest repo: <https://github.com/conflux-fans/global-hackfest-2026>
72309

73-
- Conflux-first integration,
74-
- Bitcoin wrapper liquidity,
75-
- and stablecoin support including `USDT0`.
310+
## License
76311

77-
Sunset is a privacy-native concentrated liquidity market maker built around Bitcoin wrappers and stablecoin routing on Conflux.
312+
MIT

0 commit comments

Comments
 (0)