  A quantum finite-state automaton (QFA) is a theoretical model designed to
simulate the evolution of a quantum system with finite memory in response to
sequential input strings. We define the language of a QFA as the set of strings
that lead the QFA to an accepting state when processed from its initial state.
QFAs exemplify how quantum computing can achieve greater efficiency compared to
classical computing. While being one of the simplest quantum models, QFAs are
still notably challenging to construct from scratch due to the preliminary
knowledge of quantum mechanics required for superimposing unitary constraints
on the automata. Furthermore, even when QFAs are correctly assembled, the
limitations of a current quantum computer may cause fluctuations in the
simulation results depending on how an assembled QFA is translated into a
quantum circuit.
  We present a framework that provides a simple and intuitive way to build QFAs
and maximize the simulation accuracy. Our framework relies on two methods:
First, it offers a predefined construction for foundational types of QFAs that
recognize special languages MOD and EQU. They play a role of basic building
blocks for more complex QFAs. In other words, one can obtain more complex QFAs
from these foundational automata using standard language operations. Second, we
improve the simulation accuracy by converting these QFAs into quantum circuits
such that the resulting circuits perform well on noisy quantum computers.
  Our framework is available at https://github.com/sybaik1/qfa-toolkit.
