Proposed by: Shivay Lamba

Superpowers to Serverless functions with WebAssembly

Machine Learning inference is often a computationally intensive task. Special need to be taken care of the performance when running serverless & edge computation. This is where WebAssembly shines. Because of the small size of WASM modules and quick startup time, WebAssembly finds a lot of use-cases in serverless and cloud. Learn with the help of an example how to use WebAssembly based serverless functions to run AI inference with added features of security, platform independence with WASM.




Hot topic for 2022 and 2023 are Rust programming language and use of Webassembly from Browser to Servers/Serverless and Cloud. Machine Learning on the edge is an idea being greatly explored to further expand the horizons of where Machine Learning could be deployed. Machine Learning inference is often a computationally intensive task and edge applications could greatly benefit from the speed of WebAssembly. Unfortunately, Linux containers end up being too heavy for such tasks Because of the small size of WASM modules and quick startup time, WebAssembly finds a lot of use-cases in serverless and cloud. The reason to use WebAssembly is to further improve performance. High-performance functions written in C/C++, Rust, and Swift can be easily compiled into WebAssembly. Those WebAssembly functions are much faster than JavaScript or Python commonly used in serverless functions. WebAssembly offers fine-grained runtime separation for certain functions, to start. A microservice might operate a number of supporting services and functions inside a container similar to Docker. The microservice can become more dependable and safe with WebAssembly. The bytecode for WebAssembly is portable. Developers don't have to worry about upgrades or modifications to the underlying Vercel serverless container because they just need to construct it once (OS and hardware). The same WebAssembly functions can also be reused by developers in other cloud environments. Thirdly, managing and deploying WebAssembly apps is simple. When compared to other executables, they are far simpler and have less platform dependencies. With the WASMEDGE, it can extend the WebAssembly sandbox security model to support native “command” modules. The hybrid model enables WASMEDGE FaaS to safely run WebAssembly functions that perform AI inference at full native speed. Thus WebAssembly is the future for containerless and serverless future

Source code/Reference: https://twitter.com/howdevelop

Talk duration: