code: public int getScore()
      {
          final String score0 = agiReply.getAttribute("score0");
          return score0 == null ? 0 : Integer.parseInt(score0);
      }
docs: Returns the confidence score for the first recognition result. This is an integer between 0 (lowest confidence)
  and 1000 (highest confidence).
  
  @return the confidence score for the first recognition result or 0 if no speech was recognized.