Guarded Kleene Algebra with Tests (GKAT) is the fragment of Kleene Algebra
with Tests (KAT) that arises by replacing the union and iteration operations of
KAT with predicate-guarded variants. GKAT is more efficiently decidable than
KAT and expressive enough to model simple imperative programs, making it
attractive for applications to e.g. network verification. In this paper, we
further explore GKAT's automata theory, and present GL*, an algorithm for
learning the GKAT automaton representation of a black-box, by observing its
behaviour. A complexity analysis shows that it is more efficient to learn a
representation of a GKAT program with GL* than with Angluin's existing L*
algorithm. We implement GL* and L* in OCaml and compare their performances on
example programs.