Why WebAssembly?
Asterai uses WebAssembly (WASM) as its portable execution format. This gives us:- 🌐 Language independence: Any language that compiles to WASM works with asterai
- 🔒 Sandboxed execution: Components run in isolation with explicit permissions
- ⚡ Near-native performance: WASM executes efficiently on any platform
- 📤 Portability: The same compiled component runs locally, in the cloud, or at the edge
WASI and the Component Model
Asterai uses WASI (WebAssembly System Interface) Preview 2 and the WebAssembly Component Model. This is an emerging standard for building modular, composable WebAssembly applications. Key concepts:- Components: Self-contained units with typed interfaces (not just raw WASM modules)
- WIT (WebAssembly Interface Types): A language for defining component interfaces
- Composition: Components can import and export functionality, enabling true modularity
⚠️ Experimental Technology
The WebAssembly Component Model is still evolving. Asterai is making a bet on this technology as the future of modular, portable software. What this means for you:- 🔧 Tooling is improving rapidly: Expect better error messages and faster compilation over time
- 🚧 Some rough edges: You may encounter edge cases or limitations
- 🔄 Breaking changes possible: The underlying standards are stabilizing but not frozen