Some of the work has already been done in #242.
However, the main caveat is that Rails generators still depend on ActiveRecord, see #242 (comment).
@palkan's preferred options are to use Thor or Bytes, see #242 (comment).
In addition, we need to create a separate demo Rails application using Sequel to ensure that nothing is broken without ActiveRecord. There was an experiment in c5739a8.