The execution environment for Intelligent Contracts in the GenLayer protocol.
GenVM executes Intelligent Contracts — which can contain non-deterministic code — while preserving blockchain security and consistency. This repository is the umbrella (manager) that builds GenVM from its parts: the executor, the runners, the modules, and the install/manifest pipeline.
This is a monorepo for GenVM. It is composed of the following sub-projects:
executors/— the core GenVM executor (a genvm-executor submodule, pinned per version train) plus therunners/available to contracts (software floating point, the Python interpreter with built-in bindings to the GenVM WASM module, the GenLayer Python standard library, ...). The executor is a modifiedwasmtimethat exposes thegenvm-sdk-wasiimplementation and performs all sandboxing.implementation/— the manager and modules (LLM, web).libs/,support/— shared libraries and build/CI tooling.
Required tools:
- git
- ruby (3.*)
- ninja
- rustup (cargo + rustc)
- (for runners) nix and an x86_64 system
All of them (except git, for obvious reasons) are provided by the default shell in
build-scripts/devenv/flake.nix (for direnv add use flake ./build-scripts/devenv).
cd $PROJECT_DIRgit submodule update --init --recursive --depth 1source env.sh(not needed if you used the flake)git third-party update --allgenvm-tool configure— scrapes and configures all targets (similar to CMake). Outside the dev shell usesupport/tools/genvm-tool/genvm-tool configure.ninja -C build(orninja -C build all/bin) — output is atbuild/outas a root (bin,share)- Get
genvm-runners.zipfrom GitHub - Merge
build/outandgenvm-runners.zip
WARNING: currently supported only on x86_64 Linux hosts.
cd $PROJECT_DIRnix build -o build/out-universal -v -L .#all-for-platform.universalnix build -o build/out-amd64-linux -v -L .#all-for-platform.amd64-linux- Merge outputs
GenVM's only purpose is to execute Intelligent Contracts. For getting-started documentation, see the GenLayer documentation. For more complex examples, look into the test suite.
PRs accepted. See the contributing guide.
Business Source License 1.1 © GenLayer Labs Corp.