Not ootb.
You might be able create a basic (perl-)tpl that calls a Ruby-executable and redirect its output into your tpl-output. I'm not sure with the Rails-part though.