returns false if the word has to be skipped
@param  {string}  word
@return {Boolean} false if skip; true if not
553283
function hasToSkipWord(word) {
            if(word.length < options.minLength) return false;
            if(lodash.find(options.skipWordIfMatch, function (aPattern) {
                return word.match(aPattern);
            })){
                return false;
            }
            return true;
        }
404317
def apply(self, word, ctx=None):
        
        return Sequential.in_sequence(word,AdjacentVowels.uyir_letters,AdjacentVowels.reason)
898942
public Prep findWord(String word) {
    
    if (prepsMap.containsKey("*")) {
      word = "*";
    }
    
    return prepsMap.get(word);
  }
529161
function(word, callback) {
		const deferred = Q.defer()

		this.raw((msg) => {
			parser.exactMatch(msg, word)
			.then((chatter) => {
				deferred.resolve(callback(null, chatter))
			}).catch((err) => {
				deferred.reject(callback(err))
			})
		}).catch((err) => {
			deferred.reject(callback(err))
		})
		return deferred.promise;
	}
828613
public static boolean isInSystemDic(String word) {
        Item item = DAT.getItem(word);
        return item != null && item.getStatus() > 1;
    }
193850
function constainRestrictedWords(text) {
	var i,
		restictedWords = ['today', 'tomorrow', 'yesterday', 'tonight'];

	text = text.toLowerCase();
	i = restictedWords.length;
	while (i--) {
		if (text.indexOf(restictedWords[i]) > -1) {
			return true;
		}
	}
	return false;
}
524672
public void skipGram(int i, List<VocabWord> sentence, int b, double alpha) {

        final VocabWord word = sentence.get(i);
        if (word != null && !sentence.isEmpty()) {
            int end = window * 2 + 1 - b;
            for (int a = b; a < end; a++) {
                if (a != window) {
                    int c = i - window + a;
                    if (c >= 0 && c < sentence.size()) {
                        VocabWord lastWord = sentence.get(c);
                        iterateSample(word, lastWord, alpha);
                    }
                }
            }
        }
    }
21865
function isValidReservedWordPosition(tk, iterable, words) {
	const last = iterable.behind(1) || {EMPTY: true, is: type => type === 'EMPTY'};
	const twoAgo = iterable.behind(2) || {EMPTY: true, is: type => type === 'EMPTY'};

	// evaluate based on last token
	const startOfCommand = (
		last.is('EMPTY') || last.is('SEPARATOR_OP') || last.is('OPEN_PAREN') ||
		last.is('CLOSE_PAREN') || last.is('NEWLINE') || last.is('NEWLINE_LIST') ||
		last.is('DSEMI') || last.value === ';' || last.is('PIPE') ||
		last.is('OR_IF') || last.is('PIPE') || last.is('AND_IF')
	);

	const lastIsReservedWord = (!last.value === 'for' && !last.value === 'in' && !last.value === 'case' && values(words).some(word => last.is(word)));

	const thirdInCase = twoAgo.value === 'case' && tk.is('TOKEN') && tk.value.toLowerCase() === 'in';
	const thirdInFor = twoAgo.value === 'for' && tk.is('TOKEN') &&
		(tk.value.toLowerCase() === 'in' || tk.value.toLowerCase() === 'do');

	// console.log({tk, startOfCommand, lastIsReservedWord, thirdInFor, thirdInCase, twoAgo})
	return tk.value === '}' || startOfCommand || lastIsReservedWord || thirdInFor || thirdInCase;
}
1217934
def correct_word(word_string):
    '''
    
    '''
    if word_string is None:
        return ""
    elif isinstance(word_string, str):
        return max(find_candidates(word_string), key=find_word_prob)
    else:
        raise InputError("string or none type variable not passed as argument to correct_word")
50925
public function is(string $word): bool
    {
        if ($word === '') {
            return false;
        }

        $tree = &$this->tree;
        if ($tree === []) {
            return false;
        }

        $array = $this->split($word);

        foreach ($array as $char) {
            if (!isset($tree[$char])) {
                return false;
            }

            $tree = &$tree[$char];
        }

        return $tree['end'];
    }
432342
public static boolean isUncountable(String word) {
        for (String w : UNCOUNTABLE) {
            if (w.equalsIgnoreCase(word)) {
                return true;
            }
        }
        return false;
    }
717056
function (e) {
            // see if we formed a valid word
            for (var i = 0, len = wordList.length; i < len; i++) {
                if (wordList[i] === curWord) {
                    var selected = $('.selected');
                    selected.addClass('found');
                    wordList.splice(i, 1);
                    var color = e.data.colorHash.hex(curWord);
                    $('.' + curWord).addClass('wordFound');
                    for (var selectedIndex = 0, selectedLength = selected.length; selectedIndex < selectedLength; selectedIndex++) {
                        var current = $(selected[selectedIndex]), style = current.attr("style"), hasBC = style != undefined && style.search("background-color") != -1;
                        if (hasBC) {
                            current.css("border", "4px solid " + color);
                        }
                        else {
                            current.css("background-color", color);
                        }
                    }
                    $(e.data.puzzleEl).trigger("found", curWord);
                    $(e.data.wordsEl).append("<li class=\"" + curWord + " wordFound\"><i style=\"background-color:" + color + ";\"></i>" + curWord + "</li>");
                }
                if (wordList.length === 0) {
                    $('.puzzleSquare').off(".spl").addClass('complete');
                    $(e.data.puzzleEl).trigger("end");
                }
            }
            // reset the turn
            $('.selected').removeClass('selected');
            startSquare = null;
            selectedSquares = [];
            curWord = '';
            curOrientation = null;
        }
1366226
private boolean skipBlankAndComma()
    {
        boolean commaFound = false;
        while (!isEOS())
        {
            int c = str.charAt(idx);
            if (c == ',')
            {
                if (commaFound)
                    return true;
                else
                    commaFound = true;
            }
            else if (!isBlank(c))
            {
                return true;
            }
            ++idx;
        }
        return false;
    }
366491
function isAcronym (word) {

  return word.length &&
    word.trim().length > 1 &&
    !(onlyNumbers.test(word.replace(/[\.,-\/#!–$%°\^&\*;?:+′|@\[\]{}=\-_`~()]/g,""))) &&
    word.replace(/[\.,-\/#!$%\^&\*;–?:+|@\[\]{}=\-_`~(′°)]/g,"") === word &&
    word.toUpperCase() === word;
}
854625
function isNameAbbreviation(wordCount, words) {
    if (words.length > 0) {
        if (wordCount < 5 && words[0].length < 6 && isCapitalized(words[0])) {
            return true;
        }

        var capitalized = words.filter(function(str) {
            return /[A-Z]/.test(str.charAt(0));
        });

        return capitalized.length >= 3;
    }

    return false;
}
1025975
protected boolean filter(IWord word)
    {
        /*
         * normally word with length less than 2 will
         * be something, well could be ignored 
        */
        if ( word.getValue().length() < 2 ) {
            return false;
        }
        
        //type check
        switch ( word.getType() ) {
            //case IWord.T_BASIC_LATIN:
            case IWord.T_LETTER_NUMBER:
            case IWord.T_OTHER_NUMBER:
            case IWord.T_CJK_PINYIN:
            case IWord.T_PUNCTUATION:
            case IWord.T_UNRECOGNIZE_WORD: {
                return false;
            }
        }
        
        //part of speech check
        String[] poss = word.getPartSpeech();
        if ( poss == null ) return true;
        
        char pos = poss[0].charAt(0);
        switch ( pos ) {
            case 'e': {
                if ( poss[0].equals("en") ) return true;
                return false;
            }
            case 'm': {
                if ( poss[0].equals("mix") ) return true;
                return false;
            }
            case 'q':
            case 'b':
            case 'r':
            case 'z':
            case 'p':
            case 'c':
            case 'u':
            case 'y':
            case 'd':    //@date 2015-11-23
            case 'o':
            case 'h':
            case 'k':
            case 'g':
            case 'x':
            case 'w': {
                return false;
            }
            
            /*case 'n':
            case 'v':
            case 'a':
            case 't':
            case 's':
            case 'f':
            {
                return true;
            }*/
        }
        
        return true;
    }
249936
function precedenceAdjustmentSpecification(word){
    var regex_rules = [
        /^be(.*)lah$/,
        /^be(.*)an$/,
        /^me(.*)i$/,
        /^di(.*)i$/,
        /^pe(.*)i$/,
        /^ter(.*)i$/,
    ];

    for(var i in regex_rules){
        if(word.match(regex_rules[i])){
            return true;
        }
    }
    return false;
}