summaryrefslogtreecommitdiff
path: root/e2/3eea34094e24b3dda1f72aff1cdecbe63f7b96
blob: fa0e3bd478792fcf44c7111483509b6dcca96569 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
Return-Path: <jlrubin@mit.edu>
Received: from smtp3.osuosl.org (smtp3.osuosl.org [IPv6:2605:bc80:3010::136])
 by lists.linuxfoundation.org (Postfix) with ESMTP id E7A2FC000A
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Fri,  9 Apr 2021 03:57:54 +0000 (UTC)
Received: from localhost (localhost [127.0.0.1])
 by smtp3.osuosl.org (Postfix) with ESMTP id BD72060E4A
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Fri,  9 Apr 2021 03:57:54 +0000 (UTC)
X-Virus-Scanned: amavisd-new at osuosl.org
X-Spam-Flag: NO
X-Spam-Score: 1.815
X-Spam-Level: *
X-Spam-Status: No, score=1.815 tagged_above=-999 required=5
 tests=[BAYES_50=0.8, BITCOIN_IMGUR=3.304, HTML_MESSAGE=0.001,
 RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001,
 T_KAM_HTML_FONT_INVALID=0.01] autolearn=no autolearn_force=no
Received: from smtp3.osuosl.org ([127.0.0.1])
 by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id uamYP7I8PBi4
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Fri,  9 Apr 2021 03:57:53 +0000 (UTC)
X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0
Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11])
 by smtp3.osuosl.org (Postfix) with ESMTPS id 5F4D060E47
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Fri,  9 Apr 2021 03:57:53 +0000 (UTC)
Received: from mail-io1-f44.google.com (mail-io1-f44.google.com
 [209.85.166.44]) (authenticated bits=0)
 (User authenticated as jlrubin@ATHENA.MIT.EDU)
 by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 1393vpKX018192
 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=NOT)
 for <bitcoin-dev@lists.linuxfoundation.org>; Thu, 8 Apr 2021 23:57:51 -0400
Received: by mail-io1-f44.google.com with SMTP id z3so4530262ioc.8
 for <bitcoin-dev@lists.linuxfoundation.org>;
 Thu, 08 Apr 2021 20:57:51 -0700 (PDT)
X-Gm-Message-State: AOAM531uVgGLoWG650jHreJ3iWrpMRJ4VFcBmoUBtqWtQDe5nGj4sJE8
 qyc6DeTJ2vgrDW3PSQ/n8bEj1LqbM6mV016HmmA=
X-Google-Smtp-Source: ABdhPJxuTZmGyXiC4jRUN7PMt+l4hkt8C+JKNdXezSbCAyZJF44XpvXjgfjPlJGB37tpkoTx9yu6/ys0gp5pKSVvI8Q=
X-Received: by 2002:a5d:8d12:: with SMTP id p18mr9865489ioj.31.1617940670981; 
 Thu, 08 Apr 2021 20:57:50 -0700 (PDT)
MIME-Version: 1.0
From: Jeremy <jlrubin@mit.edu>
Date: Thu, 8 Apr 2021 20:57:39 -0700
X-Gmail-Original-Message-ID: <CAD5xwhiwYLe8-0Ya2msJY5+XrTERCS20epALpqUPXz-0FEKZTg@mail.gmail.com>
Message-ID: <CAD5xwhiwYLe8-0Ya2msJY5+XrTERCS20epALpqUPXz-0FEKZTg@mail.gmail.com>
To: Bitcoin development mailing list <bitcoin-dev@lists.linuxfoundation.org>
Content-Type: multipart/alternative; boundary="000000000000f62c7905bf822ab2"
Subject: [bitcoin-dev] Designing Bitcoin Smart Contracts with Sapio
	(available on Mainnet today)
X-BeenThere: bitcoin-dev@lists.linuxfoundation.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Bitcoin Protocol Discussion <bitcoin-dev.lists.linuxfoundation.org>
List-Unsubscribe: <https://lists.linuxfoundation.org/mailman/options/bitcoin-dev>, 
 <mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=unsubscribe>
List-Archive: <http://lists.linuxfoundation.org/pipermail/bitcoin-dev/>
List-Post: <mailto:bitcoin-dev@lists.linuxfoundation.org>
List-Help: <mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=help>
List-Subscribe: <https://lists.linuxfoundation.org/mailman/listinfo/bitcoin-dev>, 
 <mailto:bitcoin-dev-request@lists.linuxfoundation.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Apr 2021 03:57:55 -0000

--000000000000f62c7905bf822ab2
Content-Type: text/plain; charset="UTF-8"

Bitcoin Developers,

I'm very excited to introduce Sapio[0] <https://github.com/sapio-lang/sapio>
formally to you all.

Sapio empowers Bitcoin Developers to craft smart contracts in an intuitive,
safe, and composable way. Sapio challenges the notion that you can't make
complex smart contracts for Bitcoin, and opens the floodgates for a myriad
of new ideas to be defined easily. Sapio works today on mainnet without any
protocol changes (via user-configurable multisig oracles, it will work
with BIP-119
OP_CHECKTEMPLATEVERIFY[1] <https://utxos.org> and Taproot when they are
available).

You can learn more about what's possible by reading *Designing Bitcoin
Smart Contracts with Sapio[2] <https://learn.sapio-lang.org>*. My Reckless
VR Talk[3] <https://judica.org/blog/sapio/> also does a great job of
breaking down the core programming model for Sapio contracts, although the
language has evolved substantially since I gave the talk.

As a concrete instance of Sapio working in the wild, I am currently
executing on mainnet a Congestion Control Tree[4]
<https://utxos.org/analysis/bip_simulation/> contract with 25 recipients
(the first Sapio contract to run on mainnet ever, as far as I'm aware). You
can review the source code, arguments, compiler outputs, and transactions
here[5]
<https://gist.github.com/JeremyRubin/1374f0916bfdef0bd36bc10d73852886>.

To see more examples of what you can do with Sapio, the repo includes
examples[6]
<https://github.com/sapio-lang/sapio/tree/master/sapio-contrib/src/contracts>
for derivatives, vaults, coin pools, games, side chains, and more. These
aren't intended to be production grade contracts -- yet -- but are
demonstrative of what can be built and how. I'm excited to see what people
build -- please open up PRs with your ideas or any issues you encounter
trying to implement them.

You can also try out Tux[7] <https://github.com/sapio-lang/tux>, an
experimental GUI, to inspect, simulate, and interact with smart contracts.
You can see the Congestion Control Tree mentioned earlier loaded in Tux
below[8] <https://i.imgur.com/pg5SqfH.png>:




This is still early work-in-progress software, so tread lightly and use
regtest. Enough of the components work today that it was appropriate to
share now and invite more developers to contribute or otherwise support the
project.

Sapio is developed free and open source for all bitcoiners by Judica.org
(my organization).

Thank you to all who have helped reach this milestone of the first mainnet
Sapio contract, including Ryan Grant, BitMEX, ACINQ, Delphi Digital,
Backend Capital, my github sponsors https://github.com/sponsors/jeremyrubin,
and numerous other supporters both fiscal and technical. I also want to
highlight the excellent work done on Miniscript and the rust-bitcoin
ecosystem, the foundation upon which Sapio rests.

[0] https://github.com/sapio-lang/sapio
[1] https://utxos.org
[2] https://learn.sapio-lang.org
[3] https://judica.org/blog/sapio/
[4] https://utxos.org/analysis/bip_simulation/
[5] https://gist.github.com/JeremyRubin/1374f0916bfdef0bd36bc10d73852886
[6]
https://github.com/sapio-lang/sapio/tree/master/sapio-contrib/src/contracts
[7] https://github.com/sapio-lang/tux
[8] https://imgur.com/pg5SqfH


Eager for you feedback,

Jeremy

--
@JeremyRubin <https://twitter.com/JeremyRubin>
<https://twitter.com/JeremyRubin>

--000000000000f62c7905bf822ab2
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_default" style=3D"font-family:arial,he=
lvetica,sans-serif;font-size:small;color:#000000">Bitcoin Developers,</div>=
<div class=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-seri=
f;font-size:small;color:#000000"><br></div><div class=3D"gmail_default" sty=
le=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:#000000"=
>I&#39;m very excited to introduce <a href=3D"https://github.com/sapio-lang=
/sapio">Sapio[0]</a> formally to you all.</div><div class=3D"gmail_default"=
 style=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:#000=
000"><br></div>Sapio empowers Bitcoin Developers to craft smart contracts i=
n an intuitive, safe, and composable way. Sapio challenges the notion that =
you can&#39;t make complex smart contracts for Bitcoin, and opens the flood=
gates for a myriad of new ideas to be defined easily.<span class=3D"gmail_d=
efault" style=3D"font-family:arial,helvetica,sans-serif;font-size:small;col=
or:rgb(0,0,0)"> </span>Sapio works today on mainnet without any protocol ch=
anges (via user-configurable multisig oracles, it will work with <a href=3D=
"https://utxos.org">BIP-119 OP_CHECKTEMPLATEVERIFY[1]</a> and Taproot when =
they are available).<br><div class=3D"gmail_default" style=3D"font-family:a=
rial,helvetica,sans-serif;font-size:small;color:#000000"><br></div><div cla=
ss=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-serif;font-s=
ize:small;color:#000000">You can learn more about what&#39;s possible by re=
ading <i><a href=3D"https://learn.sapio-lang.org">Designing Bitcoin Smart C=
ontracts with Sapio[2]</a></i>. My <a href=3D"https://judica.org/blog/sapio=
/">Reckless VR Talk[3]</a>  also does a great job of breaking down the core=
 programming model for Sapio contracts, although the language has evolved s=
ubstantially since I gave the talk.<br></div><div class=3D"gmail_default" s=
tyle=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:#00000=
0"><br></div><div class=3D"gmail_default" style=3D"font-family:arial,helvet=
ica,sans-serif;font-size:small;color:#000000">As a concrete instance of Sap=
io working in the wild, I  am currently executing on mainnet a <a href=3D"h=
ttps://utxos.org/analysis/bip_simulation/">Congestion Control Tree[4]</a> c=
ontract with 25 recipients (the first Sapio  contract to run on mainnet eve=
r, as far as I&#39;m aware). You can review the source code, arguments, com=
piler outputs, and transactions <a href=3D"https://gist.github.com/JeremyRu=
bin/1374f0916bfdef0bd36bc10d73852886">here[5]</a>.</div><div class=3D"gmail=
_default" style=3D"font-family:arial,helvetica,sans-serif;font-size:small;c=
olor:#000000"><br></div><div class=3D"gmail_default" style=3D"font-family:a=
rial,helvetica,sans-serif;font-size:small;color:#000000">To see more exampl=
es of what you can do with Sapio, the repo includes  <a href=3D"https://git=
hub.com/sapio-lang/sapio/tree/master/sapio-contrib/src/contracts">examples[=
6]</a> for derivatives, vaults, coin pools, games, side chains, and more. T=
hese aren&#39;t intended to be production grade contracts -- yet -- but are=
 demonstrative of what can be built and how. I&#39;m excited to see what pe=
ople build -- please open up PRs with your ideas or any issues you encounte=
r trying to implement them.<br></div><div><br></div><div><span class=3D"gma=
il_default" style=3D"font-family:arial,helvetica,sans-serif;font-size:small=
;color:rgb(0,0,0)">You</span> can<span class=3D"gmail_default" style=3D"fon=
t-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"> also=
</span> <span class=3D"gmail_default" style=3D"font-family:arial,helvetica,=
sans-serif;font-size:small;color:rgb(0,0,0)">try out</span> <a href=3D"http=
s://github.com/sapio-lang/tux">Tux[7]</a>, a<span class=3D"gmail_default" s=
tyle=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,=
0,0)">n experimental</span> GUI<span class=3D"gmail_default" style=3D"font-=
family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)">,</span=
> <span class=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-s=
erif;font-size:small;color:rgb(0,0,0)">to</span> inspect, simulat<span clas=
s=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-serif;font-si=
ze:small;color:rgb(0,0,0)">e</span>, and interact with smart contracts. You=
 can see the Congestion Control Tree mentioned earlier loaded in Tux <a hre=
f=3D"https://i.imgur.com/pg5SqfH.png">below[8]</a>: </div><div class=3D"gma=
il_default" style=3D"font-family:arial,helvetica,sans-serif;font-size:small=
;color:#000000"><br></div><div class=3D"gmail_default" style=3D"font-family=
:arial,helvetica,sans-serif;font-size:small;color:#000000"><div style=3D"te=
xt-align:center"><img src=3D"https://i.imgur.com/pg5SqfH.png" width=3D"570"=
 height=3D"301"><br></div><br></div><div class=3D"gmail_default" style=3D"f=
ont-family:arial,helvetica,sans-serif;font-size:small;color:#000000"><br></=
div><div class=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-=
serif;font-size:small;color:#000000">This is still early work-in-progress s=
oftware, so tread lightly and use regtest. Enough of the components work to=
day that it was appropriate to share now and invite more developers to cont=
ribute or otherwise support the project.<br></div><div class=3D"gmail_defau=
lt" style=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:#=
000000"><br></div><div class=3D"gmail_default" style=3D"font-family:arial,h=
elvetica,sans-serif;font-size:small;color:#000000">Sapio is developed free =
and open source for all bitcoiners by Judica.org (my organization).</div><d=
iv class=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-serif;=
font-size:small;color:#000000"><br></div><div class=3D"gmail_default" style=
=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:#000000">T=
hank you to all who have helped reach this milestone of the first mainnet S=
apio contract, including Ryan Grant, BitMEX, ACINQ, Delphi Digital, Backend=
 Capital, my github sponsors <a href=3D"https://github.com/sponsors/jeremyr=
ubin">https://github.com/sponsors/jeremyrubin</a>, and numerous other suppo=
rters both fiscal and technical. I also want to highlight the excellent wor=
k done on Miniscript and the rust-bitcoin ecosystem, the foundation upon wh=
ich Sapio rests.<br></div><div class=3D"gmail_default" style=3D"font-family=
:arial,helvetica,sans-serif;font-size:small;color:#000000"><br></div><div c=
lass=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-serif;font=
-size:small;color:#000000">[0] <a href=3D"https://github.com/sapio-lang/sap=
io">https://github.com/sapio-lang/sapio</a></div><div class=3D"gmail_defaul=
t" style=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:#0=
00000">[1] <a href=3D"https://utxos.org">https://utxos.org</a></div><div cl=
ass=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-serif;font-=
size:small;color:#000000">[2] <a href=3D"https://learn.sapio-lang.org">http=
s://learn.sapio-lang.org</a></div><div class=3D"gmail_default" style=3D"fon=
t-family:arial,helvetica,sans-serif;font-size:small;color:#000000">[3] <a h=
ref=3D"https://judica.org/blog/sapio/">https://judica.org/blog/sapio/</a></=
div><div class=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-=
serif;font-size:small;color:#000000">[4] <a href=3D"https://utxos.org/analy=
sis/bip_simulation/">https://utxos.org/analysis/bip_simulation/</a></div><d=
iv class=3D"gmail_default" style=3D"font-family:arial,helvetica,sans-serif;=
font-size:small;color:#000000">[5] <a href=3D"https://gist.github.com/Jerem=
yRubin/1374f0916bfdef0bd36bc10d73852886">https://gist.github.com/JeremyRubi=
n/1374f0916bfdef0bd36bc10d73852886</a></div><div class=3D"gmail_default" st=
yle=3D"font-family:arial,helvetica,sans-serif;font-size:small;color:#000000=
">[6] <a href=3D"https://github.com/sapio-lang/sapio/tree/master/sapio-cont=
rib/src/contracts">https://github.com/sapio-lang/sapio/tree/master/sapio-co=
ntrib/src/contracts</a></div><div class=3D"gmail_default" style=3D"font-fam=
ily:arial,helvetica,sans-serif;font-size:small;color:#000000">[7] <a href=
=3D"https://github.com/sapio-lang/tux">https://github.com/sapio-lang/tux</a=
></div><div class=3D"gmail_default" style=3D"font-family:arial,helvetica,sa=
ns-serif;font-size:small;color:#000000">[8] <span style=3D"background:unset=
;background-blend-mode:unset;border:unset;border-radius:unset;display:unset=
;float:unset;clear:unset;vertical-align:unset;overflow:unset;isolation:unse=
t;break-after:unset;break-before:unset;break-inside:unset;columns:unset;col=
umn-fill:unset;column-rule:unset;column-span:unset;opacity:unset;mix-blend-=
mode:unset;font:unset;font-synthesis:unset;writing-mode:unset;text-orientat=
ion:unset;image-orientation:unset;border-collapse:unset;empty-cells:unset;c=
aption-side:unset;border-spacing:unset;color:unset;text-transform:unset;tex=
t-indent:unset;word-break:unset;text-justify:unset;text-align-last:unset;te=
xt-align:unset;letter-spacing:unset;word-spacing:unset;white-space:pre;text=
-emphasis:unset;line-break:unset;text-combine-upright:unset;text-underline-=
position:unset;list-style:unset;quotes:unset;margin:unset;outline:unset;pad=
ding:unset;width:unset;min-width:unset;max-width:unset;height:unset;min-hei=
ght:unset;max-height:unset;box-sizing:unset;object-fit:unset;object-positio=
n:unset;table-layout:unset;text-overflow:unset;text-decoration:unset;ime-mo=
de:unset"><a href=3D"https://imgur.com/pg5SqfH">https://imgur.com/pg5SqfH</=
a></span></div><div class=3D"gmail_default" style=3D"font-family:arial,helv=
etica,sans-serif;font-size:small;color:#000000"><br></div><div class=3D"gma=
il_default" style=3D"font-family:arial,helvetica,sans-serif;font-size:small=
;color:#000000"><br></div><div class=3D"gmail_default" style=3D"font-family=
:arial,helvetica,sans-serif;font-size:small;color:#000000">Eager for you fe=
edback,</div><div class=3D"gmail_default" style=3D"font-family:arial,helvet=
ica,sans-serif;font-size:small;color:#000000"><br></div><div class=3D"gmail=
_default" style=3D"font-family:arial,helvetica,sans-serif;font-size:small;c=
olor:#000000">Jeremy<br></div><br clear=3D"all"><div><div dir=3D"ltr" class=
=3D"gmail_signature" data-smartmail=3D"gmail_signature"><div dir=3D"ltr">--=
<br><a href=3D"https://twitter.com/JeremyRubin" target=3D"_blank">@JeremyRu=
bin</a><a href=3D"https://twitter.com/JeremyRubin" target=3D"_blank"></a></=
div></div></div></div>

--000000000000f62c7905bf822ab2--