WebLLMLoadProgress
Progress information emitted during model download and WebGPU shader compilation.
Defined in: src/providers/llm/webllm/WebLLMLLM.ts:49
Progress information emitted during model download and WebGPU shader compilation.
Remarks
Wire this to a progress bar or loading indicator in your UI. The initial model download can be 100 MB+ and shader compilation takes additional time, so providing visual feedback is essential for good UX.
See
WebLLMLLMConfig.onLoadProgress for the callback that receives these events.
Properties
| Property | Type | Description | Defined in |
|---|---|---|---|
progress | number | Download/compilation progress as a fraction between 0 and 1. Remarks Multiply by 100 for a percentage value. | src/providers/llm/webllm/WebLLMLLM.ts:56 |
text | string | Human-readable description of the current loading phase. Example 'Downloading model weights (45%)'`, `'Compiling shaders...' | src/providers/llm/webllm/WebLLMLLM.ts:66 |
timeElapsed | number | Time elapsed since the load started, in seconds. | src/providers/llm/webllm/WebLLMLLM.ts:60 |