We propose a new General Game Playing (GGP) system called Regular Games (RG). The main goal of RG is to be both computationally efficient and convenient for game design. The system consists of several languages. The core component is a low-level language that defines the rules by a finite automaton. It is minimal with only a few mechanisms, which makes it easy for automatic processing (by agents, analysis, optimization, etc.). The language is universal for the class of all finite turn-based games with imperfect information. Higher-level languages are introduced for game design (by humans or Procedural Content Generation), which are eventually translated to a low-level language. RG generates faster forward models than the current state of the art, beating other GGP systems (Regular Boardgames, Ludii) in terms of efficiency. Additionally, RG's ecosystem includes an editor with LSP, automaton visualization, benchmarking tools, and a debugger of game description transformations.
We survey selected open problems in the theory of synchronizing automata, centered around the famous Černý conjecture. A deterministic finite automaton is called synchronizing if it admits a reset word whose action maps all states to a single state. The Černý conjecture states that every synchronizing automaton with n states possesses a reset word of length at most (n-1)^2. We discuss avoiding words, compressing a state with another, synchronization of a (given or any) subset, complexity of deciding the synchronizability, average reset threshold, and linear-algebraic methods. Some new auxiliary results are also presented.
We study synchronizing partial DFAs, which extend the classical concept of synchronizing complete DFAs and are a special case of synchronizing unambiguous NFAs. A partial DFA is called synchronizing if it has a word (called a reset word) whose action brings a non-empty subset of states to a unique state and is undefined for all other states. The class of strongly connected partial DFAs is precisely the class of DFAs recognizing the Kleene star of prefix codes. While in the general case the problem of checking whether a partial DFA is synchronizing is PSPACE-complete, we show that in the strongly connected case, this problem can be efficiently reduced to the same problem for a complete DFA. Using combinatorial, algebraic, and formal languages methods, we develop techniques that relate main synchronization problems for strongly connected partial DFAs to the same problems for complete DFAs. In particular, this includes the Cerny and the rank conjectures, the problem of finding a reset word, and upper bounds on the length of the shortest reset words of literal automata of finite prefix codes. We conclude that solving fundamental synchronization problems is equally hard in both models, as an essential improvement of the results for one model implies an improvement for the other.
A complete deterministic finite (semi)automaton (DFA) with a set of states Q is completely reachable if every nonempty subset of Q is the image of the action of some word applied to Q. The concept of completely reachable automata appeared, in particular, in connection with synchronizing automata; the class contains the Cerny automata and covers several distinguished subclasses. The notion was introduced by Bondar and Volkov (2016), who also raised the question about the complexity of deciding whether an automaton is completely reachable. We develop an algorithm solving this problem, which works in O(vertical bar Sigma vertical bar . 2(2)) time and O(vertical bar Sigma vertical bar . n) space, where n = vertical bar Q| is the number of states and vertical bar Sigma vertical bar is the size of the input alphabet. In the second part, we prove a weak Don's conjecture for this class of automata: a nonempty subset of states S subset of Q is reachable with a word of length at most 2n(n - vertical bar S vertical bar) - n . Hn - vertical bar S vertical bar, where H-i is the ith harmonic number. This implies a quadratic upper bound in = on the length of the shortest synchronizing words (reset threshold) for the class of completely reachable automata and generalizes earlier upper bounds derived for its subclasses.
Motivated by the Čherný conjecture for automata, we introduce the concept of monoidal automata, which allows us to formulate the Čherný conjecture for monoids. We obtain the upper bounds on the reset threshold of monoids with certain properties. In particular, we obtain a quadratic upper bound if the transformation monoid contains a primitive group of permutations and a singular of maximal rank with only one point of contraction.
We develop a method of adapting the AlphaZero model to General Game Playing (GGP) that focuses on faster model generation and requires less knowledge to be extracted from the game rules. The dataset generation uses MCTS playing instead of self-play; only the value network is used, and attention layers replace the convolutional ones. This allows us to abandon any assumptions about the action space and board topology. We implement the method within the Regular Boardgames GGP system and show that we can build models outperforming the UCT baseline for most games efficiently.
A complete deterministic finite (semi)automaton (DFA) with a set of states Q is completely reachable if every nonempty subset of Q is the image of the action of some word applied to Q. The concept of completely reachable automata appeared, in particular, in connection with synchronizing automata; the class contains the Černý automata and covers several distinguished subclasses. The notion was introduced by Bondar and Volkov (2016), who also raised the question about the complexity of deciding if an automaton is completely reachable. We develop an algorithm solving this problem, which works in 𝒪(|Σ|· n^2) time and 𝒪(|Σ|· n) space, where n=|Q| is the number of states and |Σ| is the size of the input alphabet. In the second part, we prove a weak Don's conjecture for this class of automata: a nonempty subset of states S ⊆ Q is reachable with a word of length at most 2n(n-|S|) - n · H_n-|S|, where H_i is the i-th harmonic number. This implies a quadratic upper bound in n on the length of the shortest synchronizing words (reset threshold) for the class of completely reachable automata and generalizes earlier upper bounds derived for its subclasses.
A complete deterministic finite (semi)automaton (DFA) with a set of states Q is completely reachable if every non-empty subset of Q can be obtained as the image of the action of some word applied to Q. The concept of completely reachable automata appeared several times, in particular, in connection with synchronizing automata; the class contains the Cerny automata and covers a few separately investigated subclasses. The notion was introduced by Bondar and Volkov (2016), who also raised the question about the complexity of deciding if an automaton is completely reachable. We develop a polynomial-time algorithm for this problem, which is based on a new complement-intersecting technique for finding an extending word for a subset of states. The algorithm works in O(|Sigma| center dot n(3)) time, where n = |Q| is the number of states and |Sigma| is the size of the input alphabet. Finally, we prove a weak Don's conjecture for this class of automata: a subset of size k is reachable with a word of length smaller than 2n( n - k). This implies a quadratic upper bound in n on the length of the shortest synchronizing words (reset threshold) for the class of completely reachable automata and generalizes earlier upper bounds derived for its subclasses.
A deterministic finite (semi)automaton is primitive if its transition monoid (semigroup) acting on the set of states has no non-trivial congruences. It is synchronizing if it contains a constant map (transformation). In analogy to synchronizing groups, we study the possibility of characterizing automata that are synchronizing if primitive. We prove that the implication holds for several classes of automata. In particular, we show it for automata whose every letter induce either a permutation or a semiconstant transformation (an idempotent with one point of contraction) unless all letters are of the first type. We propose and discuss two conjectures about possible more general characterizations.
A synchronizing word of a deterministic finite complete automaton is a word whose action maps every state to a single one. Finding a shortest or a short synchronizing word is a central computational problem in the theory of synchronizing automata and is applied in other areas such as model-based testing and the theory of codes. Because the problem of finding a shortest synchronizing word is computationally hard, among \emph{exact} algorithms only exponential ones are known. We redesign the previously fastest known exact algorithm based on the bidirectional breadth-first search and improve it with respect to time and space in a practical sense. We develop new algorithmic enhancements and adapt the algorithm to multithreaded and GPU computing. Our experiments show that the new algorithm is multiple times faster than the previously fastest one and its advantage quickly grows with the hardness of the problem instance. Given a modest time limit, we compute the lengths of the shortest synchronizing words for random binary automata up to 570 states, significantly beating the previous record. We refine the experimental estimation of the average reset threshold of these automata. Finally, we develop a general computational package devoted to the problem, where an efficient and practical implementation of our algorithm is included, together with several well-known heuristics.
In many games, moves consist of several decisions made by the player. These decisions can be viewed as separate moves, which is already a common practice in multi-action games for efficiency reasons. Such division of a player move into a sequence of simpler / lower level moves is called splitting. So far, split moves have been applied only in forementioned straightforward cases, and furthermore, there was almost no study revealing its impact on agents' playing strength. Taking the knowledge-free perspective, we aim to answer how to effectively use split moves within Monte-Carlo Tree Search (MCTS) and what is the practical impact of split design on agents' strength. This paper proposes a generalization of MCTS that works with arbitrarily split moves. We design several variations of the algorithm and try to measure the impact of split moves separately on efficiency, quality of MCTS, simulations, and action-based heuristics. The tests are carried out on a set of board games and performed using the Regular Boardgames General Game Playing formalism, where split strategies of different granularity can be automatically derived based on an abstract description of the game. The results give an overview of the behavior of agents using split design in different ways. We conclude that split design can be greatly beneficial for single- as well as multi-action games.
A deterministic finite automaton (DFA) with a set of states Q is completely reachable if every non-empty subset of Q is the image of the action of some word applied to Q . The concept was first introduced by Bondar and Volkov (2016), who also raised the question of the complexity of deciding if an automaton is completely reachable. We develop a polynomial-time algorithm for this problem, which is based on a complement-intersecting technique for finding an extending word for a subset of states. Additionally, we prove a weak Don’s conjecture for this class of automata: a subset of size k is reachable with a word of length at most 2( | Q | − k ) | Q | . This implies a quadratic upper bound in | Q | on the length of the shortest synchronizing words (reset threshold) and generalizes earlier upper bounds derived for subclasses of completely reachable automata.
For a DFA, a word avoids a subset of states, if after reading that word the automaton cannot be in any state from the subset regardless of its initial state. A subset that admits an avoiding word is avoidable. The k-avoiding threshold of a DFA is the smallest number such that every avoidable subset of size k can be avoided with a word no longer than that number. We study the problem of determining the maximum possible k-avoiding thresholds. For every fixed k ≥ 1, we show a general construction of strongly connected DFAs with n states and the k-avoiding threshold in Θ(n^k). This meets the known upper bound for k ≥ 3. For k = 1 and k = 2, the known upper bounds are respectively in 𝒪(n²) and in 𝒪(n³). For k = 1, we show that 2n-3 is attainable for every number of states n in the class of strongly connected synchronizing binary DFAs, which is supposed to be the best possible in the class of all DFAs for n ≥ 8. For k = 2, we show that the conjectured solution for k = 1 (an upper bound in 𝒪(n)) also implies a tight upper bound in 𝒪(n²) on 2-avoiding threshold. Finally, we discuss the possibility of using k-avoiding thresholds of synchronizing automata to improve upper bounds on the length of the shortest reset words.
We study synchronizing partial DFAs, which extend the classical concept of synchronizing complete DFAs and are a special case of synchronizing unambiguous NFAs. A partial DFA is called synchronizing if it has a word (called a reset word) whose action brings a non-empty subset of states to a unique state and is undefined for all other states. While in the general case the problem of checking whether a partial DFA is synchronizing is PSPACE-complete, we show that in the strongly connected case this problem can be efficiently reduced to the same problem for a complete DFA. Using combinatorial, algebraic, and formal languages methods, we develop techniques that relate main synchronization problems for strongly connected partial DFAs with the same problems for complete DFAs. In particular, this includes the Cerny and the rank conjectures, the problem of finding a reset word, and upper bounds on the length of the shortest reset words of literal automata of finite prefix codes. We conclude that solving fundamental synchronization problems is equally hard in both models, as an essential improvement of the results for one model implies an improvement for the other.
Given a subset of states S of a deterministic finite automaton and a word w, the preimage is the subset of all states mapped to a state in S by the action of w. We study three natural problems concerning words giving certain preimages. The first problem is whether, for a given subset, there exists a word extending the subset (giving a larger preimage). The second problem is whether there exists a totally extending word (giving the whole set of states as a preimage)—equivalently, whether there exists an avoiding word for the complementary subset. The third problem is whether there exists a resizing word. We also consider variants where the length of the word is upper bounded, where the size of the given subset is restricted, and where the automaton is strongly connected, synchronizing, or binary. We conclude with a summary of the complexities in all combinations of the cases.
We solve open problems concerning the Kleene star $L^*$ of a finite set $L$ of words over an alphabet $\Sigma$. The \emph{Frobenius monoid} problem is the question for a given finite set of words $L$, whether the language $L^*$ is cofinite. We show that it is PSPACE-complete. We also exhibit an infinite family of sets $L$ such that the length of the longest words not in $L^*$ (when $L^*$ is cofinite) is exponential in the length of the longest words in $L$ and subexponential in the sum of the lengths of words in $L$. The \emph{factor universality} problem is the question for a given finite set of words $L$, whether every word over $\Sigma$ is a factor (substring) of some word from $L^*$. We show that it is also PSPACE-complete. Besides that, we exhibit an infinite family of sets $L$ such that the length of the shortest words not being a factor of any word in $L^*$ is exponential in the length of the longest words in $L$ and subexponential in the sum of the lengths of words in $L$. This essentially settles in the negative the longstanding Restivo's conjecture (1981) and its weak variations. All our solutions base on one shared construction, and as an auxiliary general tool, we introduce the concept of \emph{set rewriting systems}. Finally, we complement the results with upper bounds.
We describe nearly fifteen years of General Game Playing experimental research history in the context of reproducibility and fairness of comparisons between various GGP agents and systems designed to play games described by different formalisms. We think our survey may provide an interesting perspective of how chaotic methods were allowed when nothing better was possible. Finally, from our experience-based view, we would like to propose a few recommendations of how such specific heterogeneous branch of research should be handled appropriately in the future. The goal of this note is to point out common difficulties and problems in the experimental research in the area. We hope that our recommendations will help in avoiding them in future works and allow more fair and reproducible comparisons.
We study the following natural variation on the classical universality problem: given a language L(M) represented by M (e.g., a DFA/RE/NFA/PDA), does there exist an integer l >= 0 such that Sigma(l) subset of L(M)? In the case of an NFA, we show that this problem is NEXPTIME-complete, and the smallest such l can be doubly exponential in the number of states. This particular case was formulated as an open problem in 2009, and our solution uses a novel and involved construction. In the case of a PDA, we show that it is recursively unsolvable, while the smallest such l is not bounded by any computable function of the number of states. In the case of a DFA, we show that the problem is NP-complete, and e root n log n(1+o(1)) is an asymptotically tight upper bound for the smallest such l, where n is the number of states. Finally, we prove that in all these cases, the problem becomes computationally easier when the length l is also given in binary in the input: it is polynomially solvable for a DFA, PSPACE-complete for an NFA, and co-NEXPTIME-complete for a PDA.
We present the technical side of reasoning in Regular Boardgames (RBG) language - a universal General Game Playing (GGP) formalism for the class of finite deterministic games with perfect information, encoding rules in the form of regular expressions. RBG serves as a research tool that aims to aid in the development of generalized algorithms for knowledge inference, analysis, generation, learning, and playing games. In all these tasks, both generality and efficiency are important.In the first part, this paper describes optimizations used by the RBG compiler. The impact of these optimizations ranges from 1.7 to even 33-fold efficiency improvement when measuring the number of possible game playouts per second. Then, we perform an in-depth efficiency comparison with three other modern GGP systems (GDL, Ludii, Ai Ai). We also include our own highly optimized game-specific reasoners to provide a point of reference of the maximum speed. Our experiments show that RBG is currently the fastest among the abstract general game playing languages, and its efficiency can be competitive to common interface-based systems that rely on handcrafted game-specific implementations. Finally, we discuss some issues and methodology of computing benchmarks like this.
Andrzej Kisielewicz合作论文数Institute of Mathematics
University of Wrocław9