Options for binary loading
Controls which native binary variant is loaded when creating a context. Use this for explicit GPU variant selection with automatic fallback.
Optional
GPU variant to use
If the requested variant is unavailable (missing runtime libraries), automatically falls back to CPU with a console warning.
// Request CUDA with automatic fallback to CPUconst ctx = await createContext( { modelPath: './model.gguf' }, { gpuVariant: 'cuda' }); Copy
// Request CUDA with automatic fallback to CPUconst ctx = await createContext( { modelPath: './model.gguf' }, { gpuVariant: 'cuda' });
Options for binary loading
Controls which native binary variant is loaded when creating a context. Use this for explicit GPU variant selection with automatic fallback.