updated scoring code in aws.rb