Fix as_json in guest.rb and convert tabs to spaces