bdb3bd5bd812fdc9860d876d48489c89675491aa,snips_nlu/nlu_engine/nlu_engine.py,SnipsNLUEngine,parse,#SnipsNLUEngine#Any#,29

Before Change


        self.fitted = False

    def parse(self, text):
        if self.custom_first:
            first_parsers = self.custom_parsers
            second_parsers = self.builtin_parsers
        else:
            first_parsers = self.builtin_parsers
            second_parsers = self.custom_parsers

        first_parse = self._parse(text, first_parsers)
        if first_parse.parsed_intent is not None:
            return first_parse
        else:

After Change


        custom_parse = _parse(text, self.custom_parsers, threshold=0.)
        if custom_parse.parsed_intent is not None:
            return custom_parse
        elif self.builtin_parser is not None:
            return self.builtin_parser.parse(text, threshold=0.)
        else:
            return Result(text=text, parsed_intent=None, parsed_entities=None)

    def fit(self, dataset):
        validate_dataset(dataset)
        updated_parsers = []
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: snipsco/snips-nlu
Commit Name: bdb3bd5bd812fdc9860d876d48489c89675491aa
Time: 2017-03-24
Author: adrien.ball@snips.net
File Name: snips_nlu/nlu_engine/nlu_engine.py
Class Name: SnipsNLUEngine
Method Name: parse


Project Name: snipsco/snips-nlu
Commit Name: bf6180403e4196cef6c7d418240d02e69a914461
Time: 2017-05-30
Author: clement.doumouro@snips.ai
File Name: snips_nlu/nlu_engine.py
Class Name:
Method Name: _parse


Project Name: coala/coala-bears
Commit Name: 834acd07601b6a53a59884f1fcf3ffcc802f9e18
Time: 2016-03-20
Author: jarifibrahim@gmail.com
File Name: bears/vcs/git/GitCommitBear.py
Class Name: GitCommitBear
Method Name: check_shortlog