3em
A blazingly fast, secure, reliable, multi-language execution machine for Smart Contracts.
Install / Use
/learn @three-em/3emREADME
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:
- Speed
- Security
- Multi-language support
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:
- Startup time
- Filesystem cache
- Execution performance
- Interaction loading
$ 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


- The JavaScript contract used in
3em JSandSmartWeave JSist9T7DIOGxx4VWXoCEeYYarFYeERTpWIC1V3y-BPZgKE. - The WebAssembly contract source used in
3em WASMcan be found here. The block height is not fixed. - The EVM contract source used in
3em EVMcan be found here. The block height is not fixed. - There are functional differences between evm and wasm contracts and the number of interactions (except the JavaScript contract).
fh= Fixed height of749180- The gateway used is
arweave.net
Multi-language support
3em supports contracts written in:
- JavaScript
- WebAssembly (Rust, AssemblyScript, etc.)
- EVM bytecode (Solidity, Yul, etc)
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:
- Contracts need to be deployed to Arweave in order for 3EM to run them
- 3em is capable of running existing Smartweave contracts and exposes backward
compatible APIs (like the
SmartWeaveglobal)
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
three_em run- Runs a contract deployed to Arweave given certain options.
three_em dry-run- Runs a local contract which has not yet been deployed to Arweave.
- Only JS and WASM contracts are accepted during
dry-run.
three_em serve- Spawns a local server with an endpoint to evaluate contracts.
run
The following flags are available for three_em run:
--host|string- URL of gateway to be used during execution
- Default: arweave.net
--port|number- Port of gateway to be used during execution
- Default: 443
--protocol|string- Network protocol to be used during execution
- Default: https
--contract-id|string- ID of contract to be evaluated
--pretty-print|boolean- Whether output should be printed in a prettified JSON form
- Default: false
--no-print|boolean- Whether output should be printed in the console. True will not print any output
- Default: false
--show-validity|boolean- Whether output should contain the validity table of evaluated interactions
--save|string- If provided, it contains a file path where output will be saved in JSON form
--benchmark|boolean- Whether to benchmark the execution time of the contract
- Default: false
--height|number- Maximum height to be used during evaluation
--no-cache- Whether it should use 3em's built-in cache system
--show-errors- Whether errors from failed interactions should be printed
Example
three_em run --contract-id t9T7DIOGxx4VWXoCEeYYarFYeERTpWIC1V3y-BPZgKE
dry-run
The following flags are available for three_em dry-run:
--file- File path for dry run JSON input.
- Please refer to our dry run documentation here
--host|string- URL of gateway to be used during execution
- Default: arweave.net
--port|number- Port of gateway to be used during execution
- Default: 443
--protocol|string- Network protocol to be used during execution
- Default: https
--pretty-print|boolean- Whether output should be printed in a prettified JSON form
- Default: false
--show-validity|boolean- Whether output should contain the validity table of evaluated interactions
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:
--host|string- Host to be used by the server
- Default: 127.0.0.1
--port|number- Port to be used by the server
- Default: 5400
Example
three_em serve
Related Skills
himalaya
354.3kCLI to manage emails via IMAP/SMTP. Use `himalaya` to list, read, write, reply, forward, search, and organize emails from the terminal. Supports multiple accounts and message composition with MML (MIME Meta Language).
node-connect
354.3kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
taskflow
354.3kUse when work should span one or more detached tasks but still behave like one job with a single owner context. TaskFlow is the durable flow substrate under authoring layers like Lobster, ACPX, plugins, or plain code. Keep conditional logic in the caller; use TaskFlow for flow identity, child-task linkage, waiting state, revision-checked mutations, and user-facing emergence.
frontend-design
112.3kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
