Class AbstractAdaptiveSTLUpdater<I>
- Type Parameters:
I- Type of the input at each step
- All Implemented Interfaces:
BlackBoxOracle<net.automatalib.automaton.transducer.MealyMachine<?,,String, ?, String>, String, net.automatalib.word.Word<String>> BlackBoxOracle.MealyBlackBoxOracle<String,,String> EquivalenceOracle<net.automatalib.automaton.transducer.MealyMachine<?,,String, ?, String>, String, net.automatalib.word.Word<String>> EquivalenceOracle.MealyEquivalenceOracle<String,,String> InclusionOracle<net.automatalib.automaton.transducer.MealyMachine<?,,String, ?, String>, String, net.automatalib.word.Word<String>> InclusionOracle.MealyInclusionOracle<String,,String> AdaptiveSTLUpdater<I>
- Direct Known Subclasses:
AdaptiveSTLList,StaticSTLList,StopDisprovedEQOracle.StaticLTLList
- Author:
- Masaki Waga
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface de.learnlib.oracle.BlackBoxOracle
BlackBoxOracle.DFABlackBoxOracle<I extends Object>, BlackBoxOracle.MealyBlackBoxOracle<I extends Object,O extends Object> Nested classes/interfaces inherited from interface de.learnlib.oracle.EquivalenceOracle
EquivalenceOracle.DFAEquivalenceOracle<I extends Object>, EquivalenceOracle.MealyEquivalenceOracle<I extends Object,O extends Object>, EquivalenceOracle.MooreEquivalenceOracle<I extends Object, O extends Object> Nested classes/interfaces inherited from interface de.learnlib.oracle.InclusionOracle
InclusionOracle.DFAInclusionOracle<I extends Object>, InclusionOracle.MealyInclusionOracle<I extends Object,O extends Object> -
Field Summary
FieldsModifier and TypeFieldDescriptionA function that parses edge labels in the model checker.protected EmptinessOracle.MealyEmptinessOracle<String,String> The oracle used to check for the emptiness of a language, which is essential for disproving properties.protected InclusionOracle.MealyInclusionOracle<String,String> The oracle used to check for the inclusion of one language in another, which is essential for finding counterexamples to hypotheses.(package private) booleanFlag indicating whether the property oracles have been initialized and are ready for use.protected net.automatalib.alphabet.Alphabet<String>The alphabet of input symbols used by the Mealy machine, defining the set of valid inputs for the system.protected MembershipOracle.MealyMembershipOracle<String,String> The oracle used to query membership in the language recognized by a Mealy machine, determining whether specific input sequences produce expected outputs.protected net.automatalib.modelchecking.ModelChecker.MealyModelChecker<String,String, String, net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String>> The model checker used to verify properties against a Mealy machine, ensuring that the system meets specified Signal Temporal Logic (STL) requirements.private final List<PropertyOracle.MealyPropertyOracle<String,String, String>> A list of property oracles used to verify the Signal Temporal Logic (STL) properties against the system.private final List<TemporalLogic<I>>A list of Signal Temporal Logic (STL) formulas that have been disproved by the verification process.private final List<TemporalLogic<I>>A list of Signal Temporal Logic (STL) properties that need to be verified against the system. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddSTLProperties(Collection<? extends TemporalLogic<I>> stlCollection) Adds a collection of Signal Temporal Logic (STL) properties to the list of properties to be verified.protected voidaddSTLProperty(TemporalLogic<I> stl) Adds a Signal Temporal Logic (STL) property to the list of properties to be verified.private voidInitializes the property oracles if they have not been initialized yet.@Nullable DefaultQuery<String,net.automatalib.word.Word<String>> findCounterExample(@NotNull net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String> hypothesis, @NotNull Collection<? extends String> inputs) Attempts to disprove the current list of STL formulas against the given Mealy machine.List<PropertyOracle<String,? super net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String>, ?, net.automatalib.word.Word<String>>> Returns a list of property oracles used to verify the Signal Temporal Logic (STL) properties.final booleannewlyFalsifiedFormula(TemporalLogic<I> stlFormula) Checks if a given Signal Temporal Logic (STL) formula has been newly falsified.protected voidnotifyFalsifiedProperty(List<Integer> falsifiedIndices) Notifies that the STL properties at the specified indices are falsified by the currently learned model.protected voidremoveSTLProperties(Collection<Integer> indices) Removes multiple Signal Temporal Logic (STL) properties from the list of properties to be verified.protected voidremoveSTLProperty(int index) Removes a Signal Temporal Logic (STL) property from the list of properties to be verified.voidvoidSets the membership oracle and initializes the emptiness and inclusion oracles.stream()Returns a stream of property oracles used to verify the Signal Temporal Logic (STL) properties.toLTLString(TemporalLogic<I> prop) Converts the given Temporal Logic property to its Linear Temporal Logic (LTL) string representation.toString()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
A function that parses edge labels in the model checker. This identity function is used to convert string representations to and from the model checker's internal format. -
emptinessOracle
The oracle used to check for the emptiness of a language, which is essential for disproving properties. -
modelChecker
@NotNull protected net.automatalib.modelchecking.ModelChecker.MealyModelChecker<String,String, modelCheckerString, net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String>> The model checker used to verify properties against a Mealy machine, ensuring that the system meets specified Signal Temporal Logic (STL) requirements. -
inclusionOracle
The oracle used to check for the inclusion of one language in another, which is essential for finding counterexamples to hypotheses. -
memOracle
The oracle used to query membership in the language recognized by a Mealy machine, determining whether specific input sequences produce expected outputs. -
inputAlphabet
The alphabet of input symbols used by the Mealy machine, defining the set of valid inputs for the system. -
STLProperties
A list of Signal Temporal Logic (STL) properties that need to be verified against the system. -
propertyOracles
A list of property oracles used to verify the Signal Temporal Logic (STL) properties against the system. -
initialized
boolean initializedFlag indicating whether the property oracles have been initialized and are ready for use. -
reportedFormulas
A list of Signal Temporal Logic (STL) formulas that have been disproved by the verification process. -
mapper
-
-
Constructor Details
-
AbstractAdaptiveSTLUpdater
public AbstractAdaptiveSTLUpdater()Constructs an instance ofAbstractAdaptiveSTLUpdater.Initializes the model checker used to verify properties against a Mealy machine.
-
-
Method Details
-
stream
Returns a stream of property oracles used to verify the Signal Temporal Logic (STL) properties.- Specified by:
streamin interfaceAdaptiveSTLUpdater<I>- Returns:
- A stream of
PropertyOracle.MealyPropertyOracleinstances.
-
getPropertyOracles
public List<PropertyOracle<String,? super net.automatalib.automaton.transducer.MealyMachine<?, getPropertyOracles()String, ?, String>, ?, net.automatalib.word.Word<String>>> Returns a list of property oracles used to verify the Signal Temporal Logic (STL) properties.- Specified by:
getPropertyOraclesin interfaceBlackBoxOracle<net.automatalib.automaton.transducer.MealyMachine<?,String, ?, String>, String, net.automatalib.word.Word<String>> - Returns:
- A list of
PropertyOracle.MealyPropertyOracleinstances.
-
setMemOracle
Sets the membership oracle and initializes the emptiness and inclusion oracles.- Specified by:
setMemOraclein interfaceAdaptiveSTLUpdater<I>- Parameters:
memOracle- The membership oracle to set.
-
addSTLProperty
Adds a Signal Temporal Logic (STL) property to the list of properties to be verified.- Parameters:
stl- The STL property to add.
-
addSTLProperties
Adds a collection of Signal Temporal Logic (STL) properties to the list of properties to be verified.- Parameters:
stlCollection- The collection of STL properties to add.
-
removeSTLProperty
protected void removeSTLProperty(int index) Removes a Signal Temporal Logic (STL) property from the list of properties to be verified.- Parameters:
index- The index of the STL property to remove.
-
removeSTLProperties
Removes multiple Signal Temporal Logic (STL) properties from the list of properties to be verified.- Parameters:
indices- The collection of indices corresponding to the STL properties to remove.
-
confirmInitialization
private void confirmInitialization()Initializes the property oracles if they have not been initialized yet.This method is called to set up the inclusion and emptiness oracles, which are necessary for verifying properties. The initialization is delayed until after the membership oracle has been set to ensure proper configuration.
-
newlyFalsifiedFormula
Checks if a given Signal Temporal Logic (STL) formula has been newly falsified.- Specified by:
newlyFalsifiedFormulain interfaceAdaptiveSTLUpdater<I>- Parameters:
stlFormula- The STL formula to check.- Returns:
- true if the formula has not been previously reported as falsified; otherwise, false.
-
findCounterExample
@Nullable public @Nullable DefaultQuery<String,net.automatalib.word.Word<String>> findCounterExample(@NotNull @NotNull net.automatalib.automaton.transducer.MealyMachine<?, String, ?, String> hypothesis, @NotNull @NotNull Collection<? extends String> inputs) Attempts to disprove the current list of STL formulas against the given Mealy machine.This method checks each STL formula in the list and tries to find a counterexample that disproves it. It returns:
- A counterexample for the first newly falsified STL formula, if one exists.
- A counterexample for the first falsified STL formula, if no new falsifications are found.
- null, if no counterexamples are found.
notifyFalsifiedProperty(List)with their indices.- Specified by:
findCounterExamplein interfaceEquivalenceOracle<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's input symbols.- Returns:
- A query representing a counterexample if one is found; otherwise, null.
- See Also:
-
notifyFalsifiedProperty
Notifies that the STL properties at the specified indices are falsified by the currently learned model.This method is called when one or more STL properties have been disproved. It allows for generating new adaptive formulas based on these falsifications. Note: The original formulas should not be removed; instead, they can be adapted or extended.
- Parameters:
falsifiedIndices- A list of indices corresponding to the falsified STL properties.
-
toString
-
toLTLString
Converts the given Temporal Logic property to its Linear Temporal Logic (LTL) string representation.Overrides the default implementation to utilize an optional mapping for abstracting the LTL string.
- Specified by:
toLTLStringin interfaceAdaptiveSTLUpdater<I>
-
setMapper
-