Menu

(How) Can LLMs run in the browser?
📰

(How) Can LLMs run in the browser?

DEV Community: rust·pielouNW·about 2 hours ago
#ZW2iUyVy
#devtorust#devto#dev#browser#browsers
Reading 0:00
15s threshold

A big push here at NobodyWho is to get language models running in the browser using WebAssembly.

After working on it for a few weeks we've gotten a good idea of the landscape. One thing that's very clear, and this will come as a surprise, is that browsers are actually kinda complicated.

First, we use Rust at NobodyWho, and there are (at least) three different compilation targets for Rust for WASM: Emscripten, WASI, and wasm32-unknown-unknown with wasm-bindgen . All with different levels of support in various dependencies and within Rust itself.

Second, there are (at least) three different hardware backends: CPU, WebGPU, and WebNN, with the last two being the only reasonably fast ones and both being very new or experimental.

Third, there's the question of whether the LLM will be running in a website or a browser extension.

Fourth, and importantly, there are many different browsers and many different browser versions.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.