Cargo Features

[dependencies]
metal-candle = { version = "1.3.0", default-features = false, features = ["custom-metal", "embeddings", "graph", "async-exec", "streaming"] }
default = custom-metal, graph

These default features are set whenever metal-candle is added without default-features = false somewhere in the dependency tree.

custom-metal default

custom-metal enables Metal GPU acceleration (macOS only)
This also enables the metal feature on candle-core

Enables candle-metal-kernels ^0.9, metal ^0.27, and objc

candle-metal-kernels:

Custom Metal kernels (for performance optimization)
Must match candle-core's metal version (0.27)
These are only used on macOS via the custom-metal feature

and metal of candle-core ^0.9

Candle - ML framework
Metal features added via custom-metal feature flag (macOS only)
Disable default features to avoid pulling in platform-specific dependencies

Affects backend::custom_ops, backend::metal_kernels, backend::metal_ops

embeddings

Affects metal-candle::embeddings

graph default async-exec?

Lazy evaluation framework (v2.0+)

Affects metal-candle::graph

async-exec = graph

Async execution (Phase 5)

Enables tokio

Async runtime (for streaming and async execution)

and async-trait and dashmap ^5.5

dashmap:

Lock-free data structures (for Phase 5)

Affects graph::async_executor

streaming

Async streaming inference

Enables async-stream, futures, and tokio