Releases: ml-explore/mlx-swift
0.29.1
Integrate mlx 0.29.1
NOTE
This change contains some breaking API changes in the area of quantization. Specifically:
- the
quantized/dequantizedmethods now take amodeparameter (not breaking) - the
biasesresult fromquantizedis now optional, e.g.(wq: MLXArray, scales: MLXArray, biases: MLXArray?)
We are keeping the same semver here to match with python mlx. Although the change is breaking, it will likely be limited to implementations of quantized layers, e.g. QuantizedLinear, or other code that uses quantization directly. mlx-swift-examples will have a synchronized release to reflect this change.
If you need to make a similar change, consider the changes from QuantizedLinear:
The properties changed from this:
public let scales: MLXArray
public let biases: MLXArrayto:
public let mode: QuantizationMode
public let scales: MLXArray
public let biases: MLXArray?A mode with parameter with a default value was added where needed: mode: QuantizationMode = .affine and the mode parameter was used in calls to the quantization APIs:
var x = quantizedMatmul(
x,
weight,
scales: scales,
biases: biases,
transpose: true,
groupSize: groupSize,
bits: bits,
mode: mode
)and the Quantizable protocol was updated to have a mode parameter (protocol methods can't have default values):
/// Return the module as a quantized representation
func toQuantized(groupSize: Int, bits: Int, mode: QuantizationMode) -> ModuleWhat's Changed
- Fix spelling mistakes in docs by @abeleinin in #257
- Add contiguous by @kemchenj in #260
- Minor fixes docs by @CharlieTLe in #261
- fix typo MXArray -> MLXArray by @davidkoski in #264
- fixing more typos in docs and comments by @davidkoski in #265
- Make
Module.update()throw instead of crash for incompatible parameters by @louen in #266 - Make
MLXErrorprovide a description by @louen in #268 - Update links to MLX packages in documentation by @mattt in #277
- swift-format 602 by @davidkoski in #278
- ensure that the ErrorHandler is installed by @davidkoski in #282
- document memory buffers by @davidkoski in #280
- adopt mlx 0.29.1 and related mlx-c by @davidkoski in #273
New Contributors
- @abeleinin made their first contribution in #257
- @CharlieTLe made their first contribution in #261
- @mattt made their first contribution in #277
Full Changelog: 0.25.6...0.29.1
0.25.6
What's Changed
- Add support for tvOS by @guitaripod in #254
- add path information for parameter update errors -- great help in debugging by @davidkoski in #252
New Contributors
- @guitaripod made their first contribution in #254
Full Changelog: 0.25.5...0.25.6
0.25.5
What's Changed
- Add Support for
vmapFunction Transformation by @tanmay-bakshi in #245 - Update README with correct .git package URL for Xcode by @wayne-xyz in #248
- Fix optional module updates by @petrukha-ivan in #249
- Add ReLUSquared Activation Function by @johnmai-dev in #250
New Contributors
- @tanmay-bakshi made their first contribution in #245
- @wayne-xyz made their first contribution in #248
- @petrukha-ivan made their first contribution in #249
- @johnmai-dev made their first contribution in #250
Full Changelog: 0.25.4...0.25.5
0.25.4
What's Changed
- add withWiredLimit by @davidkoski in #243
- partial fix for #237 -- switching Device exhausts many resources by @davidkoski in #242
Full Changelog: 0.25.3...0.25.4
0.25.3
What's Changed
- update README and examples by @davidkoski in #232
- manage object lifetime in the face of more aggressive inlining and optimizations by @davidkoski in #239
- if no error handler set produce a fatal error (like the default used to be) by @davidkoski in #238
Full Changelog: 0.25.2...0.25.3
0.25.2
What's Changed
- new tests for dtype and promotion by @davidkoski in #233
- Fix scaled dot product attention mask argument by @louen in #236
Full Changelog: 0.25.1...0.25.2
0.25.1
What's Changed
-
adopt mlx v0.25.1 and mlx-c v0.2.0
- https://github.com/ml-explore/mlx/releases/tag/v0.25.1
- https://github.com/ml-explore/mlx/releases/tag/v0.25.0
- https://github.com/ml-explore/mlx/releases/tag/v0.24.2
- https://github.com/ml-explore/mlx/releases/tag/v0.24.1
- https://github.com/ml-explore/mlx/releases/tag/v0.24.0
- https://github.com/ml-explore/mlx/releases/tag/v0.23.2
-
use an evalLock for eval, asyncEval and Stream creation (ml-explore/mlx#2133)
-
CompiledFunction is not thread safe by @davidkoski in #226
-
add saveToData and load from data (safetensors) -- fix #214
-
fixes #211 (moves metalKernel API back to what it was)
-
add
withErrorandwithErrorHandlererror handling -
add function import/export: https://ml-explore.github.io/mlx/build/html/usage/export.html
-
various Random improvements,
withRandomStateby @davidkoski in #219 -
Return correct value in memory limit getter functions by @louen in #223
-
consistent treatment of HasDType (Float.self) vs dtype (.float32) by @davidkoski in #222
-
rename update -> _updateInternal to discourage callers by @davidkoski in #230
-
Add quantize function that can return different parameters per layer by @davidkoski in #229
New Contributors
Full Changelog: 0.23.1...0.25.1
0.23.1
Significant Changes
-
mlx version updated to 0.23.1
-
some modules are deprecated and folded into MLX (main module)
- MLXFast, MLXFFT, MLXRandom and MLXLinalg
- previous imports work, previous names work -- backward compatible
- see #205
What's Changed
- Remove package.resolved by @louen in #194
- add missing at functions by @davidkoski in #193
- add missing roll function by @davidkoski in #192
- Fix ml-explore/mlx-swift-examples#218 by @davidkoski in #200
- address issues that prevent using composition for layers like LoRA by @davidkoski in #177
- Update mlx-c to 0.1.2 by @barronalex in #204
- Reorganize MLXFast, MLXFFT, MLXRandom and MLXLinalg by @barronalex in #205
New Contributors
- @barronalex made their first contribution in #204
Full Changelog: 0.21.3...0.23.1
0.21.3
What's Changed
- Update check all set by @LaurentMazare in #174
- remove gguf -- fix #111 by @davidkoski in #176
- Add setErrorHandler and fatalErrorHandler by @finnvoor in #179
- fix: Correct wrong defatul value on docs of
SinusoidalPositionalEncodingby @minghuaw in #182 - add dilation parameter to convolution layers (match mlx.nn) by @davidkoski in #183
- remove symlinks by @davidkoski in #191
New Contributors
- @LaurentMazare made their first contribution in #174
- @finnvoor made their first contribution in #179
Full Changelog: 0.21.2...0.21.3
0.21.2
What's Changed
- fix #172 -- missing steel_attenion.metal by @davidkoski in #173
Full Changelog: 0.21.1...0.21.2