Skip to content

Feature Flags

PMetal uses Cargo feature flags to control which crates and capabilities are compiled.

FeatureDefaultCrateDescription
coreYespmetal-coreFoundation types, configs, traits
ggufYespmetal-ggufGGUF format support
metalYespmetal-metalMetal GPU kernels
hubYespmetal-hubHuggingFace Hub integration
distributedYespmetal-distributedMulti-Mac discovery, all-reduce, pipeline harnesses
cliYespmetalCommand-line binary and shared CLI dependencies
dashboardYesRatatui terminal TUI
trainerYespmetal-trainerSFT, LoRA/QLoRA, pretraining, GRPO, RLKD, distillation orchestration
loraYespmetal-loraLoRA/QLoRA adapters
mergeYespmetal-mergeModel merging strategies and save pipeline
aneYespmetal-metal, pmetal-trainer, pmetal-modelsApple Neural Engine integration
mlxYespmetal-mlxMLX backend
modelsYespmetal-modelsLLM architectures
dataYespmetal-dataDataset loading, tokenization, chat templates
distillYes*pmetal-distillKnowledge distillation (*via trainer)
lora-metal-fusedNo~2× LoRA training speedup via fused Metal kernels
native-onlyNopmetal-bridgeBridge-only native runtime without the full MLX feature set
vocoderNopmetal-vocoderBigVGAN neural vocoder
mhcNopmetal-mhcManifold-Constrained Hyper-Connections
serveNopmetal-serveOpenAI-compatible inference server
mcpNopmetal-mcpMCP server tools
fullNoAll library feature groups; add serve/mcp separately for those CLI surfaces
Terminal window
# Default features
cargo install pmetal
# With specific features
cargo install pmetal --features "serve,mcp"
# All library feature groups
cargo install pmetal --features full
# Library feature groups plus optional CLI surfaces
cargo install pmetal --features "full,serve,mcp"
# Minimal CLI build
cargo build --release --no-default-features --features cli
# TUI without default trainer/ANE/distributed stack
cargo build --release --no-default-features --features dashboard
[dependencies]
pmetal = { version = "0.5", default-features = false, features = ["core", "models"] }
# Or specific crates
pmetal-models = "0.5"
pmetal-trainer = "0.5"
pmetal-lora = "0.5"