

The algorithm is an extension for stochastic machines of the k-tails method introduced in 1972 by Biermann and Feldman for non-stochastic machines. We describe a simple, fast and easy to implement recursive algorithm with four alternate intuitive heuristics for inferring Probabilistic Finite State Automata. We show through experiments that the quality of specification mining can be significantly improved using SMArTIC. Correspondingly, SMArTIC comprises four components: an erroneous-trace filtering block, a related-trace clustering block, a learner, and a merger. This architecture is constructed based on two hypotheses: (1) Erroneous traces should be pruned from the input traces to a miner, and (2) Clustering related traces will localize inaccuracies and reduce over-generalizationin learning. In this paper, we propose a novel API specification mining architecture called SMArTIC (Specification Mining Architecture with Trace fIltering and Clustering) to improve the accuracy, robustness and scalability of specification miners.
EXPRESSING QUERIES AS FINITE STATE AUTOMATA SOFTWARE
Software specification mining is a new technique to address this concern by inferring specifications automatically. This can result in software that is characterized by bugs, anomalies and even security threats. Use Myhill-Nerode theorem to show the following languages are not regular.Improper management of software evolution, compounded by imprecise, and changing requirements, along with the “short time to market ” requirement, commonly leads to a lack of up-to-date specifications. The output is 1 if the last three symbols read are in alphabetical order i.e., abc, bcd or cde. If they belong to different blocks, split this block into two or more blocks depending on the a-successors of the states.įor example, if a block has satisfying the following condition. Consider the a-successors of them for a ∊ Σ. Step 2. Consider the set of states in a block. (Any state in F is distinguishable from a state in K - F by ε.) Repeat the following step till no more split is possible. We get a partition of the set of states of K as follows: Then, xa and ya will belong to the same equivalence class of R L. Suppose x and y belong to the same equivalence class of R L. This definition is consistent as R L is right invariant. Let denote the equivalence class of R L to which x belongs.Ĭonstruct a DFSA M L = ( K′, Σ, δ′, q 0, F′) as follows: K′ contains one state corresponding to each equivalence class of R L. xR L y if ∀z in Σ*, xz is in L exactly when yz is in L or we can also write this in the following way: xR L y if for all w, z in Σ*, xwz is in L exactly when ywz is in L.

Therefore, E is a refinement of R L and so the index of R L is less than or equal to the index of E and hence finite.įirst, we show R L is right invariant. Hence, any equivalence class of E is completely contained in an equivalence class of R L. Hence, xz and yz are both in L or both not in L as L is the union of some of the equivalence classes of E. xz and yz are in the same equivalence class of E. Let R L be defined as in the statement of the theorem. L is the union of those equivalence classes of R M which correspond to final states of M.Īssume statement (2) of the theorem and let E be the equivalence relation considered. It can be easily seen that this equivalence relation R M is right invariant, i.e., if (If a state is not reachable from q 0, it can be removed without affecting the language accepted). The number of equivalence classes is therefore equivalent to the number of states of M, assuming every state is reachable from q 0. The set of strings which take the machine from q 0 to a particular state q i are in one equivalence class. So R M divides Σ* into equivalence classes. R M is an equivalence relation, as seen below. Define a relation R M on Σ* such that xR My if δ( q 0, x) = δ(q 0, y).

Let L be accepted by a FSA M = ( K, Σ, δ, q 0, F). Let equivalence relation R L be defined over Σ* as follows: xR L y if and only if, for all z ∊ Σ*, xz is in L exactly when yz is in L. L is the union of some of the equivalence classes of a right invariant equivalence relation of finite index on Σ*.
