0e2a7f6d85a341959eba41d65019b2566084b406,inference.py,,inference_internal,#Any#,195

Before Change


// Internal inference function (for direct call)
def inference_internal(question):
    answers = inference_helper(tokenize(question))[0]
    answers = detokenize(answers)
    answers = replace_in_answers(answers, "answers")
    answers_score = score_answers(answers, "answers")
    return (answers, answers_score)

// Get index and score for best answer
def get_best_score(answers_score, include_blacklisted = True):

After Change


def inference_internal(questions):

    // Process questions and return
    return process_questions(questions)


// Get index and score for best answer
def get_best_score(answers_score, include_blacklisted = True):
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: daniel-kukiela/nmt-chatbot
Commit Name: 0e2a7f6d85a341959eba41d65019b2566084b406
Time: 2017-12-03
Author: daniel@kukiela.pl
File Name: inference.py
Class Name:
Method Name: inference_internal


Project Name: daniel-kukiela/nmt-chatbot
Commit Name: 0e2a7f6d85a341959eba41d65019b2566084b406
Time: 2017-12-03
Author: daniel@kukiela.pl
File Name: inference.py
Class Name:
Method Name:


Project Name: daniel-kukiela/nmt-chatbot
Commit Name: 0e2a7f6d85a341959eba41d65019b2566084b406
Time: 2017-12-03
Author: daniel@kukiela.pl
File Name: inference.py
Class Name:
Method Name: inference