Professional Documents
Culture Documents
this technology
not really the best way to gauge a person’s
story.
How it works and Then the officer will uses the transcript of the said
interview and put it into the machine.
//check for unique words ● Each element of the array will be will be
int uniqueWords = compared to the one in front of it.
splittedTranscript .length;
● If they are the same, the number of unique
words (which is equal to the length of the array)
for (int i = 0; i<
will be decremented.
splittedTranscript .length; i++) {
for (int j = i+1; j<
splittedTranscript .length; j++){
if(splittedTranscript [i].equals(
splittedTranscript [j])){
uniqueWords --;
Calculating sentence length and average length of a
sentence in the transcript.
How it works and why (steps)
● Replacing every punctuation with #
//sentence length
● Store the transcript in an Array, splitting it by #
double transcriptLength =
splittedTranscript.length; ● Call the function .length to get the number of
int totalLength = 0; sentence in the transcript.
String sentence =
● Calculate average length by dividing the
transcript.replaceAll("\\.",
"#/").replaceAll("\\?",
transcript length with number of sentences.
"#/").replaceAll("\\!", "#/");
String[] numSentence =
sentence.split("#/");
double transcriptLength =
splittedTranscript.length;
double averageLength =
(double)transcriptLength/numSentence.len
gth;
The score is divided into categories and each category
has a maximum score of 100.
How it works and why (steps)
For example, total words score. If the number of
//score calculation words is more than 125, the score will be 100 in this
double totalWordsScore; category.
if (transcriptLength >=125){
totalWordsScore = 100; Other categories:
} else {
● sentence score (at least 12 words per sentence
totalWordsScore = (transcriptLength/125)
for full score)
*100;}
double rating; ● unique words score (60% of the words has to
if (engFirst == true) { be unique for full score.)
rating = (uniqueScore*0.45)+(sentence
Score*0.35)+(totalWordsScore*0.2); The score of each categories has different weight
} else { which also change depending on the suspect’s native
rating = (uniqueScore*0.15)+(sentence language.
Score*0.15) + (totalWordsScore*0.6);
}
The reasons for parameters of 1)response length
2)sentence length and 3)unique words because of
Sources https://www.smithsonianmag.com/innovation/why-l
ie-detector-tests-cant-be-trusted-180972724/.