Cargo Features

mistralrs-core has no features set by default.

[dependencies]
mistralrs-core = { version = "0.8.1", features = ["pyo3_macros", "cuda", "cudnn", "metal", "flash-attn", "flash-attn-v3", "accelerate", "mkl", "nccl", "utoipa", "ring", "accelerate-src", "intel-mkl-src"] }
pyo3_macros = pyo3

Enables pyo3_macros of mistralrs-mcp

cuda flash-attn? flash-attn-v3? nccl?

Enables cudaforge, cuda of candle-core and candle-nn, cuda of mistralrs-paged-attn and mistralrs-quant

Affects gdn::gated_delta_rule_recurrence_cuda, gdn::chunked_gated_delta_rule_recurrence_cuda, gdn::causal_conv1d_cuda, gdn::fused_gdn_gating_cuda, moe::moe_gemm, moe::moe_gemm_transposed, ssm::selective_scan_cuda, forward::should_use_mla_decode, forward::should_use_mla_cache, forward::mla_decode_forward, forward::mla_cache_forward, ops::cuda_topk_softmax, layers::paged_attention, utils::paged_attn_supported

cudnn

Enables cudnn of candle-core

metal

Enables candle-metal-kernels, objc and objc2-metal, metal of candle-core, metal of candle-nn, mistralrs-paged-attn, and mistralrs-quant

Affects gdn::gated_delta_rule_recurrence_metal, gdn::chunked_gated_delta_rule_recurrence_metal, gdn::causal_conv1d_metal, gdn::fused_gdn_gating_metal, ssm::selective_scan_metal, layers::paged_attention, utils::paged_attn_supported

flash-attn = cuda

Enables candle-flash-attn

Affects utils::using_flash_attn

flash-attn-v3 = cuda

Enables candle-flash-attn-v3

Affects utils::using_flash_attn

accelerate

Enables accelerate of candle-core, candle-nn, and mistralrs-quant

mkl

Enables mkl of candle-core and candle-nn

nccl = cuda

Enables nccl of mistralrs-quant

utoipa

Enables utoipa

ring

Enables ring of mistralrs-quant

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

accelerate-src implicit feature

Enables accelerate-src

accelerate-src:

The package provides a source of BLAS and LAPACK via the Accelerate framework

intel-mkl-src implicit feature

Enables intel-mkl-src

intel-mkl-src:

Redistribution of Intel(R) MKL as a crate

pyo3 pyo3_macros?

Enables pyo3 ^0.25.1