Skip to content

Add experimental BF16 support for Metal#809

Draft
alvarobartt wants to merge 28 commits intomainfrom
add-bfloat16-support
Draft

Add experimental BF16 support for Metal#809
alvarobartt wants to merge 28 commits intomainfrom
add-bfloat16-support

Conversation

@alvarobartt
Copy link
Member

@alvarobartt alvarobartt commented Jan 31, 2026

What does this PR do?

This PR adds experimental support for BF16 as a supported dtype on Metal, when the features candle and metal are enabled. As candle natively supports BF16, and some recent models as https://huggingface.co/voyageai/voyage-4-nano (and all the other Voyage AI embedding models) default to BF16; support has been introduced to support such cases.

Warning

Support for BF16 is still experimental on Metal, whilst stable for Intel HPUs under the python feature, as it runs with a Python-based backend. And, work in progress for CUDA which requires bumping candle to latest and updating candle-extensions accordingly.

Additionally, this PR also updates the Rust version to 1.92.0 (latest stable) in rust-toolchain.toml, and removes half as unused.

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you read the contributor guideline?
  • Was this discussed/approved via a GitHub issue or the forum? Please add a link to it if that's the case.
  • Did you make sure to update the documentation with your changes? Here are the documentation guidelines.
  • Did you write any new necessary tests? If applicable, did you include or update the insta snapshots?

Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.

@alvarobartt alvarobartt changed the title Add experimental BF16 support for Metal and CUDA Add experimental BF16 support for Metal Feb 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant