Setting up the development environment
TypeScript
Golem’s TypeScript toolchain uses npm as the underlying build tool. Install Node.js and npm on your system by following the official instructions .
Rust
Setup Rust
Developing Golem agents in Rust requires installing the latest stable compiler and enabling the WASM target used by Golem 1.5.
Installing Rust
Use the official guide to install the latest stable version of the Rust compiler.
For MacOS the recommended way is using rustup by running the following installation script:
$ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | shEnabling WebAssembly targets
With Rust and rustup installed, the next step is to enable the WebAssembly target used by Golem builds:
$ rustup target add wasm32-wasip2To verify if this step was successful, run:
$ rustup target list --installed | grep wasm32-wasip2
wasm32-wasip2Golem 1.5 uses the standard cargo build toolchain, so no additional cargo subcommands need to be installed.
Scala
Setup Scala
Developing Golem agents in Scala requires a Java Development Kit and sbt, because Golem 1.5 compiles Scala agents through Scala.js using an sbt plugin.
Installing Java
Install Java 17 or newer (JDK) using your preferred distribution.
Installing sbt
Install sbt by following the official installation guide .
Once Java and sbt are installed, golem build will drive the full Scala.js-based build pipeline for Scala components.
MoonBit
Setup MoonBit
Developing Golem agents in MoonBit requires the MoonBit toolchain and wasm-tools, because Golem 1.5 compiles MoonBit agents to WebAssembly using moon and packages them as components with wasm-tools.
Installing MoonBit
Install the latest stable version of the MoonBit toolchain by following the official instructions .
Installing wasm-tools
Install wasm-tools by following the official installation guide .
Once moon and wasm-tools are installed, golem build will install the required MoonBit dependencies and drive the full MoonBit-to-WASM build pipeline for MoonBit components.