Closed
Description
With v0.6, DI supports any number of context arguments (constants or caches), but only a single active argument x
(which comes first).
The last step to full generality is support for any number of active arguments. This would improve performance e.g. with Enzyme, and also (apparently) avoid some differentiation errors.
The issue is that for multiple active arguments, every operator output must become a tuple instead of a single object. In addition to being another breaking change, that might slow down backends which do not support multiple arguments.
My workaround idea for now is:
- force the first argument to always be active
- if there are no other active arguments (easy to check by constraining the
Vararg
), return single objects - otherwise, return tuples
Related past discussions: