Home

Awesome

<p align="center"> <img src="https://3em.dev/logo.svg" alt="3em Logo" width="110" height="110"> <h3 align="center">3em</h3> <p align="center"> A blazingly fast, secure, reliable, multi-language execution environment for smart contracts inside the <a href="https://arweave.org">Arweave</a> ecosystem. </p> </p> <p align="center"> Special thanks to: <ul> <li> <a href="https://verto.exchange">Verto Exchange</a> for incubating this project as well as all their members which have been key part of conceiving 3em. </li> </ul> </p>

Purpose

3em was conceived as an alternate solution to SmartWeave while still accomplishing the same goal: Simple & Scalable smart contracts on the Arweave protocol.

After receiving multiple feedback from different individuals and teams, we realize there were 3 main issues that needed to be solved:

For more information on how we solved the issues mentioned above, please refer to our technical guide.

Install

With Shell:

curl -fsSL https://3em.dev/install.sh | sh

With PowerShell:

iwr https://3em.dev/install.ps1 -useb | iex

CLI benchmarks

Measures:

$ hyperfine 'target/release/bench' 'target/release/bench_evm' 'target/release/bench_wasm' 'node tools/benchmarks/smartweave/index.js' 'target/release/bench_fh' -r 20 --export-json bench.json

Multi-language support

3em supports contracts written in:

Please refer to the "helpers" for details on writing contracts.

Javascript Library

3EM can be integrated in both client and server side through the Javascript library.

Please click here for more information.

Smartweave Compatability

3em follows the SmartWeave contract design. This essentially means two things:

Determinism

3em execution is deterministic. Random operations have a constant seed and Non deterministic APIs are overriden with their deterministic version. You can read more about it in our technical guide.

CLI

Available Commands


run

The following flags are available for three_em run:

Example

three_em run --contract-id t9T7DIOGxx4VWXoCEeYYarFYeERTpWIC1V3y-BPZgKE

dry-run

The following flags are available for three_em dry-run:

dry-run requires a JSON file containing the dry-run structure, for more information about it please refer to our dry run guide.


serve

The following flags are available for three_em serve:

Example

three_em serve