---
title: Componentwise Automata Learning
url: https://www.emergentmind.com/topics/componentwise-automata-learning
type: topic
---

# Componentwise Automata Learning

Searching arXiv for the cited work and closely related papers on componentwise/compositional automata learning.
Componentwise automata learning is a family of active automata learning techniques that exploits a target system’s compositional structure by learning smaller component models or projections and then reconstructing a global hypothesis. In the literature represented here, the approach appears in several technically distinct forms: componentwise learning of Moore machines with product-valued outputs, output-decomposed learning of Mealy machines, compositional learning of synchronizing parallel systems through automated alphabet refinement, and componentwise automata learning for system integration with direct component access [1705.02850] [2405.08647] [2504.16624] [2508.04458]. Across these variants, the shared objective is complexity reduction relative to monolithic learning, typically by replacing a single large inference problem with multiple smaller ones.

## 1. Conceptual scope and main variants

The core idea is to replace monolithic inference of a single automaton by inference of components that correspond either to output coordinates, observable projections, or local alphabets. In the Moore-machine setting, the output alphabet factors as a Cartesian product \(O = O_1 \times \dots \times O_k\), and each projection \(\pi_i\) yields a component machine \(M_i\) that can be learned separately [1705.02850]. In the Mealy-machine setting, the decomposition is dual in the sense that it projects onto individual outputs; if \(O=\{o_1,\dots,o_k\}\) is one-hot coded by \(k\) bits, then each projection \(\pi_j:O\to\{0,1\}\) yields a binary-output Mealy machine \(M_j\) [2405.08647].

A different line of work treats decomposition as a problem of recovering component alphabets for synchronizing systems. There, the target is an LTS over a global alphabet \(\Sigma\), and a distribution \(\mathcal D=\{\Sigma_1,\dots,\Sigma_n\}\) is refined during learning until it is consistent with global observations [2504.16624]. Another setting arises in system integration, where the learner has direct access not only to the whole system but also to black-box components. In that setting, the target is a Moore machine network, and the distinguishing issue is not merely decomposition but also avoidance of learning component parts that never contribute to system-level behavior [2508.04458].

| Work | Target formalism | Decomposition principle |
|---|---|---|
| "Learning Product Automata" [1705.02850] | Moore machines | Product-valued outputs |
| "Output-decomposed Learning of Mealy Machines" [2405.08647] | Mealy machines | Projections onto individual outputs |
| "Compositional Active Learning of Synchronizing Systems through Automated Alphabet Refinement" [2504.16624] | LTSs | Distributions of possibly overlapping component alphabets |
| "Componentwise Automata Learning for System Integration (Extended Version)" [2508.04458] | Moore machine networks | Direct component access with contextual redundancy removal |

This suggests that “componentwise automata learning” is not a single algorithm but a methodological umbrella spanning several decomposition axes: outputs, observables, alphabets, and explicit system components.

## 2. Formal models and decomposition mechanisms

For Moore machines, a machine is a 6-tuple
\[
M = (Q,\Sigma,O,\delta,\lambda,q_0)
\]
with behavior \([M]_q:\Sigma^*\to O\) defined by \([M]_q(w)=\lambda(\delta(q,w))\). When \(O = O_1 \times \dots \times O_k\), the projections \(\pi_i(o_1,\dots,o_k)=o_i\) define component machines
\[
M_i=(Q,\Sigma,O_i,\delta,\lambda_i,q_0), \quad \lambda_i(q)=\pi_i(\lambda(q)).
\]
The original machine is equivalent to the product machine \(M_1\times\dots\times M_k\), although \(Q\times\dots\times Q\) may contain unreachable states; in a minimal realization one has \(|M_i|\le |M|\) [1705.02850].

For Mealy machines, a deterministic machine is given as
\[
M=(I,O,Q,q_0,\delta,\lambda),
\]
with semantics \(\llbracket M\rrbracket:I^*\to O^*\). If \(O=\{o_1,\dots,o_k\}\) is one-hot coded by \(k\) bits, then for \(j=1\dots k\),
\[
\pi_j:O\to\{0,1\},\qquad \pi_j(o)=1 \text{ iff } o=o_j,
\]
and the \(j\)-th projected machine is
\[
M_j:=\pi_j(M)=(I,\{0,1\},Q,q_0,\delta,\pi_j\circ\lambda).
\]
The full system is reconstructed from learned projections by synchronous product and re-assembly of the unique original output, with joint injectivity of \(\{\pi_j\}\) guaranteeing well-definedness [2405.08647].

For synchronizing systems, the formalism is the labelled transition system
\[
T=(S,\Sigma,\rightarrow,s_0).
\]
Given local LTSs \(T_i=(S_i,\Sigma_i,\rightarrow_i,s_{0,i})\), synchronous parallel composition \(\bigparallel_{i=1}^n T_i\) uses the standard synchronous-on-shared, interleaving-on-local rule. A distribution of alphabets is a set of possibly overlapping subalphabets
\[
\mathcal D=\{\Sigma_1,\Sigma_2,\dots,\Sigma_n\}, \qquad \bigcup_i \Sigma_i=\Sigma.
\]
A language \(\mathcal L\subseteq \Sigma^*\) is a product language over \(\mathcal D\) if
\[
\mathcal L=\bigparallel_{i=1}^n (\mathcal L_i,\Sigma_i),
\]
and the Prod-of-projections lemma states that this holds iff
\[
\mathcal L=\bigparallel_{i=1}^n (\mathrm{proj}_{\Sigma_i}(\mathcal L),\Sigma_i).
\]
This establishes projection as the semantic basis of decomposition in the synchronous setting [2504.16624].

For system integration, each component is modeled as a deterministic Moore machine
\[
M=(Q,q_0,I,O,\delta,\lambda),
\]
with partial transition function \(\delta:Q\times I\rightharpoonup Q\). Components are glued by a directed graph \(G=(V,E)\), producing a Moore machine network \(\mathcal M\) whose global machine
\[
[\mathcal M]=\Bigl(\prod_{c\in c}Q_c,\mathbf q_0,in,out,\Delta,\Lambda\Bigr)
\]
updates synchronously via
\[
\Delta(\mathbf q,\mathbf i)
=\Bigl(\delta_c\bigl(q_c,(\mathbf i,\Lambda(\mathbf q))\!\!\mid_{\mathit{in}(c)}\bigr)\Bigr)_{c\in c}, \quad
\Lambda(\mathbf q)=\bigl(\lambda_c(q_c)\bigr)_{c\in c}.
\]
Here decomposition is explicit in the system architecture rather than inferred from outputs or alphabets [2508.04458].

## 3. Learning architectures and query models

The classical baseline is Angluin-style active learning in the minimally adequate teacher model, using membership queries and equivalence queries. In the Moore-machine product setting, MQ returns the full tuple in \(O_1\times\dots\times O_k\), and EQ tests equivalence of a hypothesis to the target. A single observation table \((S,E,T)\) is maintained, with
\[
T:(S\cup S\cdot\Sigma)\times E\to O,\qquad T(s,e)=M(se),
\]
and projections \(T_i(s,e)=\pi_i(T(s,e))\). The adapted criteria are product-closedness and product-consistency. If the table is product-closed and product-consistent, the usual quotient construction yields a candidate product machine whose \(i\)-th component is exactly the minimal Moore automaton consistent with \((S,E,T_i)\) [1705.02850].

That same work also gives a parallel reduction to \(k\) independent learners. Each learner receives projected answers to membership queries, and once all learners propose hypotheses \(H_i\), the master forms \(H=H_1\times\dots\times H_k\) and poses a global equivalence query. Any returned counterexample is a counterexample in at least one projection and is fed back to the corresponding learner [1705.02850].

The Mealy-machine variant, OL\(^*\), also maintains a single L\(^*\)-style table \((S,E,T)\), but \(T\) records full Mealy outputs and is projected to \(T_j\) for each output bit. The central defects are output-closure, output-consistency, and component-consistency. When a defect is found, the algorithm adds either a new prefix to \(S\) or a new suffix to \(E\), refills the table by MQs, and repeats. Its pseudocode initializes \(S\leftarrow\{\epsilon\}\), \(E\leftarrow I\), fills \(T\) by MQs, repairs projected defects, builds provisional hypotheses \(H_j\), checks “exactly-one-1,” composes \(H=\mathbin{\text{\Large$\times$}}_j(H_j,\pi_j)\), and asks \(\mathrm{EQ}(H)\). In practice, checks for different \(j\) are interleaved and table repairs are chosen greedily by a greedy hitting-set approximation [2405.08647].

CoalA interleaves two loops. In the local-learning loop, for each current subalphabet \(\Sigma_i\in\mathcal D\), a standard active learner runs on \(\Sigma_i\), translating local membership queries to global queries by uplift if possible. In the global-equivalence loop, the composite hypothesis
\[
H=H_1\parallel H_2\parallel\dots\parallel H_k
\]
is checked against the Teacher. If a counterexample arrives and \(\mathcal D\not\models \mathit{Obs}\), then the counterexample is or immediately yields a distribution-counterexample, from which one extracts minimal discrepancy sets \(\Delta\) and updates \(\mathcal D\gets\mathcal D\cup\{\Delta\}\), optionally canonizing and restarting local learners. Otherwise, the counterexample is local and its projections are forwarded to learners [2504.16624].

CCwL\(^*\) for system integration runs concurrent L\(^*\)-style learners—one per component—but uses only system-level EQ and combines this with context analysis. The learner has access to system-level oracles \(\mathsf{OQ}:in^*\to out^*\) and \(\mathsf{EQ}\), as well as component-level oracles \(\mathsf{OQ}_c:I_c^*\to O_c^*\) and \(\mathsf{EQ}_c\). The algorithm builds a hypothesis network from component tables, performs 1Ext completeness queries, and analyzes global counterexamples via contextual variants of 1Ext and AnalyzeCex\(^c\), parameterized by CA-parameters \((\mathcal E,\mathcal R)\) [2508.04458].

## 4. Reconstruction, correctness, and complexity

Reconstruction is explicit in both the Moore and Mealy projection settings. For Moore machines with product outputs, the global machine is equivalent to the product of the learned component machines, modulo unreachable states in the Cartesian product [1705.02850]. For Mealy machines, if each projected learner returns
\[
M_j=(I,\{0,1\},Q_j,q_{0,j},\delta_j,\lambda_j),
\]
then the reconstructed machine has state space
\[
Q' = Q_1\times Q_2\times\cdots\times Q_k,
\]
initial state \((q_{0,1},\dots,q_{0,k})\), synchronous transition function, and output assembled as the unique \(o\in O\) whose projections match the component outputs. One shows \(\llbracket M'\rrbracket=\llbracket M\rrbracket\), and in fact only the reachable part of the product is used [2405.08647].

The query-complexity rationale for componentwise learning is that smaller components can make \(\sum_i n_i^2\) much smaller than \(n^2\). For monolithic L\(^*\) on a Moore machine of size \(n\), standard bounds give \(O(|\Sigma|\cdot n^2)\) membership queries and \(O(n)\) equivalence queries. If each component \(M_i\) is learned separately, the total cost becomes
\[
\mathrm{MQ}_{\mathrm{total}}=\sum_{i=1}^k O(|\Sigma|\cdot n_i^2),\qquad
\mathrm{EQ}_{\mathrm{total}}=\sum_{i=1}^k O(n_i),
\]
and if the states factor as \(Q_1\times\dots\times Q_k\) with \(n=\prod_i n_i\), then \(\sum_i n_i^2\) is exponentially smaller than \(n^2\) once \(k>1\) [1705.02850].

For output-decomposed Mealy learning, standard L\(^*\) for \(M\) with \(|I|=m\) asks \(O(m\cdot n^2)\) membership queries and \(O(n)\) EQs. OL\(^*\) asks, in the worst case,
\[
O\Bigl(m\cdot\sum_{j=1}^k n_j^2\Bigr)\ \text{MQs plus}\ O\Bigl(\sum n_j\Bigr)\ \text{EQs},
\]
with the note that in practice only 1 EQ is used on the composed \(H\). The structural assumption is that a substantial gain arises when the original machine is “one-hot” in its outputs or more generally exhibits a product-like structure in \(O\), so that each \(\pi_j\) drastically reduces the number of distinguishable states. Conversely, if some projection still needs \(n_j\approx n\) states, no improvement is gained [2405.08647].

CoalA’s correctness argument has two parts: termination of local learners for any fixed distribution by standard active-learning convergence, and termination of distribution refinement because each update strictly increases a finite preorder on distributions. The algorithm therefore terminates and returns hypotheses whose synchronous composition is equivalent to the unknown SUL. Its complexity discussion is intentionally rough: in the worst case one may refine up to \(2^{|\Sigma|}\) subsets, but in practice far fewer, and the total number of membership queries is typically orders of magnitude smaller than monolithic learning over \(\Sigma\) [2504.16624].

CCwL\(^*\) states an explicit theorem for the sound case. If \(\mathcal R=\mathsf D_\infty\), \(\mathcal E\) is any component abstraction, the true network has in total \(n\) states summed over components, input alphabet size \(\ell\), and maximum counterexample length \(m\), then CCwL\(^*\) uses at most
\[
O\bigl(\ell n^2+n|c|\log m\bigr)
\]
component-level output queries and \(O(n)\) system-level equivalence queries. Unsound \(\mathcal R\) may add at most \(O(\ell n|c|)\) extra queries, but does not affect termination [2508.04458].

## 5. Empirical results and application domains

The empirical literature shows that the effectiveness of componentwise learning is strongly structure-dependent. In "Learning Product Automata," the motivating applications are software and protocol components exposing multiple observables such as “status” and “error-code,” or several output pins of a hardware port. The paper states that if these observables evolve largely independently, one can learn each projection with far fewer queries than the monolithic product. It also reports that empirical results on \(n\)-bit “register-machines” show a drop from \(O((2^n)^2)\) MQ to \(O(n\cdot 2^{2}n)\), described as “from exponential to polynomial in \(n\)” [1705.02850].

The Mealy-machine study reports preliminary experiments in LearnLib on two benchmark suites. For artificial random interleavings with dedicated outputs, machines were built by “activating” one of \(r\) small sub-machines on inputs \(L/R\), each sub-machine having its own disjoint output set; full machine size reached up to 10 000 states while projections summed to only \(\sim 100\) states, and OL\(^*\) reduced membership-query symbols by up to two orders of magnitude compared to standard L\(^*\). On the Labbaf et al. (2023) benchmark, the machines arise from parallel interleavings of components that share output symbols; because outputs are not one-hot, OL\(^*\) cannot decompose, and indeed it performs worse than L\(^*\) [2405.08647].

CoalA’s evaluation spans more than 630 subject systems. On 300 random LTSs with various concurrency patterns, CoalA used up to \(10^5\)–\(10^6\times\) fewer membership queries than monolithic L\(^*\) and roughly \(10\times\) fewer equivalence queries in highly concurrent cases. On two large industrial-style models, CloudOpsManagement and a producer/consumer net, the implementation scales to systems with thousands of states, with query complexity close to an idealized compositional baseline with known decomposition. On more sequential Petri-net-derived examples, it still learns correctly but the query savings are smaller, as expected when concurrency is limited [2504.16624].

The system-integration work compares MnL\(^*\), CwL\(^*\), and CCwL\(^*\) on random benchmarks, MQTT, and \(\mathtt{BinaryCounter}(k)\). The metrics are learned states and transitions, number of OQ resets and steps, EQ resets and steps, learner CPU time, and validation success/failure/timeouts. In all benchmarks, MnL\(^*\) quickly times out on larger networks; CwL\(^*\) learns all components fully, incurring large tables for redundant parts; and CCwL\(^*\) with \((\mathsf{Eq},\mathsf D_\infty)\) consistently yields the smallest models and fewest queries, at a moderate learner-side cost. On RichComp and MQTT, CCwL\(^*\) reduces component sizes by \(>90\%\), OQ queries by \(>80\%\), and EQs by \(>50\%\), compared to CwL\(^*\) [2508.04458].

These findings support a consistent interpretation: componentwise methods are most effective when the decomposition exposes smaller state spaces or excludes behavior that is irrelevant at the system level.

## 6. Limitations, misconceptions, and open directions

A persistent misconception is that decomposition automatically yields savings. The cited work repeatedly rejects that conclusion. In the output-decomposed Mealy setting, if outputs are shared by components, projections do not shrink the machine and OL\(^*\) can even incur extra cost because of extra consistency checks; the paper’s Labbaf-benchmark result is a direct example [2405.08647]. In the Moore-machine product setting, if outputs are strongly correlated, the individual learners may not save queries, and intermediate global hypotheses \(H_1\times\dots\times H_k\) can have many unreachable states, which some equivalence-oracles struggle with [1705.02850].

A second misconception is that the decomposition is always known a priori. The literature is divided on this point. Product-output and output-projection methods assume a meaningful projection structure from the start. CoalA explicitly addresses the case of unknown decomposition by starting from singleton alphabets and refining them through discrepancy sets derived from distribution-counterexamples. The paper also notes that greedy discrepancy selection may not always yield the smallest final distribution, and finding optimal refinements remains open [2504.16624]. In the Mealy setting, finding the “best” output decomposition beyond one-hot may be computationally hard [2405.08647].

A third issue concerns access assumptions. Earlier compositional work often assumes only global teacher access; the system-integration setting changes this by giving the learner direct access to black-box components through component-level output queries. That setting introduces “component redundancies,” meaning states or transitions that can never appear under any global execution. CCwL\(^*\) addresses this by over-approximating reachable global configurations of the current hypothesis through reachability analysis \(\mathcal R\) on the quotiented network \(\mathcal H/\mathcal E\). The abstraction choices include \(\mathsf{Eq}\), \(\mathsf{Eq}_k\), and \(\mathsf{Uni}\); the reachability bounds include \(\mathsf D_\infty\) and \(\mathsf D_d\). When \((\mathcal E,\mathcal R)\) is sound, no reachable input to any component is missed; unsound choices merely add extra refinements [2508.04458].

The open directions identified in the literature are technically aligned. The Mealy paper references using TTT instead of L\(^*\) for smaller tables, combining input- and output-decomposition for even larger gains, and allowing component-wise EQs in the teacher model [2405.08647]. The system-integration work points to large alphabet and symbolic methods, as well as application to real-world SI pipelines [2508.04458]. CoalA highlights extensions to richer models such as register automata and timed automata, and to other query frameworks such as apartness-based learning [2504.16624].

Taken together, these directions indicate that componentwise automata learning has evolved from fixed output-factorization in product automata to automated decomposition discovery and context-sensitive pruning, while retaining the central premise that scalability depends on exposing a decomposition that meaningfully reduces the effective hypothesis space.

Source: https://www.emergentmind.com/topics/componentwise-automata-learning