How do I use Ash.Transform

There is some frustratingly out of date bits here: Ash.Resource.Preparation — ash v3.29.3

Ultimately a preparation can look one of two ways:

prepare fn query, context -> 
  ...
end
# or
prepare Module
prepare {Module, foo: :bar} # or with opts
defmodule Module do
  use Ash.Resource.Preparation

  def prepare(query, opts, context) do
    query
  end
end

The actions guide talks more about the lifefcycle of each action type. Actions — ash v3.29.3