Use a Typespec function type

Yes, you can reference remote types for any of the arguments or the return type, but you can’t do

@spec some_function :: some_generic_function_signature()

which is what the OP was asking.