# What changed in onnxscript

> 74 changes in onnxscript 0.7 from its official release notes, upgrade guides and advisories: 4 breaking, 21 new APIs and options. Each one cited. Sources checked 2026-10-23. HTML: https://unstale.sh/pypi/onnxscript/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## onnxscript 0.7

### Breaking changes

- Rewrite rules must now specify inputs and attributes as args and kwargs instead of a list and a dictionary. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- The optimizer no longer constant-folds DynamicQuantizeLinear. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Arguments after graph are now keyword-only, affecting how the constructor can be called. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- The version converter raises an error when a function attribute is RefAttr. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)

### New APIs and options

- Adds an ONNX lowering for aten::bincount. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Adds a converter for aten::_grouped_mm.default. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Adds torchlib support for prims::remainder. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Accepts a memory_format keyword argument on rand, randn, and randint _like ops. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Exposes build_function in the public API. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Exposes build_graph in the public API. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Implements per-channel dequantization. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Implements per-channel quantization. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Adds support for torchvision.ops.deform_conv2d. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Adds the missing dtype parameter. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Introduces a graph construction utility, extended with support for script functions, schema-based input and attribute partitioning, None inputs, and initializers. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds a method for declaring graph outputs. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds a method for declaring graph inputs. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds subgraph construction and support for control-flow operations. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds a callable ModuleList that chains forward calls and accepts modules as PyTorch-style varargs. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds a neural-network module with Module and Parameter classes. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds tracing support for a single op.SplitToSequence. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Exposes OpBuilder through the onnxscript package. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Script functions can reference values from an outer scope. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds conversion to IR for use with control-flow operations. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Adds a converter for torch aten::histc. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)

### Performance

- Reimplements as_strided without an ONNX loop. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Folds Gemm beta into the fused BatchNorm bias. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Skips key/value repetition when query and key head counts are equal. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Adds a fusion rule that removes Expand before broadcast-capable binary operators. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)

### Behavior and default changes

- Exports aten::relu6 as a single Clip op. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- The rewriter supports an extended list of commutative operations. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- BatchNorm fusion now supports ConvTranspose with group values other than 1. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)

### Tooling

- Generates new opsets up to 27. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)

### Fixes and other changes

- Fixes arange and logit behavior. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Improves integer export by dropping Sign ops. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes bool-mask handling. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Corrects handling of infinities and equal_nan. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes rank mismatch for 1D weights by adding the missing squeeze. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Honors the dtype argument when exporting without dim. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes type promotion when the exponent is not floating point. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Corrects rank handling in ONNX export. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes handling of negative dims and shifts past the dimension length. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Avoids invalid ONNX graphs when start or end is None. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Emits scalar Range bounds. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Uses the query dtype's lowest finite value for the causal attention mask. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Preserves subgraph initializers when inlining If branches during constant folding. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Sets the kernel_shape attribute on Conv and ConvTranspose in torchlib. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Materializes the DFT axis default when converting opset 19 to 20. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes rounding for float16 truncating division. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes Dynamo export when memory_format is passed. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes protobuf serialization failure for large models. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Improves folding for Reshape and Slice operations. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Prevents initializer name collisions when resolving shared -1 shapes. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Preserves dft_length to fix FFT export truncation. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes Dynamo export for scalar multiplication on converted real tensors. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes scalar uneven splits producing incorrect equal-split output. (0.7.2) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.2)
- Fixes the incorrect float output dtype when using the default step. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Fixes an incorrect default dtype that caused ONNX shape-inference errors. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Sets linear_before_reset=1 to match PyTorch GRU semantics. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Fixes behavior for broadcasting masks. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Fixes violations of the ONNX specification. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Prevents incorrect fusion when Pad contains negative values. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Fixes fusion when the max value is None. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Invokes NameFixPass after graph-modifying operations in the rewriter, version-converter, and optimizer. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Fixes incorrect channel ordering by replacing SpaceToDepth with Reshape→Transpose→Reshape. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Antialiased upsampling now sets exclude_outside=1 on Resize. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Fixes half pixel mode when the output size is one. (0.7.1) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.1)
- Fusion no longer produces invalid ONNX when Conv nodes share weight initializers. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Uses cubic_coeff_a=-0.5 instead of -0.75 for bicubic antialias export. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Normalizes dtype in cache keys to prevent initializer name collisions. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Converter input-constraint failures now raise TranslationError instead of relying on asserts. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- Rewriter behavior is deterministic when matching multi-output patterns. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- The lowering now accepts the 7-argument schema. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
- The version converter now includes an inliner and removes unused functions before conversion. (0.7.0) — [release notes](https://github.com/microsoft/onnxscript/releases/tag/v0.7.0)
