Fetching centroid of geometry objects

This was it! Thank you Zach!

I will note for posterity that while calling the aggregate the field needs to be passed into the custom module and the type needs to be declared as an option to Ash.aggregate. Like this:

Ash.aggregate(:centroid, :custom, 
  type: AshGeo.Geometry,
  implementation: {StCentroid, [field: :coordinates]}
)