Package net.openai.util.fsm

Examples of net.openai.util.fsm.Condition


    State negPartState = new NamedState("NEG_PART");
    State negVerbState = new NamedState("NEG_VERB");
    State negCollocState = new NamedState("NEG_COLLOC");
    State negColPartState = new NamedState("NEG_COLPART");

    Condition regModalC = new TextSetCondition(iv_modalVerbsSet, false);
    Condition negPartC = new TextSetCondition(iv_negParticlesSet, false);
    Condition regVerbC = new TextSetCondition(iv_regVerbsSet, false);
    Condition negVerbC = new TextSetCondition(iv_negVerbsSet, false);
    Condition negDetC = new TextSetCondition(iv_negDeterminersSet, false);
    Condition negCollocC = new TextSetCondition(iv_negCollocSet, false);
    Condition negColPartC = new TextSetCondition(iv_negColPartSet, false);

    Condition notCollocC = new NegateCondition(negCollocC);

    startState.addTransition(negVerbC, negVerbState);
    startState.addTransition(negCollocC, negCollocState); // rule

    startState.addTransition(new DisjoinCondition(regModalC, regVerbC),
View Full Code Here


    Machine m = new Machine(startState);
    State negPrepState = new NamedState("NEG_PREP");
    State negDetState = new NamedState("NEG_DET");
    State regNounState = new NamedState("REG_NOUN");

    Condition negPrepC = new TextSetCondition(iv_negPrepositionsSet, false);
    Condition negDetC = new TextSetCondition(iv_negDeterminersSet, false);
    Condition regNounC = new TextSetCondition(iv_regNounsSet, false);

    startState.addTransition(negDetC, negDetState); // start with a modal
    startState.addTransition(negPrepC, negPrepState);
    startState.addTransition(new AnyCondition(), startState);
View Full Code Here

    Machine m = new Machine(startState);
    State regPrepState = new NamedState("REG_PREP");
    State negAdjState = new NamedState("NEG_ADJ");

    Condition regPrepC = new TextSetCondition(iv_regPrepositionsSet, false);
    Condition negAdjC = new TextSetCondition(iv_negAdjectivesSet, false);

    startState.addTransition(negAdjC, negAdjState); // start with a modal
    startState.addTransition(new AnyCondition(), startState);

    negAdjState.addTransition(regPrepC, regPrepState);
View Full Code Here

    endState.setEndStateFlag(true);

    Machine m = new Machine(startState);
    State titleNameState = new NamedState("TITLENAME");

    Condition titleNameCondition = new WordSetCondition(iv_fullTextSet,
        false);
    Condition periodCondition = new PunctuationValueCondition('.');

    startState.addTransition(titleNameCondition, titleNameState);
    startState.addTransition(new AnyCondition(), startState);

    titleNameState.addTransition(periodCondition, endState);
View Full Code Here

        endState.setEndStateFlag(true);

        Machine m = new Machine(startState);

        Condition probableC = new TextSetCondition(iv_probableSet, false);

        startState.addTransition(probableC, endState);
        startState.addTransition(new AnyCondition(), startState);

        endState.addTransition(new AnyCondition(), startState);
View Full Code Here

        endState.setEndStateFlag(true);

        Machine m = new Machine(startState);

        Condition historyC = new TextSetCondition(iv_historySet, false);

        startState.addTransition(historyC, endState);
        startState
                .addTransition(new TextValueCondition("h", false), hAbbrState);
        startState.addTransition(new AnyCondition(), startState);
View Full Code Here

        endState.setEndStateFlag(true);

        Machine m = new Machine(startState);

        Condition familyHistoryC = new TextSetCondition(
                iv_familyHistorySet,
                false);

        startState.addTransition(familyHistoryC, endState);
        startState.addTransition(
View Full Code Here

    State hourNumState = new NamedState("HOUR_NUM");
    State hourMinTextState = new NamedState("HOUR_MIN_TEXT");
    State ampmTextWithPeriodState = new NamedState("AM_PM_PERIOD_TEXT");

    Condition hourNumCondition = new IntegerRangeCondition(MIN_HOUR,
        MAX_HOUR);
    Condition hourMinCondition = new HourMinuteCondition(MIN_HOUR,
        MAX_HOUR, MIN_MINUTE, MAX_MINUTE);
    Condition dayNightCondition = new WordSetCondition(iv_dayNightSet,
        false);
    Condition dayNightWithPeriodCondition = new DayNightWordCondition();
    Condition closingPeriodCondition = new PunctuationValueCondition('.');

    startState.addTransition(hourNumCondition, hourNumState);
    startState.addTransition(hourMinCondition, hourMinTextState);
    startState.addTransition(new AnyCondition(), startState);
View Full Code Here

    State middleATextState = new NamedState("MID_TEXT");
    State firstDashState = new NamedState("FIRSTDASH");
    State secondDashState = new NamedState("SECONDDASH");
 

    Condition firstDashCondition = new PunctuationValueCondition('-');
    Condition secondDashCondition = new PunctuationValueCondition('-');
    Condition rangeCombineCondition = new DisjoinCondition(
    new RangeCondition(),
    new RangeStrengthCondition()
    );
 
 
    Condition initialMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition firstMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition secondMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition thirdMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition fourthMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
   
 
    Condition specificWordCondition = new WordSetCondition(
        iv_specifiedPatchesWordSet, false);
   
 
    startState.addTransition(new TextValueCondition("a", true),
        leftAbbreviateState);
View Full Code Here

    State middleATextState = new NamedState("MID_TEXT");
    State firstDashState = new NamedState("FIRSTDASH");
    State secondDashState = new NamedState("SECONDDASH");
 
 
    Condition firstDashCondition = new PunctuationValueCondition('-');
    Condition secondDashCondition = new PunctuationValueCondition('-');
    Condition rangeCombineCondition = new DisjoinCondition(
    new RangeCondition(),
    new RangeStrengthCondition()
    );
 
 
    Condition initialMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition firstMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition secondMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition thirdMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
    Condition fourthMiddleTextCondition = new WordSetCondition(
        iv_middleTermSet, true);
   
 
    Condition specificWordCondition = new WordSetCondition(
        iv_specifiedGastricWordSet, false);
   
 
    startState.addTransition(new TextValueCondition("a", true),
        leftAbbreviateState);
View Full Code Here

TOP

Related Classes of net.openai.util.fsm.Condition

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.