Package net.maswag.falcaun
Class AbstractAdaptiveSTLUpdater<I>
java.lang.Object
net.maswag.falcaun.AbstractAdaptiveSTLUpdater<I>
- Type Parameters:
I- Type of the input at each step
- All Implemented Interfaces:
de.learnlib.oracle.BlackBoxOracle<net.automatalib.automaton.transducer.MealyMachine<?,,String, ?, String>, String, net.automatalib.word.Word<String>> de.learnlib.oracle.BlackBoxOracle.MealyBlackBoxOracle<String,,String> de.learnlib.oracle.EquivalenceOracle<net.automatalib.automaton.transducer.MealyMachine<?,,String, ?, String>, String, net.automatalib.word.Word<String>> de.learnlib.oracle.EquivalenceOracle.MealyEquivalenceOracle<String,,String> de.learnlib.oracle.InclusionOracle<net.automatalib.automaton.transducer.MealyMachine<?,,String, ?, String>, String, net.automatalib.word.Word<String>> de.learnlib.oracle.InclusionOracle.MealyInclusionOracle<String,,String> AdaptiveSTLUpdater<I>
- Direct Known Subclasses:
AdaptiveSTLList,StaticSTLList,StopDisprovedEQOracle.StaticLTLList
Abstract class for potentially adaptive set of STL formulas
- Author:
- Masaki Waga
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface de.learnlib.oracle.BlackBoxOracle
de.learnlib.oracle.BlackBoxOracle.DFABlackBoxOracle<I>, de.learnlib.oracle.BlackBoxOracle.MealyBlackBoxOracle<I,O> Nested classes/interfaces inherited from interface de.learnlib.oracle.EquivalenceOracle
de.learnlib.oracle.EquivalenceOracle.DFAEquivalenceOracle<I>, de.learnlib.oracle.EquivalenceOracle.MealyEquivalenceOracle<I,O>, de.learnlib.oracle.EquivalenceOracle.MooreEquivalenceOracle<I, O> Nested classes/interfaces inherited from interface de.learnlib.oracle.InclusionOracle
de.learnlib.oracle.InclusionOracle.DFAInclusionOracle<I>, de.learnlib.oracle.InclusionOracle.MealyInclusionOracle<I,O> -
Field Summary
FieldsModifier and TypeFieldDescription(package private) booleanprotected net.automatalib.alphabet.Alphabet<String> protected net.automatalib.modelchecking.ModelChecker.MealyModelChecker<String, String, String, net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String>> private final List<TemporalLogic<I>> private final List<TemporalLogic<I>> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddSTLProperties(Collection<? extends TemporalLogic<I>> stlCollection) protected voidaddSTLProperty(TemporalLogic<I> stl) private voidInitialize property oracles if they are not initialized yet.findCounterExample(@NotNull net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String> hypothesis, @NotNull Collection<? extends String> inputs) Try to disprove the current list of STL formulas against the given Mealy machine.List<de.learnlib.oracle.PropertyOracle<String, ? super net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String>, ?, net.automatalib.word.Word<String>>> final booleannewlyFalsifiedFormula(TemporalLogic<I> stlFormula) Returns if the formula is not yet falsifiedprotected voidnotifyFalsifiedProperty(List<Integer> falsifiedIndices) Notify that this.getLTLProperties.get(i) is falsified by the currently learned model.protected voidremoveSTLProperties(Collection<Integer> indices) protected voidremoveSTLProperty(int index) voidsetMemOracle(de.learnlib.oracle.MembershipOracle.MealyMembershipOracle<String, String> memOracle) Set new membership oracle.stream()Returns the current list of LTL formulas in MealyPropertyOracle in streamtoString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface net.maswag.falcaun.AdaptiveSTLUpdater
allDisproved, getLTLProperties, getSTLProperties, list, reset, setInputAlphabet, sizeMethods inherited from interface de.learnlib.oracle.InclusionOracle
isCounterExample
-
Field Details
-
EDGE_PARSER
-
emptinessOracle
-
modelChecker
-
inclusionOracle
-
memOracle
-
inputAlphabet
-
STLProperties
-
propertyOracles
-
initialized
boolean initialized -
reportedFormulas
-
-
Constructor Details
-
AbstractAdaptiveSTLUpdater
public AbstractAdaptiveSTLUpdater()
-
-
Method Details
-
stream
Description copied from interface:AdaptiveSTLUpdaterReturns the current list of LTL formulas in MealyPropertyOracle in stream- Specified by:
streamin interfaceAdaptiveSTLUpdater<I>
-
getPropertyOracles
-
setMemOracle
public void setMemOracle(@NotNull de.learnlib.oracle.MembershipOracle.MealyMembershipOracle<String, String> memOracle) Description copied from interface:AdaptiveSTLUpdaterSet new membership oracle. This is necessary to call list() and stream()- Specified by:
setMemOraclein interfaceAdaptiveSTLUpdater<I>
-
addSTLProperty
-
addSTLProperties
-
removeSTLProperty
protected void removeSTLProperty(int index) -
removeSTLProperties
-
confirmInitialization
private void confirmInitialization()Initialize property oracles if they are not initialized yet.We do not initialize it in the constructor to delay the construction of the membership oracle.
-
newlyFalsifiedFormula
Description copied from interface:AdaptiveSTLUpdaterReturns if the formula is not yet falsified- Specified by:
newlyFalsifiedFormulain interfaceAdaptiveSTLUpdater<I>
-
findCounterExample
@Nullable public @Nullable de.learnlib.query.DefaultQuery<String,net.automatalib.word.Word<String>> findCounterExample(@NotNull @NotNull net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String> hypothesis, @NotNull @NotNull Collection<? extends String> inputs) Try to disprove the current list of STL formulas against the given Mealy machine.It returns
- a counterexample for the newly falsified STL formula, if exists
- a counterexample for the first falsified STL formula, if exists
- null, if no counterexample is found.
- Specified by:
findCounterExamplein interfacede.learnlib.oracle.EquivalenceOracle<net.automatalib.automaton.transducer.MealyMachine<?,String, ?, String>, String, net.automatalib.word.Word<String>> - Parameters:
hypothesis- The Mealy machine to be verified.inputs- The alphabet of the Mealy machine.- Returns:
- A query of counterexample if a counterexample is found. Otherwise, it returns null.
- See Also:
-
notifyFalsifiedProperty
Notify that this.getLTLProperties.get(i) is falsified by the currently learned model.Typically, we can generate a new adaptive formula. Note: we should not remove the original formula by this.
- Parameters:
falsifiedIndices- The set of indices of the falsified LTL formulas
-
toString
-