Title: Reinforcement Learning with LTL and $\omega$-Regular Objectives via Optimality-Preserving Translation to Average Rewards
Venue: NeurIPS 2024
Accepted: yes
Keywords: Reinforcement Learning

LTL

limit average rewards

translation
Abstract: Linear temporal logic (LTL) and, more generally, $\omega$-regular objectives are alternatives to the traditional discount sum and average reward objectives in reinforcement learning (RL), offering the advantage of greater comprehensibility and hence explainability. In this work, we study the relationship between these objectives. Our main result is that each RL problem for $\omega$-regular objectives can be reduced to a limit-average reward problem in an optimality-preserving fashion, via (finite-memory) reward machines. Furthermore, we demonstrate the efficacy of this approach by showing that optimal policies for limit-average problems can be found asymptotically by solving a sequence of discount-sum problems approximately. Consequently, we resolve an open problem: optimal policies for LTL and $\omega$-regular objectives can be learned asymptotically.

Reinforcement Learning with LTL and ω -Regular Objectives via Optimality-Preserving Translation to Average Rewards

Abstract

Linear temporal logic (LTL) and, more generally, ω -regular objectives are alternatives to the traditional discount sum and average reward objectives in reinforcement learning (RL), offering the advantage of greater comprehensibility and hence explainability. In this work, we study the relationship between these objectives. Our main result is that each RL problem for ω -regular objectives can be reduced to a limit-average reward problem in an optimality-preserving fashion, via (finitememory) reward machines. Furthermore, we demonstrate the efficacy of this approach by showing that optimal policies for limit-average problems can be found asymptotically by solving a sequence of discount-sum problems approximately. Consequently, we resolve an open problem: optimal policies for LTL and ω -regular objectives can be learned asymptotically.

1 Introduction

Reinforcement learning (RL) is a machine learning paradigm whereby an agent aims to accomplish a task in a generally unknown environment [37]. Traditionally, tasks are specified via a scalar reward signal obtained continuously through interactions with the environment. These rewards are aggregated over entire trajectories either through averaging or by summing the exponentially decayed rewards. However, in many applications, there are no reward signals that can naturally be extracted from the environment. Moreover, reward signals that are supplied by the user are prone to error in that the chosen low-level rewards often fail to accurately capture high-level objectives. Generally, policies derived from local rewards-based specifications are hard to understand because it is difficult to express or explain their global intent.

As a remedy, it has been proposed to specify tasks using formulas in Linear Temporal Logic (LTL) [41, 30, 9, 38, 15, 34, 14] or ω -regular languages more generally [30]. In this framework, the aim is to maximise the probability of satisfying a logical specification. LTL can precisely express a wide range of high-level behavioural properties such as liveness (infinitely often P ), safety (always P ), stability (eventually always P ), and priority ( P then Q then T ).

Motivated by this, a growing body of literature study learning algorithms for RL with LTL and ω -regular objectives (e.g. [41, 15, 30, 7, 32, 20, 21, 16]). However, to the best of our knowledge, all of these approaches may fail to learn provably optimal policies without prior knowledge of a generally unknown parameter such as the optimal ϵ -return mixing time [15] or the ϵ -recurrence time [30],

which depend on the (unavailable) transition probabilities of the MDP. Moreover, it is known that neither LTL nor (limit) average reward objectives are PAC (probably approximately correct) learnable [2]. Consequently, approximately optimal policies can only possibly be found asymptotically but not in bounded time. 1

In this work, we pursue a different strategy: rather than solving the RL problem directly, we study optimality-preserving translations [2] from ω -regular objectives to more traditional rewards, in particular, limit-average rewards. This method offers a significant advantage: it enables the learning of optimal policies for ω -regular objectives by solving a single more standard problem, for which we can leverage existing off-the-shelf algorithms (e.g. [26, 15, 30]). In this way, all future advances-in both theory and practice-for these much more widely studied problems carry over directly, whilst still enjoying significantly more explainable and comprehensible specifications. It is well-known that such a translation from LTL to discounted rewards is impossible [2]. Intuitively, this is because the latter cannot capture infinite horizon tasks such as reachability or safety [2, 42, 19]. Hence, we instead investigate translations to limit-average rewards in this paper.

Contributions

We study reinforcement learning of ω -regular and LTL objectives in Markov decision processes (MDPs) with unknown probability transitions, translations to limit-average reward objectives and learning algorithms for the latter. In detail:

We prove a negative result (Proposition 4): in general it is not possible to translate ω -regular objectives to limit average objectives in an optimality-preserving manner if rewards are memoryless (i.e., independent of previously performed actions, sometimes called historyfree or Markovian).

On the other hand, our main result (Theorem 12) resolves Open Problem 1 in [2]: such an optimality-preserving translation is possible if the reward assignment may use finite memory as formalised by reward machines [23, 24].

To underpin the efficacy of our reduction approach, we provide the first convergence proof (Theorem 16) of an RL algorithm (Algorithm 1) for average rewards. To the best of our knowledge (and as indicated by [13]), this is the first proof without assumptions on the induced Markov chains . In particular, the result applies to multichain MDPs, which our translation generally produces, with unknown probability transitions. Consequently, we also resolve Open Problem 4 of [2]: RL for ω -regular and LTL objectives can be learned in the limit (Theorem 18).

Outline. We start by reviewing the problem setup in Section 2. Motivated by the impossibility result for simple reward functions, we define reward machines (Section 3). In Section 4 we build intuition for the proof of our main result in Section 5. Thereafter, we demonstrate that RL with limit-average, ω -regular and LTL objectives can be learned asymptotically (Section 6). Finally, we review related work and conclude in Section 7.

2 Background

Recall that a Markov Decision Process (MDP) is a tuple M = ( S, A, s 0 , P ) where S is a finite set of states, s 0 ∈ S is the initial state, A is the finite set of actions and P : S × A × S → [0 , 1] is the probability transition function such that ∑ s ′ ∈ S P ( s, a, s ′ ) = 1 for every s ∈ S and a ∈ A . MDPs may be graphically represented; see e.g. Fig. 1a. We let Runs fi ( S, A ) = S × ( A × S ) ∗ and Runs( S, A ) = ( S × A ) ω denote the set of finite runs and the set of infinite runs in M respectively.

A policy π : Runs fi ( S, A ) →D ( A ) maps finite runs to distributions over actions. We let Π( S, A ) denote the set of all such policies. A policy π is memoryless if π ( s 0 a 0 . . . s n ) = π ( s ′ 0 a ′ 0 . . . s ′ m ) for all finite runs s 0 a 0 . . . s n and s ′ 0 a ′ 0 . . . s ′ m such that s n = s ′ m . For each MDP M and policy π , there is a natural induced probability measure D M π on its runs.

The desirability of policies for a given MDP M can be expressed as a function J : Π( S, A ) → R . Much of the RL literature focuses on discounted-sum J R M γ and limit-average reward objectives J R M avg ,

s

0

start

s

1

a

b

b

(a) An MDP where all transitions occur with probability 1 , λ ( s 0 , b, s 1 ) = { p } and the rest are labeled with ∅ .

q

0

start

q

1

q

2

∅

{

p

}

∅

{

p

}

∗

(b) A DRA, where F := { ( { q 1 } , ∅ ) } , for the objective to visit the petrol station p exactly once.

which lift a reward function R : S × A × S → R for single transitions to runs ρ = s 0 a 0 s 1 a 1 . . . as follows:

where r i = R ( s i , a i , s i +1 ) and γ ∈ (0 , 1) is the discount factor .

ω -Regular Objectives. ω -regular objectives (which subsume LTL objectives) are an alternative to these traditional objectives. Henceforth, we fix an alphabet AP and a label function λ : S × A × S → 2 AP for transitions, where 2 X is the power set of a set X . Each run ρ = s 0 a 0 s 1 a 1 s 2 . . . induces a sequence of labels λ ( ρ ) = λ ( s 0 , a 0 , s 1 ) λ ( s 1 , a 1 , s 2 ) . . . . Thus, for a set L ⊆ (2 AP ) ω of 'desirable' label sequences we can consider the probability of a run's labels being in that set: P ρ ∼D M π [ λ ( ρ ) ∈ L ] .

Example 1. For instance, an autonomous car may want to 'visit a petrol station exactly once' to conserve resources (e.g. time or petrol). Consider the MDP in Fig. 1a where the state s 1 represents a petrol station. We let AP = { p } ( p for petrol), λ ( s 0 , b, s 1 ) = { p } , and the rest are labeled with ∅ . The desirable label sequences are L = { λ 1 λ 2 · · · | for exactly one i ∈ N , λ i = { p }} .

In this work, we focus on L which are ω -regular languages. It is well known that ω -regular languages are precisely the languages recognised by Deterministic Rabin Automata (DRA) [27, 29]:

̸

Definition 2. A DRA is a tuple A = ( Q, 2 AP , q 0 , δ, F ) where Q is a finite state set, 2 AP is the alphabet, q 0 ∈ Q is the initial state, δ : Q × 2 AP → Q is the transition function, and F = { ( A 1 , R 1 ) , . . . , ( A n , R n ) } , where A i , R i ⊆ Q , is the accepting condition. Let ρ ∈ (2 AP ) ω be an infinite run and InfS( ρ ) the set of states visited infinitely often by ρ . We say ρ is accepted by A if there exists some ( A i , R i ) ∈ F such that ρ visits some state in A i infinitely often whilst visiting every state in R i finitely often, i.e. InfS( ρ ) ∩ A i = ∅ and InfS( ρ ) ∩ R i = ∅ .

For example, the objective in Example 1 may be represented by the DRA in Fig. 1b.

Thus, the desirability of π is the probability of π generating an accepting sequence in the DRA A :

Remarks. The class of ω -regular languages subsumes languages expressed by Linear Temporal Logic (LTL, see e.g. [4, Ch. 5]), a logical framework in which e.g. reachability (eventually P , ♢ P ), safety (always P , □ P ) and reach-avoid (eventually P whilst avoiding Q , ( ¬ Q ) U P ) properties can be expressed concisely and intuitively. The specification of our running Example 1 to visit the petrol station exactly once can be expressed as the LTL formula ( ¬ p ) U ( p ∧ GLYPH<7> □ ¬ p ) , where GLYPH<7> Q denotes ' Q holds at the next step'. Furthermore, our label function λ , which maps transitions to labels, is more general than other definitions (e.g. [41, 15, 30]) instead mapping states to labels. As a result, we are able to articulate properties that involve actions, such as 'to reach the state s while avoiding taking the action a '.

Optimality-Preserving Specification Translations. Rather than solving the problem of synthesising optimal policies for Eq. (1) directly, we are interested in reducing it to more traditional RL

problems and applying off-the-shelf RL algorithms to find optimal policies. To achieve this, the reduction needs to be optimality preserving 2 :

Definition 3 ([2]) . An optimality-preserving specification translation from ω -regular objectives to limit-average rewards is a computable function mapping each tuple ( S, A, λ, A ) to R ( S,A,λ, A ) s.t.

for every MDP M = ( S, A, s 0 , P ) , label function λ : S × A × S → 2 AP and DRA A .

We stress that since the probability transition function P is generally not known, the specification translation may not depend on it.

3 Negative Result and Reward Machines

Reward functions emit rewards purely based on the transition being taken without being able to take the past into account. On the other hand, DRAs have finite memory. Therefore, there cannot generally be optimality-preserving translations from ω -regular objectives to limit average rewards provided by reward functions:

Proposition 4. There is an MDP M and an ω -regular language L for which it is impossible to find a reward function R : S × A × S → R such that every J R M avg -optimal policy of M also maximises the probability of membership in L .

Remarkably, this rules out optimality-preserving specification translations even if transition probabilities are fully known 3 .

Proof. Consider the deterministic MDP in Fig. 1a and the objective of Example 1 'to visit s 1 exactly once' expressed by the DRA A in Fig. 1b. Assume towards contradiction there exists a reward function R : S × A × S → R such that optimal policies w.r.t. J R M avg maximise acceptance by A . Note that every policy π ∗ maximising acceptance by the DRA induces the run s 0 ( as 0 ) n bs 1 bs 0 ( as 0 ) ω for some n ∈ N , and J A M ( π ∗ ) = 1 . Thus, its limit-average reward is J R M avg ( π ∗ ) = R ( s 0 , a, s 0 ) . Now, consider the policy π always selecting action a with probability 1 . As the run induced by π is s 0 ( as 0 ) ω , we deduce that J A M ( π ) = 0 and J R M avg ( π ) = R ( s 0 , a, s 0 ) = J R M avg ( π ∗ ) , which is a contradiction since π is not J A M -optimal.

Since simple reward functions lack the expressiveness to capture ω -regular objectives, we employ a generalisation, reward machines [23, 24], whereby rewards may also depend on an internal state:

Definition 5. A reward machine (RM) is a tuple R = ( U, u 0 , δ u , δ r ) where U is a finite set of states, u 0 ∈ U is the initial state, δ r : U × ( S × A × S ) → R is the reward function, and δ u : U × ( S × A × S ) → U is the update function.

Intuitively, a RM R utilises the current transition to update its states through δ u and assigns the rewards through δ r . For example, Fig. 2a depicts a reward machine for the MDP of Fig. 1a, where the states count the number of visits to s 1 (0 times, once, more than once).

Let ρ = s 0 a 0 s 1 · · · be an infinite run. Since δ u is deterministic, it induces a sequence u 0 u 1 . . . of states in R , where e i = ( s i , a i , s i +1 ) and u i +1 = δ u ( u i , e i ) . The limit-average reward of a policy π is defined as:

It is seen that limit-average optimal policies π ∗ for the MDP in Fig. 1a and the RM in Fig. 2a eventually select action b exactly once in state s 0 to achieve J R M avg ( π ∗ ) = 1 .

In the following two sections, we present a general translation from ω -regular languages to limitaverage reward machines, and we show that our translation is optimality-preserving (Theorem 12).

u

0

start

u

1

u

2

(

s

0

, a, s

0

)

/

0

(

s

1

, b, s

0

)

/

0

(

s

0

, b, s

1

)

/

0

(

s

0

, a, s

0

)

/

1

(

s

1

, b, s

0

)

/

0

(

s

0

, b, s

1

)

/

0

∗

/

0

(a) A reward machine for the objective of visiting the petrol station exactly once. (The rewards are given following '/'.)

(

s

0

, q

0

)

start

(

s

0

, q

1

)

(

s

0

, q

2

)

(

s

1

, q

0

)

(

s

1

, q

1

)

(

s

1

, q

2

)

b

a

b

b

a

b

b

a, b

(b) Product MDP for Fig. 1, where all transitions have probability 1 and F M := { ( { ( s 0 , q 1 ) , ( s 1 , q 1 ) } , ∅ ) } .

Remarks. Our definition of RM is more general than the one presented in [23, 24], where δ ′ u : U → [ S × A × S → R ] and δ ′ r : U × 2 AP → U . Note that ( δ ′ u , δ ′ r ) can be reduced to ( δ u , δ r ) by expanding the state space of the RM to include the previous state and utilising the inverse label function λ -1 . It is worth pointing out that Theorem 12 does not contradict a negative result in [2] regarding the non-existence of an optimality-preserving translation from LTL constraints to abstract limit-average reward machines (where only the label of transitions is provided to δ u and δ r ).

4 Warm-Up: Transitions with Positive Probability are Known

To help the reader gain intuition about our construction, we first explore the situation where the support { ( s, a, s ′ ) ∈ S × A × S | P ( s, a, s ′ ) > 0 } of the MDP's transition function is known. Crucially, we do not assume that the magnitude of these (non-zero) probabilities are known. Subsequently, in Section 5, we fully eliminate this assumption.

This assumption allows us to draw connections between our problem and a familiar scenario in probabilistic model checking [4, Ch. 10], where the acceptance problem for ω -regular objectives can be transformed into a reachability problem. Intuitively, our reward machine monitors the state of the DRA and provides reward 1 if the MDP and the DRA are in certain 'good' states ( 0 otherwise).

For the rest of this section, we fix an MDP without transition function ( S, A, s 0 ) , a set of possible transitions E ⊆ S × A × S , a label function λ : S × A × S → 2 AP and a DRA A = ( Q, 2 AP , q 0 , δ, F ) . Our aim is to find a reward machine R such that for every transition function P compatible with E (formally: E = { ( s, a, s ′ ) | P ( s, a, s ′ ) > 0 } ), optimal policies for limit-average rewards are also optimal for the acceptance probability of the DRA A .

4.1 Product MDP and End Components

First, we form the product MDP M⊗A (e.g. [41, 15]), which synchronises the dynamics of the MDP M with the DRA A . Formally, M⊗A = ( V, A, v 0 , ∆ , F M ) where V = S × Q is the set of states, A is the set of actions, v 0 = ( s 0 , q 0 ) is the initial state. The transition probability function ∆ : V × A × V → [0 , 1] satisfies ∆( v, a, v ′ ) = P ( s, a, s ′ ) given that v = ( s, q ) , v ′ = ( s ′ , q ′ ) , and δ ( q, λ ( s, a, s ′ )) = q ′ . The accepting condition is F M = { ( A ′ 1 , R ′ 1 ) , ( A ′ 2 , R ′ 2 ) , . . . } where A ′ i = S × A i , R ′ i = S × R i , and ( A i , R i ) ∈ F . A run ρ = ( s 0 , q 0 ) a 0 · · · is accepted by M⊗A if there exists some ( A ′ i , R ′ i ) ∈ F M such that InfV( ρ ) ∩ A ′ i = ∅ and InfV( ρ ) ∩ R ′ i = ∅ , where InfV is the set of states ( s, v ) in the product MDP visited infinitely often by ρ .

̸

Note that product MDPs have characteristics of both MDPs and DRAs which neither possesses in isolation: transitions are generally probabilistic and there is a notation of acceptance of runs. For example, the product MDP for Fig. 1 is shown in Fig. 2b. Due to the deterministic nature of the DRA A , every run ρ in M gives rise to a unique run ρ ⊗ in M⊗A . Crucially, for every policy π ,

We make use of well-known almost-sure characterisation of accepting runs via the notion of accepting end components:

Definition 6. An end component (EC) of M⊗A = ( V, A, v 0 , ∆ , F M ) is a pair ( T, Act) where T ⊆ V and Act : T → 2 A satisfies the following conditions

For every v ∈ T and a ∈ Act( v ) , we have ∑ v ′ ∈ T ∆( v, a, v ′ ) = 1 , and

The graph ( T, → Act ) is strongly connected, where v → Act v ′ iff ∆( v, a, v ′ ) > 0 for some a ∈ Act( v ) .

̸

( T, Act) is an accepting EC (AEC) if T ∩ A ′ i = ∅ and T ∩ R ′ i = ∅ for some ( A ′ i , R ′ i ) ∈ F M .

Intuitively, an EC is a strongly connected sub-MDP. For instance, for the product MDP in Fig. 2b there are five end components, ( { ( s 0 , q 0 ) } , ( s 0 , q 0 ) ↦→ { a } ) , ( { ( s 0 , q 1 ) } , ( s 0 , q 1 ) ↦→ { a } ) , ( { ( s 0 , q 2 ) } , ( s 0 , q 2 ) ↦→ { a } ) , ( { ( s 0 , q 2 ) } , ( s 0 , q 2 ) ↦→ { b } ) and ( { ( s 0 , q 2 ) } , ( s 0 , q 2 ) ↦→ { a, b } ) . ( { ( s 0 , q 1 ) } , ( s 0 , q 1 ) ↦→{ a } ) is its only accepting end component.

It turns out that, almost surely, a run is accepted iff it enters an accepting end component and never leaves it [1]. Therefore, a natural idea for a reward machine is to use its state to keep track of the state q ∈ Q the DRA is in and give reward 1 to transitions ( s, a, s ′ ) if ( s, q ) is in some AEC (and 0 otherwise). Unfortunately, this approach falls short since the AEC may contain non-accepting ECs, thus assigning maximal reward to sub-optimal policies. 4 As a remedy, we introduce a notion of minimal AEC, and ensure that only runs eventually committing to one such minimal AEC get a limit-average reward of 1.

Definition 7. An AEC ( T, Act) is an accepting simple EC (ASEC) if | Act( v ) | = 1 for every v ∈ T .

Let C 1 = ( T 1 , Act 1 ) , . . . , C n = ( T n , Act n ) be a collection of ASECs covering all states in ASECs, i.e. if ( s, q ) is in some ASEC then ( s, q ) ∈ T 1 ∪ · · · ∪ T n . In particular, n ≤ | S × Q | is sufficient.

We can prove that every AEC contains an ASEC (see Lemma 20 in Appendix B). Consequently,

Lemma 8. Almost surely, if ρ is accepted by A then ρ reaches a state in some ASEC C of M⊗A .

4.2 Reward Machine and Correctness

Next, to ensure that runs eventually commit to one such ASEC we introduce the following notational shorthand: for ( s, q ) ∈ T 1 ∪ · · · ∪ T n , let C ( s,q ) = ( T ( s,q ) , Act ( s,q ) ) be the C i with minimal i containing ( s, q ) , i.e. C ( s,q ) := C min { 1 ≤ i ≤ n | ( s,q ) ∈ T i } .

Intuitively, we give a reward of 1 if ( s, q ) is in one of the C 1 , . . . , C n . However, once an action is performed which deviates from Act ( s,q ) no rewards are given thereafter, thus resulting in a limit average reward of 0 .

A state in the reward machine has the form q ∈ Q , keeping track of the state in the DRA, or ⊥ , which is a sink state signifying that in a state in C 1 , . . . , C n we have previously deviated from Act ( s,q ) .

Finally, we are ready to formally define the reward machine R = R ( S,A,λ, A ) exhibiting our specification translation as ( Q ∪ {⊥} , q 0 , δ u , δ r ) , where

̸

For our running example, this construction essentially yields the reward machine in Fig. 2a (with some inconsequential modifications cf. Fig. 4 in Appendix B).

Theorem 9. For all transition probability functions P with support E , policies maximising the limit-average reward w.r.t. R also maximise the acceptance probability of the DRA A .

This result follows immediately from the following (the full proof is presented in Appendix B):

⊗ i

Lemma 10. Let P be a probability transition function with support E and M := ( S, A, s 0 , P ) .

For every policy π , J R M avg ( π ) ≤ J A M ( π ) .

For every policy π , there exists some policy π ′ satisfying J A M ( π ) ≤ J R M avg ( π ′ ) .

Proof sketch. 1. By construction, every run receiving a limit-average reward of 1 , must have entered some ASEC C i and never left it. Furthermore, almost surely all states are visited infinitely often and the run is accepted by definition of accepting ECs.

2. By Lemma 8, almost surely, a run is only accepted if it enters some C i . We set π ′ to be the policy agreeing with π until reaching one of the C 1 , . . . , C n and henceforth following the action Act ( s t ,q t ) ( s t , q t ) , where q t is the state of the DRA at step t , yielding a guaranteed limit-average reward of 1 for the run by construction.

Remark 11. Our construction considers a collection of ASECs covering all states in ASECs. Whilst it does not necessarily require listing all possible ASECs but only (up to) one ASEC per state, it is unclear whether this can be obtained in polynomial time. In Appendix B.1, we present an alternative (yet more complicated) construction which has polynomial time complexity.

5 Main Result

In this section, we generalise the approach of the preceding section to prove our main result:

Theorem 12. There exists an optimality-preserving translation from ω -regular languages to limitaverage reward machines.

Again, we fix an MDP without transition function ( S, A, s 0 ) , a label function λ : S × A × S → 2 AP and a DRA A = ( Q, 2 AP , q 0 , δ, F ) . Note that the ASECs of a product MDP are uniquely determined by the non-zero probability transitions. Thus, for each set of transitions E ⊆ ( S × Q ) × A × ( S × Q ) , we let C E 1 = ( T 1 , Act 1 ) , . . . , C E n = ( T n , Act n ) denote a collection of ASECs covering all states in ASECs w.r.t. the MDPs in which E is the set of non-zero probability transitions. 5 Then, for each set E and state ( s, q ) ∈ T E 1 ∪··· ∪ T E n , we let C E ( s,q ) = ( T E ( s,q ) , Act E ( s,q ) ) be the ASEC C E i that contains ( s, q ) in which the index i is minimal.

Our reward machine R = R ( S,A,λ, A ) extends the ideas from the preceding section. Importantly, we keep track of the set of transitions E taken so far and assign rewards according to our current knowledge about the graph of the product MDP. Therefore, we propose employing states of the form ( q, f, E ) , where q ∈ Q keeps track of the state of the DRA, f ∈ {⊤ , ⊥} is a status flag and E ⊆ ( S × Q ) × A × ( S × Q ) memorises the transitions in the product MDP encountered thus far.

Intuitively, we set the flag to ⊥ if we are in MDP state s , ( s, q ) is in one of the C E 1 , . . . , C E n and the chosen action deviates from Act E ( s,q ) ( s, q ) . We can recover from ⊥ by discovering new transitions. Besides, we give reward 1 if f = ⊤ and ( s, q ) is in one of the C E 1 , . . . , C E n (and 0 otherwise).

The status flag is required since discovering new transitions will change the structure of (accepting simple) end components. Hence, differently from the preceding section, it is not sufficient to have a single sink state.

The initial state of our reward machine is u 0 := ( q 0 , ⊤ , ∅ ) and we formally define the update and reward functions as follows:

Example 13. For our running example (see Example 1 and Fig. 1) initially no transitions are known (hence no ASECs). Therefore, all transitions receive reward 0 . Once action a has been performed in state s 0 in the MDP M and ( q 1 , f, E ) in the reward machine R , we have discovered the ASEC ( { ( s 0 , q 1 ) } , ( s 0 , q 1 ) ↦→{ a } ) and a reward of 1 is given henceforth unless action b is selected eventually. In that case, we leave the ASEC and we will not discover further ASECs since there is only one. From here, it is not possible to return to state q 1 in the DRA and henceforth only reward 0 will be obtained.

Theorem 12 is proven by demonstrating an extension of Lemma 10 (see Appendix C):

Lemma 14. Suppose M = ( S, A, s 0 , P ) is an arbitrary MDP.

For every policy π , J R M avg ( π ) ≤ J A M ( π ) .

For every policy π , there exists some policy π ′ satisfying J A M ( π ) ≤ J R M avg ( π ′ ) .

Note that Lemma 14 immediately proves that the reduction is not only optimality preserving (Theorem 12) but also robust: every ϵ -approximately limit-average optimal policy is also ϵ -approximately optimal w.r.t. J A M . This observation is important because exactly optimal policies for the limit average problem may be hard to find.

Intuitively, to see part 1 of Lemma 14 we note: If an average reward of 1 is obtained for a run, the reward machine believes, based on the partial observation of the product MDP, that the run ends up in an ASEC. Almost surely, we eventually discover all possible transitions involving the same state-action pairs as this ASEC and therefore this must also be an ASEC w.r.t. the true, unknown product MDP. For part 2, we modify the policy π similarly as in Lemma 10 by selecting actions Act( s t , q t ) once having entered an ASEC C = ( T, Act) w.r.t. the true, unknown product MDP. 6

6 Convergence for Limit Average, ω -Regular and LTL Objectives

Thanks to the described translation, advances (in both theory and practice) in the study of RL with average rewards carry over to RL with ω -regular and LTL objectives. In this section, we show that it is possible to learn optimal policies for limit average rewards in the limit. Hence, we resolve an open problem [2]: also RL with ω -regular and LTL objectives can also be learned in the limit.

We start with the case of simple reward functions R : S × A × S → R . Recently, [18, Theorem 4.2] have shown that discount optimal policies for sufficiently high discount factor γ ∈ [0 , 1) are also limit average optimal. 7 This result alone is not enough to demonstrate Theorem 16 since γ is generally not known and in finite time we might only obtain approximately limit average optimal policies.

Our approach is to reduce RL with average rewards to a sequence of discount sum problems with increasingly high discount factor, which are solved with increasingly high accuracy. Our crucial insight is that eventually the approximately optimal solutions to the discounted problems will also be limit average optimal (see Appendix D for a proof):

Lemma 15. Suppose γ k ↗ 1 , ϵ k ↘ 0 and suppose each π k is a memoryless policy. Then there exists k 0 such that for all K ∋ k ≥ k 0 , π k is limit average optimal, where K is the set of k ∈ N satisfying J R M γ k ( π k ) ≥ J R M γ k ( π ) -ϵ k for all memoryless policies π .

Our proof harnesses yet another notion of optimality: a policy π is Blackwell optimal (cf. [6] and [22, Sec. 8.1]) if there exists γ ∈ (0 , 1) such that π is γ -discount optimal for all γ ≤ γ < 1 . It is well-known that memoryless Blackwell optimal policies always exist [6, 18] and they are also limit-average optimal [22, 18].

Thanks to the PAC (probably approximately correct) learnability of RL with discounted rewards [26, 36], there exists an algorithm Discounted which receives as inputs a simulator for M , R as well as γ, ϵ and δ , and with probability 1 -δ returns an ϵ -optimal memoryless policy for discount factor γ . In view of Lemma 15, our approach is to run the PAC algorithm for discount-sum RL for increasingly large discount factors γ and increasingly low δ and ϵ (Algorithm 1).

Theorem 16. RL with average reward functions can be learned in the limit by Algorithm 1: almost surely there exists k 0 ∈ N such that π k is limit-average optimal for k ≥ k 0 .

Proof. Using the definition for K of Lemma 15 of iterations where the PAC-MDP algorithm succeeds,

The claim follows immediately with Lemma 15.

Next, we turn to the more general case of reward machines . [23, 24] observe that optimal policies for reward machines can be learned by learning optimal policies for the modified MDP which additionally tracks the state the reward machine is in and assigns rewards accordingly. We conclude at once:

Corollary 17. RL with average reward machines can be learned in the limit.

Finally, harnessing Theorem 12 we resolve Open Problem 4 of [2]:

Theorem 18. RL with ω -regular and LTL objectives can be learned in the limit.

Discussion. Algorithm 1 makes independent calls to black box algorithms for discount sum rewards. Many such algorithms with PAC guarantees are model based (e.g. [26, 36]) and sample from the MDP to obtain suitable approximations of the transition probabilities. Thus, Algorithm 1 can be improved in practice by re-using approximations obtained in earlier iterations and refining them.

7 Related Work and Conclusion

The connection between acceptance of ω -regular languages in the product MDP and AECs is wellknown in the field of probabilistic model checking [4, 12]. As an alternative to DRAs [41, 14, 32], Limit Deterministic Büchi Automata [35] have been employed to express ω -regular languages for RL [38, 7, 10, 20, 21].

A pioneering work on RL for ω -regular rewards is [41], which expresses ω -regular objectives using Deterministic Rabin Automata. Similar RL approaches for ω -regular objectives can also be found in [14, 38, 10, 15]. The authors of [15, 30] approach RL for ω -regular objectives directly by studying the reachability of AECs in the product MDP and developing variants of the R-MAX algorithm [8] to find optimal policies. However, these approaches require prior knowledge of the MDP, such as the structure of the MDP, the optimal ϵ -return mixing time [15], or the ϵ -recurrence time [30].

Various studies have explored reductions of ω -regular objectives to discounted rewards, and subsequently applied Q-learning and its variants for learning optimal policies [7, 32, 20, 21, 16]. In a similar spirit, [39] present a translation from LTL objectives to eventual discounted rewards, where only strictly positive rewards are discounted. These translations are generally not optimality preserving unless the discount factor is selected in a suitable way. Again, this is impossible without prior knowledge of the exact probability transition functions in the MDP.

[25] propose a translation to limit-average rewards for ω -regular specifications which are also absolute liveness properties. (In particular, optimal policies satisfy such specifications with either probability 0 or 1 .) Their translation is optimality-preserving provided the MDP is communicating and the magnitute of penalty rewards in their construction are chosen sufficiently large (which requires knowledge of the MDP).

Furthermore, whilst there are numerous convergent RL algorithms for average rewards for unichain or communicating 8 MDPs (e.g. [8, 43, 17, 33, 3, 40]), it is unknown whether such an algorithm exists for general multichain MDPs with a guaranteed convergence property. In fact, a negative result in [2, 5] shows that there is no PAC (probably approximately correct) algorithm for LTL objectives and limit-average rewards when the MDP transition probabilities are unknown.

[8] have proposed an algorithm with PAC guarantees provided ϵ -return mixing times are known. They informally argue that for fixed sub-optimality tolerance ϵ , this assumption can be lifted by guessing increasingly large candidates for the ϵ -return mixing time. This yields ϵ -approximately optimal policies in the limit. However, it is not clear how to asymptotically obtain exactly optimal policies as this would require simultaneously decreasing ϵ and increasing guesses for the ϵ -return mixing time (which depends on ϵ ).

Conclusion. We have presented an optimality-preserving translation from ω -regular objectives to limit-average rewards furnished by reward machines. As a consequence, off-the-shelf RL algorithms for average rewards can be employed in conjunction with our translation to learn policies for ω -regular objectives. Furthermore, we have developed an algorithm asymptotically learning provably optimal policies for limit-average rewards. Hence, also optimal policies for ω -regular and LTL objectives can be learned in the limit. Our results provide affirmative answers to two open problems in [2].

Limitations. We focus on MDPs with finite state and action sets and assume states are fully observable. The assumption of Section 4 that the support of the MDP's probability transition function is known is eliminated in Section 5. Whilst the size of our general translation-the first optimalitypreserving translation-is exponential, the additional knowledge in Section 4 enables a construction of the reward machine of the same size as the DRA expressing the objective. Hence, we conjecture that this size is minimal relative to the DRA specification. Since RL with average rewards is not PAC learnable, we cannot possibly provide finite-time complexity guarantees of our Algorithm 1.

Acknowledgments and Disclosure of Funding

This research is supported by the National Research Foundation, Singapore, under its RSS Scheme (NRFRSS2022-009).

References

Luca Alfaro. Formal Verification of Probabilistic Systems . Phd thesis, Stanford University, Stanford, CA, USA, 1998.

Rajeev Alur, Suguman Bansal, Osbert Bastani, and Kishor Jothimurugan. A framework for transforming specifications in reinforcement learning. In Jean-François Raskin, Krishnendu Chatterjee, Laurent Doyen, and Rupak Majumdar, editors, Principles of Systems Design: Essays Dedicated to Thomas A. Henzinger on the Occasion of His 60th Birthday , pages 604-624, Cham, 2022. Springer Nature Switzerland.

Peter Auer, Thomas Jaksch, and Ronald Ortner. Near-optimal regret bounds for reinforcement learning. In D. Koller, D. Schuurmans, Y. Bengio, and L. Bottou, editors, Advances in Neural Information Processing Systems , volume 21. Curran Associates, Inc., 2008.

Christel Baier and Joost-Pieter Katoen. Principles of Model Checking . The MIT Press, 2008.

Hugo Bazille, Blaise Genest, Cyrille Jégourel, and Jun Sun. Global PAC bounds for learning discrete time Markov chains. In Shuvendu K. Lahiri and Chao Wang, editors, Computer Aided Verification - 32nd International Conference, CAV 2020, Los Angeles, CA, USA, July 21-24, 2020, Proceedings, Part II , volume 12225 of Lecture Notes in Computer Science , pages 304-326. Springer, 2020.

David Blackwell. Discrete Dynamic Programming. The Annals of Mathematical Statistics , 33(2):719 - 726, 1962.

Alper Kamil Bozkurt, Yu Wang, Michael M. Zavlanos, and Miroslav Pajic. Control synthesis from Linear Temporal Logic specifications using model-free reinforcement learning. 2020 IEEE International Conference on Robotics and Automation (ICRA) , pages 10349-10355, 2019.

Ronen I. Brafman and Moshe Tennenholtz. R-max - A general polynomial time algorithm for near-optimal reinforcement learning. J. Mach. Learn. Res. , 3(null):213-231, mar 2003.

Tomáš Brázdil, Krishnendu Chatterjee, Martin Chmelik, Vojtˇ ech Forejt, Jan Kˇ retínsk` y, Marta Kwiatkowska, David Parker, and Mateusz Ujma. Verification of Markov Decision Processes using learning algorithms. In Automated Technology for Verification and Analysis: 12th International Symposium, ATVA 2014, Sydney, NSW, Australia, November 3-7, 2014, Proceedings 12 , pages 98-114. Springer, 2014.

Mingyu Cai, Shaoping Xiao, Zhijun Li, and Zhen Kan. Optimal probabilistic motion planning with potential infeasible LTL constraints. IEEE Transactions on Automatic Control , 68(1):301316, 2023.

Krishnendu Chatterjee and Monika Henzinger. Faster and dynamic algorithms for maximal end-component decomposition and related graph problems in probabilistic verification. In Dana Randall, editor, Proceedings of the Twenty-Second Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 2011, San Francisco, California, USA, January 23-25, 2011 , pages 1318-1336. SIAM, 2011.

Luca de Alfaro. Computing minimum and maximum reachability times in probabilistic systems. In Jos C. M. Baeten and Sjouke Mauw, editors, CONCUR'99 Concurrency Theory , pages 66-81, Berlin, Heidelberg, 1999. Springer Berlin Heidelberg.

Vektor Dewanto, George Dunn, Ali Eshragh, Marcus Gallagher, and Fred Roosta. Averagereward model-free reinforcement learning: A systematic review and literature mapping, 2021.

Xuchu Ding, Stephen L. Smith, Calin Belta, and Daniela Rus. Optimal control of Markov Decision Processes with Linear Temporal Logic constraints. IEEE Transactions on Automatic Control , 59(5):1244-1257, 2014.

Jie Fu and Ufuk Topcu. Probably approximately correct MDP learning and control with Temporal Logic constraints. In Dieter Fox, Lydia E. Kavraki, and Hanna Kurniawati, editors, Robotics: Science and Systems X, University of California, Berkeley, USA, July 12-16, 2014 , 2014.

Qitong Gao, Davood Hajinezhad, Yan Zhang, Yiannis Kantaros, and Michael M. Zavlanos. Reduced variance deep reinforcement learning with Temporal Logic specifications. In Proceedings of the 10th ACM/IEEE International Conference on Cyber-Physical Systems , ICCPS '19, page 237-248, New York, NY, USA, 2019. Association for Computing Machinery.

Abhijit Gosavi. Reinforcement learning for long-run average cost. European Journal of Operational Research , 155(3):654-674, 2004. Traffic and Transportation Systems Analysis.

Julien Grand-Clément and Marek Petrik. Reducing Blackwell and average optimality to discounted MDPs via the Blackwell discount factor. In Alice Oh, Tristan Naumann, Amir Globerson, Kate Saenko, Moritz Hardt, and Sergey Levine, editors, Advances in Neural Information Processing Systems 36: Annual Conference on Neural Information Processing Systems 2023, NeurIPS 2023, New Orleans, LA, USA, December 10 - 16, 2023 , 2023.

Ernst Moritz Hahn, Mateo Perez, Sven Schewe, Fabio Somenzi, Ashutosh Trivedi, and Dominik Wojtczak. Omega-regular objectives in model-free reinforcement learning. In Tomáš Vojnar and Lijun Zhang, editors, Tools and Algorithms for the Construction and Analysis of Systems , pages 395-412, Cham, 2019. Springer International Publishing.

Hosein Hasanbeig, Daniel Kroening, and Alessandro Abate. Certified reinforcement learning with logic guidance. Artificial Intelligence , 322:103949, 2023.

Mohammadhosein Hasanbeig, Daniel Kroening, and Alessandro Abate. Deep reinforcement learning with Temporal Logics. In Nathalie Bertrand and Nils Jansen, editors, Formal Modeling and Analysis of Timed Systems , pages 1-22, Cham, 2020. Springer International Publishing.

Arie Hordijk and Alexander A. Yushkevich. Blackwell Optimality , pages 231-267. Springer US, Boston, MA, 2002.

Rodrigo Toro Icarte. Reward Machines . Phd thesis, University of Toronto, 03 2022.

Rodrigo Toro Icarte, Toryn Klassen, Richard Valenzano, and Sheila McIlraith. Using reward machines for high-level task specification and decomposition in reinforcement learning. In Jennifer Dy and Andreas Krause, editors, Proceedings of the 35th International Conference on Machine Learning , volume 80 of Proceedings of Machine Learning Research , pages 2107-2116. PMLR, 10-15 Jul 2018.

Milad Kazemi, Mateo Perez, Fabio Somenzi, Sadegh Soudjani, Ashutosh Trivedi, and Alvaro Velasquez. Translating omega-regular specifications to average objectives for model-free reinforcement learning. In Piotr Faliszewski, Viviana Mascardi, Catherine Pelachaud, and Matthew E. Taylor, editors, 21st International Conference on Autonomous Agents and Multiagent Systems, AAMAS 2022, Auckland, New Zealand, May 9-13, 2022 , pages 732-741. International Foundation for Autonomous Agents and Multiagent Systems (IFAAMAS), 2022.

Michael Kearns and Satinder Singh. Near-optimal reinforcement learning in polynomial time. Machine Learning , 49:209-232, 2002.

Bakhadyr Khoussainov and Anil Nerode. Automata Theory and its Applications . Birkhäuser Boston, Boston, MA, 2001.

Achim Klenke. Probability Theory: A Comprehensive Course . Universitext. Springer London, 2014.

Dexter Kozen. Theory of Computation . Springer, London, 2006.

Mateo Perez, Fabio Somenzi, and Ashutosh Trivedi. A PAC learning algorithm for LTL and omega-regular objectives in MDPs. Proceedings of the AAAI Conference on Artificial Intelligence , 38(19):21510-21517, 2024.

Martin L. Puterman. Markov Decision Processes: Discrete Stochastic Dynamic Programming . John Wiley & Sons, Inc., USA, 1st edition, 1994.

Dorsa Sadigh, Eric S. Kim, Samuel Coogan, S. Shankar Sastry, and Sanjit A. Seshia. A learning based approach to control synthesis of Markov Decision Processes for Linear Temporal Logic specifications. In 53rd IEEE Conference on Decision and Control , pages 1091-1096, 2014.

Anton Schwartz. A reinforcement learning method for maximizing undiscounted rewards. In International Conference on Machine Learning , 1993.

Daqian Shao and Marta Kwiatkowska. Sample efficient model-free reinforcement learning from LTL specifications with optimality guarantees. IJCAI International Joint Conference on Artificial Intelligence , 2023-Augus:4180-4189, 2023.

Salomon Sickert, Javier Esparza, Stefan Jaax, and Jan Kˇ retínský. Limit-deterministic Büchi automata for Linear Temporal Logic. In Swarat Chaudhuri and Azadeh Farzan, editors, Computer Aided Verification , pages 312-332, Cham, 2016. Springer International Publishing.

Alexander L. Strehl, Lihong Li, and Michael L. Littman. Reinforcement learning in finite MDPs: PAC analysis. J. Mach. Learn. Res. , 10:2413-2444, 2009.

Richard S. Sutton and Andrew G. Barto. Reinforcement Learning: An Introduction . A Bradford Book, Cambridge, MA, USA, 2018.

Cameron Voloshin, Hoang Le, Swarat Chaudhuri, and Yisong Yue. Policy optimization with Linear Temporal Logic constraints. Advances in Neural Information Processing Systems , 35:17690-17702, 2022.

Cameron Voloshin, Abhinav Verma, and Yisong Yue. Eventual discounting Temporal Logic counterfactual experience replay. In Andreas Krause, Emma Brunskill, Kyunghyun Cho, Barbara Engelhardt, Sivan Sabato, and Jonathan Scarlett, editors, International Conference on Machine Learning, ICML 2023, 23-29 July 2023, Honolulu, Hawaii, USA , volume 202 of Proceedings of Machine Learning Research , pages 35137-35150. PMLR, 2023.

Yi Wan, Abhishek Naik, and Richard S. Sutton. Learning and planning in average-reward Markov Decision Processes. In Marina Meila and Tong Zhang, editors, Proceedings of the 38th International Conference on Machine Learning, ICML 2021, 18-24 July 2021, Virtual Event , volume 139 of Proceedings of Machine Learning Research , pages 10653-10662. PMLR, 2021.

Eric M. Wolff, Ufuk Topcu, and Richard M. Murray. Robust control of uncertain Markov Decision Processes with Temporal Logic specifications. In 2012 IEEE 51st IEEE Conference on Decision and Control (CDC) , pages 3372-3379, 2012.

Cambridge Yang, Michael L. Littman, and Michael Carbin. On the (in)tractability of reinforcement learning for LTL objectives. IJCAI International Joint Conference on Artificial Intelligence , pages 3650-3658, 2022.

Shangdong Yang, Yang Gao, Bo An, Hao Wang, and Xingguo Chen. Efficient average reward reinforcement learning using constant shifting values. Proceedings of the AAAI Conference on Artificial Intelligence , 30(1), 2016.

s

0

start

s

1

s

3

s

2

a/

1

a/

1

b/p

2

a/p

1

a/

1

-

p

1

1

-

p

2

1

q

0

start

q

1

{

c

}

∅

{

c

}

∅

(a) An MDP M where λ ( s 1 , a, s 1 ) = λ ( s 3 , b, s 0 ) = { c } , and the rest are labeled with ∅ .

(b) A DRA A for the objective of visiting s 1 or s 3 infinitely often where F := { ( { q 1 } , ∅ ) } .

A Supplementary Materials for Section 3

Recall that a ω -regular language L is prefix-independent if for every infinite label sequence w ∈ (2 AP ) ω , we have w ∈ L iff w ′ ∈ L for every suffix w ′ of w . We prove that there is no optimality-preserving translation for reward functions regardless of whether L is prefix-independent or not. The prefix-dependent case was given in Section 3. Here we focus on the other case:

Proposition 19. There exists a tuple ( S, A, s 0 , λ ) and a prefix-independent ω -regular language L for which it is impossible to find a reward function R : S × A × S → R such that for every probability transition P , let M = ( S, A, s 0 , P, λ ) , then every R avg -optimal policy of M is also L -optimal (i.e. maximizing the probability of membership in L ).

Proof. Our proof technique is based on the fact that we can modify the transition probability function. Consider the MDP in Fig. 3a, where the objective is to visit either s 1 or s 3 infinitely often. It can be checked that the DRA in Fig. 3b captures the given objective and the language accepted by A is prefix-independent. There are only two deterministic memoryless policies: π 1 , which consistently selects action a , and π 2 , which consistently selects action b . For the sake of contradiction, let's assume the existence of a reward function R that preserves optimality for every transition probability function P . Pick p 1 = 1 and p 2 = 0 . Then J A M ( π 1 ) = 1 and J A M ( π 2 ) = 0 , which implies that π 1 is A -optimal whereas π 2 is not. Thus R ( s 1 , a, s 1 ) = J R M avg ( π 1 ) > J R M avg ( π 2 ) = R ( s 0 , b, s 0 ) . Now, assume p 1 , p 2 ∈ (0 , 1) . Accordingly, we have J R M avg ( π 1 ) ≥ p 1 R ( s 1 , a, s 1 ) and we can deduce that (e.g. by solving the linear equation system described in [31, §8.2.3]) J R M avg ( π 2 ) = p 2 2 -p 2 R ( s 0 , b, s 0 ) + 1 -p 2 2 -p 2 ( R ( s 0 , b, s 3 ) + R ( s 3 , b, s 0 )) . As a result:

Consequently, if p 1 , p 2 are sufficiently large then J R M avg ( π 1 ) > J R M avg ( π 2 ) . However, this contradicts to the fact that π 2 is A -optimal and π 1 is not, since J A M ( π 2 ) = 1 > p 1 = J A M ( π 1 ) . Hence, there is no such reward function R .

B Supplementary Materials for Section 4

Lemma 20. Every AEC contains an ASEC.

Proof. Consider an AEC C = ( T, Act) of M A . We will prove this by using induction on the number of actions in C , denoted as size ( C ) := ∑ s ∈ T | Act( s ) | ≥ 1 . For the base case where size ( C ) = 1 , it can be deduced that C consists of only one accepting state with a self-loop. Therefore, C itself is an ASEC.

̸

Now, let's assume that size ( C ) = k +1 ≥ 2 . If C is already an ASEC, then we are done. Otherwise, there exists a state s ∈ T such that | Act( s ) | > 1 . Since C is strongly connected, there exists a finite path ρ = sas 1 a 1 . . . s n a n s F where s F is an accepting state and all the states s 1 , . . . , s n are different from s . Let a ′ ∈ Act( s ) such that a ′ = a . We construct a new AEC C ′ = ( T ′ , Act ′ ) by first removing a ′ from Act( s ) and then removing all the states that are no longer reachable from s along with their associated transitions. It is important to note that after the removal, s F ∈ T ′ since we can reach s F from s without taking the action a ′ . (Besides, the graph is still strongly connected.) Since size ( C ′ ) ≤ k , we can apply the induction hypothesis to conclude that C ′ contains an ASEC, thus completing the proof.

Lemma 8. Almost surely, if ρ is accepted by A then ρ ⊗ reaches a state in some ASEC C i of M⊗A .

To proof this result, we recall a well-known result in probabilistic model checking that with probability of one (wpo), every run ρ of the policy π eventually stays in one of the ECs of M A and visits every transition in that EC infinitely often. To state this formally, we define for any run ρ = s 0 a 0 s 1 · · · ,

the set of state-action-pairs occurring infinitely often in ρ . Furthermore, a state-action set χ ⊆ S × A defines a sub-MDP sub( χ ) := ( T, Act) , where

Lemma 21 ([12]) . P ρ ∼D M⊗A π [sub(InfSA( ρ )) is an end component ] = 1 .

For the sake of self-containedness, we recall the proof of [12].

Proof. We start with two more definitions: for any sub-MDP ( T, Act) [1], let

be the set of state-action pairs ( s, a ) such that a is enabled in s . Finally, let

be the set of runs such that action a is taken infinitely often in state s iff s ∈ T and a ∈ Act( s ) . Note that the Ω ( T, Act) constitute a partition of Runs( S, A ) .

Therefore, it suffices to establish for any sub-MDP ( T, Act) , ( T, Act) is an end-component or P [ ρ ∈ Ω ( T, Act) ] = 0 .

Let ( T, Act) be an arbitrary sub-MDP. First, suppose there exist s ∈ T and a ∈ Act( t ) such that p := ∑ s ′ ∈ T ∆( t, a, t ′ ) < 1 . By definition each ρ ∈ Ω ( T, Act) takes action a in state s infinitely often. Hence, not only P [ ρ ∈ Ω ( T, Act) ] ≤ p k for all k ∈ N but also P [ ρ ∈ Ω ( T, Act) ] = 0 .

Thus, we can assume that for all s ∈ T and a ∈ Act( t ) , ∑ s ′ ∈ T ∆( t, a, t ′ ) = 1 . If Ω ( T, Act) = ∅ then clearly P [ ρ ∈ Ω ( T, Act) ] = 0 follows. Otherwise, take any ρ = s 0 a 0 a 1 · · · ∈ Ω ( T, Act) , and let t, t ′ ∈ T be arbitrary. We show that there exists a connecting path in ( T, → Act ) , which implies that ( T, Act) is an end component.

Evidently, there exists an index i 0 such that all state-action pairs occur infinitely often in ρ , i.e.

Thus, for all i ≥ i 0 , s i ∈ T and a i ∈ Act( s i ) , and for all i ′ > i ≥ i 0 , there is a path from s i to s i ′ in ( T, → Act ) . Finally, it suffices to note that clearly for some i ′ > i = i 0 , s i = t and s i ′ = t ′ .

Proof of Lemma 8. By Lemma 21, almost surely sub(InfSA( ρ )) is an accepting end component. Clearly, ρ is only accepted by the product MDP if this end component is an accepting EC. By Lemma 20 this AEC contains an ASEC. Therefore, by definition of sub(InfSA( ρ )) , ρ almost surely in particular enters some ASEC. Finally, since the C 1 , . . . , C n cover all states in ASECs, ρ almost surely enters some C i .

q

0

start

q

1

⊥

q

2

(

s

0

, a, s

0

)

/

0

(

s

1

, b, s

0

)

/

0

(

s

0

, b, s

1

)

/

0

(

s

0

, a, s

0

)

/

1

(

s

1

, b, s

0

)

/

0

(

s

0

, b, s

1

)

/

1

∗

/

0

∗

/

0

Before turning to the proof of Lemma 10, let J R M avg ( ρ ) = lim inf t →∞ 1 t · ∑ t -1 i =0 r i denote the limitaverage reward of a run ρ . Note that, for any run ρ , J R M avg ( ρ ) ∈ { 0 , 1 } . Thus, by the dominated convergence theorem [28, Cor. 6.26],

Lemma 10. Let P be a probability transition function with support E and M := ( S, A, s 0 , P ) .

For every policy π , J R M avg ( π ) ≤ J A M ( π ) .

For every policy π , there exists some policy π ′ satisfying J A M ( π ) ≤ J R M avg ( π ′ ) .

Proof. 1. For any run ρ , J R M avg ( ρ ) = 1 only if ρ ⊗ enters a C i and never leaves it. ( ρ ⊗ might have entered other C j 's earlier but then those necessarily need to overlap with yet another C k such that i ≤ k < j to avoid being trapped in state ⊥ , resulting in J R M avg ( ρ ) = 1 . Furthermore, this C i can only overlap with C j if i < j . Otherwise, the reward machine would have enforced transitioning to C j .)

Since C i is an ASEC, ρ ⊗ is accepted by the product MDP M⊗A . Hence, by Eqs. (2) and (3),

Let π be arbitrary. For a run s 0 a 0 · · · let q t be the state of the DRA in step t . Define π ′ to follow π until reaching s t such that ( s t , q t ) ∈ T 1 ∪ · · · ∪ T n . Henceforth, we select the (unique) action guaranteeing to stay in the C i with minimal i including the current state, i.e. Act ( q,u ) ( q, u ) . Formally 9 ,

Note that whenever a run ρ ∼ D M π ′ follows the modified policy π ′ and its induced run ρ ⊗ reaches some ASEC C i then J R M avg ( ρ ) = 1 . Thus,

Furthermore, by Lemma 8 almost surely, every induced run ρ ⊗ accepted by the product MDP must reach some C i . Consequently, by Eq. (2),

In the penultimate step, we have exploited the fact that π and π ′ agree until reaching the first C i .

B.1 Efficient Construction

We consider a different collection C 1 , . . . , C n of ASECs:

Suppose C ′ 1 , . . . , C ′ n is a collection of AECs (not necessarily simple ones) containing all states in AECs. Then we consider ASECs C 1 , . . . , C n such that C i is contained in C ′ i .

The definition of the reward machine in Section 4.2 and the extension in Section 5 do not need to be changed. Next, we argue the following:

This collection can be obtained efficiently (in time polynomial in the size of the MDP and DRA).

Lemma 10 and hence the correctness result (Theorem 9) still hold.

For 1. it is well-known that a collection of maximal AECs (covering all states in AECs) can be found efficiently using graph algorithms [1, Alg. 3.1], [15, 11] and [4, Alg. 47 and Lemma 10.125]. Subsequently, Lemma 20 can be used to obtain an ASEC contained in each of them. In particular, note that the proof of Lemma 20 immediately gives rise to an efficient algorithm. (Briefly, we iteratively remove actions and states whilst querying reachability properties.)

For 2., the first part of Lemma 10 clearly still holds. For the second, we modify policy π as follows: Once, π enters a maximal accepting end component we select an action on the shortest path to the respective ASEC C i inside C ′ i . Once we enter one of the C i we follow the actions specified by the ASEC as before. Observe that the probability that under an AEC is entered is the same as the probability that one of the C i is entered under the modified policy. The lemma, hence Theorem 9, follow.

C Supplementary Materials for Section 5

Lemma 14. Suppose M = ( S, A, s 0 , P ) is an arbitrary MDP.

For every policy π , J R M avg ( π ) ≤ J A M ( π ) .

For every policy π , there exists some policy π ′ satisfying J A M ( π ) ≤ J R M avg ( π ′ ) .

Proof. 1. For a run ρ , let E ρ be the set of transitions encountered in the product MDP. Note that J R M avg ( ρ ) = 1 only if ρ ⊗ enters some C E ρ i and never leaves it. ( ρ ⊗ might have entered other C E j s earlier for E ⊆ E ρ .)

With probability 1, E ρ contains all the transitions present in C E ρ i in the actual MDP. (NB possible transitions outside of C E ρ i might be missing from E ρ .) In particular, with probability 1, C E ρ i is also an ASEC for the true unknown MDP and ρ ⊗ is accepted by the product MDP M⊗A . Consequently, using Eq. (3) again,

Let π be arbitrary. We modify π to π ′ as follows: until reaching an ASEC C = ( T, Act) w.r.t. the true, unknown 10 set of transitions E ∗ follow π . Henceforth, select action Act E ∗ ( s t ,q t ) ( s t , q t ) .

We claim that whenever ρ ∼ D M π ′ follows the modified policy π ′ and ρ ⊗ reaches some ASEC in the true product MDP, J R M avg ( ρ ) = 1 .

To see this, suppose ρ ∼ D M π ′ is such that for some minimal t 0 ∈ N , ( s t 0 , q t 0 ) ∈ T E ∗ 1 ∪ · · · ∪ T E ∗ n . Let C = ( T, Act) := C E ∗ ( s t 0 ,q t 0 ) .

Define E t to be the transitions encountered up to step t ∈ N , i.e. E t := { (( s k , q k ) , a k , ( s k +1 , q k +1 )) | 0 ≤ k < t } . Then almost surely for some minimal t ≥ t 0 ,

and there exists γ ∈ [0 , 1) such that

̸

E t contains all transitions in C , and no further transitions will be encountered, i.e. for all t ′ ≥ t , E t ′ = E t . Define E := E t . Note that for all (( s, q ) , a, ( s ′ , q ′ )) ∈ E such that ( s, q ) ∈ T , Act( s, q ) = { a } . (This is because upon entering the ASEC C we immediately switch to following the action dictated by Act . Thus, we avoid 'accidentally' discovering other ASECs w.r.t. the partial knowledge of the product MDP's graph, which might otherwise force us to perform actions leaving C .) Consequently, there cannot be another ASEC C ′ = ( T ′ , Act ′ ) w.r.t. E overlapping with C , i.e. T ∩ T ′ = ∅ . Therefore, for all ( s, q ) ∈ C , Act E ( s,q ) = Act . Consequently, J R M avg ( ρ ) = 1 .

Thus,

P ρ ∼D M π ′ [ ρ ⊗ reaches some ASEC in true product MDP ] ≤ E ρ ∼D M π ′ [ J R M avg ( ρ )] = J R M avg ( π ′ )

Consequently,

In the penultimate step we have exploited that π and π ′ agree until reaching some ASEC in true product MDP.

D Supplementary Materials for Section 6

Let Π be the set of all memoryless policies and Π ∗ be the set of all limit-average optimal policies. Besides, let w ∗ := J R M avg ( π ∗ ) the limit average reward of any optimal π ∗ ∈ Π ∗ .

Lemma 15 is proven completely analagously to the following (where K = N ):

Lemma 22. Suppose γ k ↗ 1 , ϵ k ↘ 0 and each π k is a memoryless policy satisfying J R M γ k ( π k ) ≥ J R M γ k ( π ) -ϵ k for all π ∈ Π . Then there exists k 0 such that for all k ≥ k 0 , π k is limit average optimal.

Proof. We define ∆ := min π ∈ Π \ Π ∗ J R M avg ( π ) -w ∗ > 0 . Recall (see e.g. [22, Sec. 8.1]) that for any policy π ∈ Π ,

Since Π is finite, due to Eq. (5) there exists γ 0 such that

for all π ∈ Π and γ ∈ [ γ 0 , 1) . Let π ∗ be a memoryless Blackwell optimal policy (which exists due to [6, 18]). Note that

for all γ ∈ [ γ, 1) and π ∈ Π . Moreover, there clearly exists k 0 such that ϵ k ≤ ∆ / 4 and γ k ≥ γ 0 , γ for all k ≥ k 0 .

Therefore, for any k ≥ k 0 ,

Consequently, by definition of ∆ , π k ∈ Π ∗ .

NeurIPS Paper Checklist

1. Claims

Question: Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope?

Answer: [Yes]

Justification: The main results mentioned in the abstract and introduction are Proposition 4 and Theorems 12, 16 and 18. They accurately reflect the paper's contributions and scope.

Guidelines:

The answer NA means that the abstract and introduction do not include the claims made in the paper.

The abstract and/or introduction should clearly state the claims made, including the contributions made in the paper and important assumptions and limitations. A No or NA answer to this question will not be perceived well by the reviewers.

The claims made should match theoretical and experimental results, and reflect how much the results can be expected to generalize to other settings.

It is fine to include aspirational goals as motivation as long as it is clear that these goals are not attained by the paper.

2. Limitations

Question: Does the paper discuss the limitations of the work performed by the authors?

Answer: [Yes]

Justification: Limitations are discussed in Section 7.

Guidelines:

The answer NA means that the paper has no limitation while the answer No means that the paper has limitations, but those are not discussed in the paper.

The authors are encouraged to create a separate "Limitations" section in their paper.

The paper should point out any strong assumptions and how robust the results are to violations of these assumptions (e.g., independence assumptions, noiseless settings, model well-specification, asymptotic approximations only holding locally). The authors should reflect on how these assumptions might be violated in practice and what the implications would be.

The authors should reflect on the scope of the claims made, e.g., if the approach was only tested on a few datasets or with a few runs. In general, empirical results often depend on implicit assumptions, which should be articulated.

The authors should reflect on the factors that influence the performance of the approach. For example, a facial recognition algorithm may perform poorly when image resolution is low or images are taken in low lighting. Or a speech-to-text system might not be used reliably to provide closed captions for online lectures because it fails to handle technical jargon.

The authors should discuss the computational efficiency of the proposed algorithms and how they scale with dataset size.

If applicable, the authors should discuss possible limitations of their approach to address problems of privacy and fairness.

While the authors might fear that complete honesty about limitations might be used by reviewers as grounds for rejection, a worse outcome might be that reviewers discover limitations that aren't acknowledged in the paper. The authors should use their best judgment and recognize that individual actions in favor of transparency play an important role in developing norms that preserve the integrity of the community. Reviewers will be specifically instructed to not penalize honesty concerning limitations.

3. Theory Assumptions and Proofs

Question: For each theoretical result, does the paper provide the full set of assumptions and a complete (and correct) proof?

Answer: [Yes]

Justification: Full proofs are presented in the appendices and results are cross-referenced. At the beginning of Section 4 we assume knowledge of the support of the MDP's probability transition function for presentational purposes. This assumption is fully removed in Section 5.

Guidelines:

The answer NA means that the paper does not include theoretical results.

All the theorems, formulas, and proofs in the paper should be numbered and crossreferenced.

All assumptions should be clearly stated or referenced in the statement of any theorems.

The proofs can either appear in the main paper or the supplemental material, but if they appear in the supplemental material, the authors are encouraged to provide a short proof sketch to provide intuition.

Inversely, any informal proof provided in the core of the paper should be complemented by formal proofs provided in appendix or supplemental material.

Theorems and Lemmas that the proof relies upon should be properly referenced.

4. Experimental Result Reproducibility

Question: Does the paper fully disclose all the information needed to reproduce the main experimental results of the paper to the extent that it affects the main claims and/or conclusions of the paper (regardless of whether the code and data are provided or not)?

Answer: [NA]

Justification: The paper does not include experiments.

Guidelines:

The answer NA means that the paper does not include experiments.

If the paper includes experiments, a No answer to this question will not be perceived well by the reviewers: Making the paper reproducible is important, regardless of whether the code and data are provided or not.

If the contribution is a dataset and/or model, the authors should describe the steps taken to make their results reproducible or verifiable.

Depending on the contribution, reproducibility can be accomplished in various ways. For example, if the contribution is a novel architecture, describing the architecture fully might suffice, or if the contribution is a specific model and empirical evaluation, it may be necessary to either make it possible for others to replicate the model with the same dataset, or provide access to the model. In general. releasing code and data is often one good way to accomplish this, but reproducibility can also be provided via detailed instructions for how to replicate the results, access to a hosted model (e.g., in the case of a large language model), releasing of a model checkpoint, or other means that are appropriate to the research performed.

While NeurIPS does not require releasing code, the conference does require all submissions to provide some reasonable avenue for reproducibility, which may depend on the nature of the contribution. For example

(a) If the contribution is primarily a new algorithm, the paper should make it clear how to reproduce that algorithm.

(b) If the contribution is primarily a new model architecture, the paper should describe the architecture clearly and fully.

(c) If the contribution is a new model (e.g., a large language model), then there should either be a way to access this model for reproducing the results or a way to reproduce the model (e.g., with an open-source dataset or instructions for how to construct the dataset).

(d) We recognize that reproducibility may be tricky in some cases, in which case authors are welcome to describe the particular way they provide for reproducibility. In the case of closed-source models, it may be that access to the model is limited in some way (e.g., to registered users), but it should be possible for other researchers to have some path to reproducing or verifying the results.

5. Open access to data and code

Question: Does the paper provide open access to the data and code, with sufficient instructions to faithfully reproduce the main experimental results, as described in supplemental material?

Answer: [NA]

Justification: The paper does not include experiments.

Guidelines:

The answer NA means that paper does not include experiments requiring code.

Please see the NeurIPS code and data submission guidelines ( https://nips.cc/ public/guides/CodeSubmissionPolicy ) for more details.

While we encourage the release of code and data, we understand that this might not be possible, so 'No' is an acceptable answer. Papers cannot be rejected simply for not including code, unless this is central to the contribution (e.g., for a new open-source benchmark).

The instructions should contain the exact command and environment needed to run to reproduce the results. See the NeurIPS code and data submission guidelines ( https: //nips.cc/public/guides/CodeSubmissionPolicy ) for more details.

The authors should provide instructions on data access and preparation, including how to access the raw data, preprocessed data, intermediate data, and generated data, etc.

The authors should provide scripts to reproduce all experimental results for the new proposed method and baselines. If only a subset of experiments are reproducible, they should state which ones are omitted from the script and why.

At submission time, to preserve anonymity, the authors should release anonymized versions (if applicable).

Providing as much information as possible in supplemental material (appended to the paper) is recommended, but including URLs to data and code is permitted.

6. Experimental Setting/Details

Question: Does the paper specify all the training and test details (e.g., data splits, hyperparameters, how they were chosen, type of optimizer, etc.) necessary to understand the results?

Answer: [NA]

Justification: The paper does not include experiments.

Guidelines:

The answer NA means that the paper does not include experiments.

The experimental setting should be presented in the core of the paper to a level of detail that is necessary to appreciate the results and make sense of them.

The full details can be provided either with the code, in appendix, or as supplemental material.

7. Experiment Statistical Significance

Question: Does the paper report error bars suitably and correctly defined or other appropriate information about the statistical significance of the experiments?

Answer: [NA]

Justification: The paper does not include experiments.

Guidelines:

The answer NA means that the paper does not include experiments.

The authors should answer "Yes" if the results are accompanied by error bars, confidence intervals, or statistical significance tests, at least for the experiments that support the main claims of the paper.

The factors of variability that the error bars are capturing should be clearly stated (for example, train/test split, initialization, random drawing of some parameter, or overall run with given experimental conditions).

The method for calculating the error bars should be explained (closed form formula, call to a library function, bootstrap, etc.)

The assumptions made should be given (e.g., Normally distributed errors).

It should be clear whether the error bar is the standard deviation or the standard error of the mean.

It is OK to report 1-sigma error bars, but one should state it. The authors should preferably report a 2-sigma error bar than state that they have a 96% CI, if the hypothesis of Normality of errors is not verified.

For asymmetric distributions, the authors should be careful not to show in tables or figures symmetric error bars that would yield results that are out of range (e.g. negative error rates).

If error bars are reported in tables or plots, The authors should explain in the text how they were calculated and reference the corresponding figures or tables in the text.

8. Experiments Compute Resources

Question: For each experiment, does the paper provide sufficient information on the computer resources (type of compute workers, memory, time of execution) needed to reproduce the experiments?

Answer: [NA]

Justification: The paper does not include experiments.

Guidelines:

The answer NA means that the paper does not include experiments.

The paper should indicate the type of compute workers CPU or GPU, internal cluster, or cloud provider, including relevant memory and storage.

The paper should provide the amount of compute required for each of the individual experimental runs as well as estimate the total compute.

The paper should disclose whether the full research project required more compute than the experiments reported in the paper (e.g., preliminary or failed experiments that didn't make it into the paper).

9. Code Of Ethics

Question: Does the research conducted in the paper conform, in every respect, with the NeurIPS Code of Ethics https://neurips.cc/public/EthicsGuidelines ?

Answer: [Yes]

Justification: The research conducted in the paper conform, in every respect, with the NeurIPS Code of Ethics https://neurips.cc/public/EthicsGuidelines .

Guidelines:

The answer NA means that the authors have not reviewed the NeurIPS Code of Ethics.

If the authors answer No, they should explain the special circumstances that require a deviation from the Code of Ethics.

The authors should make sure to preserve anonymity (e.g., if there is a special consideration due to laws or regulations in their jurisdiction).

10. Broader Impacts

Question: Does the paper discuss both potential positive societal impacts and negative societal impacts of the work performed?

Answer: [NA]

Justification: There is no societal impact of the work performed.

Guidelines:

The answer NA means that there is no societal impact of the work performed.

If the authors answer NA or No, they should explain why their work has no societal impact or why the paper does not address societal impact.

Examples of negative societal impacts include potential malicious or unintended uses (e.g., disinformation, generating fake profiles, surveillance), fairness considerations (e.g., deployment of technologies that could make decisions that unfairly impact specific groups), privacy considerations, and security considerations.

The conference expects that many papers will be foundational research and not tied to particular applications, let alone deployments. However, if there is a direct path to any negative applications, the authors should point it out. For example, it is legitimate to point out that an improvement in the quality of generative models could be used to generate deepfakes for disinformation. On the other hand, it is not needed to point out that a generic algorithm for optimizing neural networks could enable people to train models that generate Deepfakes faster.

The authors should consider possible harms that could arise when the technology is being used as intended and functioning correctly, harms that could arise when the technology is being used as intended but gives incorrect results, and harms following from (intentional or unintentional) misuse of the technology.

If there are negative societal impacts, the authors could also discuss possible mitigation strategies (e.g., gated release of models, providing defenses in addition to attacks, mechanisms for monitoring misuse, mechanisms to monitor how a system learns from feedback over time, improving the efficiency and accessibility of ML).

11. Safeguards

Question: Does the paper describe safeguards that have been put in place for responsible release of data or models that have a high risk for misuse (e.g., pretrained language models, image generators, or scraped datasets)?

Answer: [NA]

Justification: The paper poses no such risks.

Guidelines:

The answer NA means that the paper poses no such risks.

Released models that have a high risk for misuse or dual-use should be released with necessary safeguards to allow for controlled use of the model, for example by requiring that users adhere to usage guidelines or restrictions to access the model or implementing safety filters.

Datasets that have been scraped from the Internet could pose safety risks. The authors should describe how they avoided releasing unsafe images.

We recognize that providing effective safeguards is challenging, and many papers do not require this, but we encourage authors to take this into account and make a best faith effort.

12. Licenses for existing assets

Question: Are the creators or original owners of assets (e.g., code, data, models), used in the paper, properly credited and are the license and terms of use explicitly mentioned and properly respected?

Answer: [NA]

Justification: The paper does not use existing assets.

Guidelines:

The answer NA means that the paper does not use existing assets.

The authors should cite the original paper that produced the code package or dataset.

The authors should state which version of the asset is used and, if possible, include a URL.

The name of the license (e.g., CC-BY 4.0) should be included for each asset.

For scraped data from a particular source (e.g., website), the copyright and terms of service of that source should be provided.

If assets are released, the license, copyright information, and terms of use in the package should be provided. For popular datasets, paperswithcode.com/datasets has curated licenses for some datasets. Their licensing guide can help determine the license of a dataset.

For existing datasets that are re-packaged, both the original license and the license of the derived asset (if it has changed) should be provided.

If this information is not available online, the authors are encouraged to reach out to the asset's creators.

13. New Assets

Question: Are new assets introduced in the paper well documented and is the documentation provided alongside the assets?

Answer: [NA]

Justification: The paper does not release new assets.

Guidelines:

The answer NA means that the paper does not release new assets.

Researchers should communicate the details of the dataset/code/model as part of their submissions via structured templates. This includes details about training, license, limitations, etc.

The paper should discuss whether and how consent was obtained from people whose asset is used.

At submission time, remember to anonymize your assets (if applicable). You can either create an anonymized URL or include an anonymized zip file.

14. Crowdsourcing and Research with Human Subjects

Question: For crowdsourcing experiments and research with human subjects, does the paper include the full text of instructions given to participants and screenshots, if applicable, as well as details about compensation (if any)?

Answer: [NA]

Justification: The paper does not involve crowdsourcing nor research with human subjects.

Guidelines:

The answer NA means that the paper does not involve crowdsourcing nor research with human subjects.

Including this information in the supplemental material is fine, but if the main contribution of the paper involves human subjects, then as much detail as possible should be included in the main paper.

According to the NeurIPS Code of Ethics, workers involved in data collection, curation, or other labor should be paid at least the minimum wage in the country of the data collector.

15. Institutional Review Board (IRB) Approvals or Equivalent for Research with Human Subjects

Question: Does the paper describe potential risks incurred by study participants, whether such risks were disclosed to the subjects, and whether Institutional Review Board (IRB) approvals (or an equivalent approval/review based on the requirements of your country or institution) were obtained?

Answer: [NA]

Justification: The paper does not involve crowdsourcing nor research with human subjects.

Guidelines:

The answer NA means that the paper does not involve crowdsourcing nor research with human subjects.

Depending on the country in which research is conducted, IRB approval (or equivalent) may be required for any human subjects research. If you obtained IRB approval, you should clearly state this in the paper.

We recognize that the procedures for this may vary significantly between institutions and locations, and we expect authors to adhere to the NeurIPS Code of Ethics and the guidelines for their institution.

For initial submissions, do not include any information that would break anonymity (if applicable), such as the institution conducting the review.

Peer reviews:
{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThe authors present a theoretical framework for learning $\\omega$-regular properties in unknown MDPs through average reward optimization (via an \"optimality preserving\" approach). \nCompared to previous work, the approach allows for multi-chain MDP. \nThe idea is to formalize the property through a deterministic Rabin automaton, construct an auxiliary model (a product MDP) that encodes the state space and the transitions of this automaton into those of the original MDP, and incorporate the resulting model into a reward machine.\nRewards are then generated according to the current knowledge of the underlying graph of the product MDP. \nThe reward machine can be constructed on the fly, which enables its optimization through RL. \nFinally, the authors show that optimizing the discounted return objective boils down to (i) optimizing the average reward objective, which in turn implies (ii) the optimality preserving learning of the $\\omega$-regular property.\nFinally, convergence guarantees are proved through a sequential algorithm making calls to any PAC-MDP algorithm for discounted return, eventually decreasing the error and confidence terms to 0 as the algorithm progresses.\n\nSTRENGTHS:\nThe authors answer questions that were left open: (i) learning $\\omega$-regular properties through a limit average reward objective in an optimality-preserving way is not possible with Markovian rewards, (ii) this is in contrast made possible by using finite-spaces reward machines, and (iii) in RL, one can design such an algorithm that converges in the limit. \nOverall, the paper is well-written and the proof sketches in the main text effectively allow the reader to grasp the main ideas of the proofs presented in the appendix.\n\nWEAKNESSES:\nFirst, although the paper is quite well written, I think that for somebody unfamiliar with all the concepts presented, the paper might be difficult to follow. For instance, the authors build upon accepting end components to detect when the specification is satisfied. However, the authors do not mention or discuss the reason why it is possible to do that in practice. Specifically, I would expect the authors to mention that identifying ECs can be done through purely graph algorithms, which makes them affordable to consider in this context.\n\nSecond, I found that the authors do not really take into account practical considerations in the proposed approach. For instance, there is no mention of how to detect minimal ECs. I mention other issues that I believe should be clarified in the \"Questions\" section.\n\nFinally, there is no evaluation. I understand that this is intentional due to the theoretical nature of the paper. However, after reading the text, I am eager to know if the approach works in practice, as learning to satisfy LTL specifications is an ongoing challenge in RL. Furthermore, Algorithm 1 is an (unrealizable) theoretical algorithm but I would have loved to see a discussion or remark on how to implement such an algorithm in practice.\n\nQUESTIONS:\n-  Is listing all minimal ECs not equivalent to listing all the possible deterministic policies in a maximal end component? If that's the case, even though the memory of the reward machine need not be too large due to the coverage sufficiency, detecting them might be costly and in the worst case exponential. I believe this question should be addressed and at least discussed in the main text.\n- Section 5 is a bit ambiguous to me. In particular, I don't understand how Lemma 13 applies without fixing the set of visited transitions $E$. By looking at the Appendix, I understand that either the set $E$ is fixed, or it changes over time steps, i.e., the set is defined as $E_t$ for $t \\geq 0$. If this is the case, then the reward machine $\\mathcal{R}$ should take this time step into account in its definition, and I expect to see this in the main text. Could you please clarify?\n- Could you please clarify what happens if the current algorithm believes to act in an EC (according to $E$) that is actually _not_ an EC? For instance, what happens if a region of the system is detected at the current time step as being an EC that has a *very* small probability of being left?\n- Do you have any insights on how to design a *practical* algorithm that preserves the theoretical guarantees in the limit?\n\n### Remarks and suggestions\n- In Section 6, I was confused because I did not understand why considering a discounted return objective is relevant for the average return. I had to check in the appendix to see the reference, mentioning that when the discount $\\gamma$ goes to one, $(1 - \\gamma) \\mathcal{J}\\_{\\mathcal{R}^{\\gamma}}$ coincides with $\\mathcal{J}\\_{\\mathcal{R}^{\\text{avg}}}$. This should be explicitly stated in the main text!\n- line 131: everyone => every?\n- for the reference that LTL is not PAC-learnable, I would also cite [1]\n- line 177: it seems that you used $R_i$ for denoting the sets of states visited finitely often and then suddenly switched to $B_i$.\n\n[1] Hugo Bazille, Blaise Genest, Cyrille Jégourel, Jun Sun: Global PAC Bounds for Learning Discrete Time Markov Chains. CAV (2) 2020: 304-326\n\nLIMITATIONS:\nLimitations have been addressed and further discussed in the conclusion.", "TITLE": "Official Review", "RECOMMENDATION": 6, "REVIEWER_CONFIDENCE": 4, "SOUNDNESS_CORRECTNESS": 4, "DATE": "2024-07-11"}

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThe paper studies the link between reinforcement learning with $\\omega$-regular objectives to reinforcement learning with limit-average reward. It is shown that one cannot reduce RL with $omega$-regular objectives to RL with limit-average objectives by only replacing the reward function (Proposition 4), but that it is possible if one considers rewards given by finite-memory reward machines (Theorem 11), which is the main result of the paper. It is also shown that RL with limit-average rewards can be learned in the limit, thus implying that RL with omega-regular objectives can also be learned in the limit (Theorem 17).\n\nSTRENGTHS:\nThe paper is original in the sense that it provides theoretical tools for a new approach for RL with $\\omega$-regular objectives by reducing it to the well-known case of limit-average rewards. This allows to apply the many approaches designed originally for the case of limit-average rewards to $\\omega$-regular objectives. The idea of approaching RL with $\\omega$-regular objectives by analyzing the end components of the product MDP with a DRA or LDBA representing the objective might not be new, but the way it is precisely used with accepting simple components and reward machines is new and original to the best of my knowledge. I would judge the paper of high quality as it is well presented, the proofs are sound as far as I could check, and the context of the results is very well explained. The paper is easy to read and its more technical concepts are explained in a simple manner (Section 4 is a good addition in that sense). The results of the paper solves open problems given in [1], and contribute to building a theoretical framework for transforming specifications in RL, which is right now underdeveloped with many open questions, and was a work begun in [1]. Moreover, even though no practical applications of the results are presented, it is not unreasonable to expect that the main result might be directly applied in the case of finite MDPs with the support of the actions known. Therefore, the results are of high significance to the community.\n\n[1]: Rajeev Alur, Suguman Bansal, Osbert Bastani, and Kishor Jothimurugan. A framework for transforming specifications in reinforcement learning. In Jean-François Raskin, Krishnendu Chatterjee, Laurent Doyen, and Rupak Majumdar, editors, Principles of Systems Design: Essays Dedicated to Thomas A. Henzinger on the Occasion of His 60th Birthday, pages 604–624, Cham, 2022. Springer Nature Switzerland.\n\nWEAKNESSES:\nI do not think that the paper has any obvious weaknesses, but it could be improved by either providing a polynomial construction for the reduction from $\\omega$-regular objectives to limit-average ones in the case where the probabilities of the MDP are unknown or providing a negative result.\n\nQUESTIONS:\nI do not have any questions\n\nLIMITATIONS:\nThe authors addressed the limitations of their work in the Limitations section at the end.", "TITLE": "Official Review", "RECOMMENDATION": 7, "REVIEWER_CONFIDENCE": 4, "SOUNDNESS_CORRECTNESS": 4, "DATE": "2024-07-12"}

comments: SUMMARY:
This paper tackle several open problems in the field of specification driven learning using Reinforcement Learning (RL) algorithms. It proves that $\omega$-regular objectives can be translated in an optimality preserving manner to limit-average reward MDPs. A PAC-MDP convergence proof for limit-average reward MDPs is introduced as well.

STRENGTHS:
The paper reads well and presents a clear and logical progression towards the main results.

WEAKNESSES:
The claim of the first proof of convergence for average reward MDPs may need to be further evaluated [1].

QUESTIONS:
1. How does the choice between Limit Deterministic Büchi Automatas (LDBAs) and DRAs to express $\omega$-regular languages affect the results [2]?
2. Although [1] does not consider the PAC-MDP setting, how relevant is their proof of convergence w.r.t. the results in the paper?
3. Minor typos
    1.  L131 everyone → every
    2. L156 $\delta_d$ ->  $\delta_u$ ?
    3. L289 “sequence of discount sum”

References:

[1] Learning and Planning in Average-Reward Markov Decision Processes, Wan et al, ICML 2021

[2] From LTL to your favourite deterministic automaton, Kretínsky et al, 
In CAV (1), volume 10981 of Lecture Notes in Computer
Science, pages 567–577. Springer, 2018.

LIMITATIONS:
The cost of running these transformations is not discussed (empirically or otherwise).
TITLE: Official Review
SOUNDNESS_CORRECTNESS: 4
DATE: 2024-07-13

comments: SUMMARY:
This paper considers the problem of reducing temporal logic objectives to limit-average reward problems which enable using reinforcement learning to compute policies. The key contributions are an explicit construction and analysis for the setting where the MDPs transition support is known, followed by a relaxation which drops this assumption. The key theorems then provide a characterization of the optimality preserving nature of the reduction.

STRENGTHS:
The constructions and theorems are to my knowledge novel and sound. Further, the target problem of LTL policy synthesis in the model free setting is important and relevant to the Neurips audience.

Particularly interesting is the adaptive relaxation of the transition support knowledge. Further lemma 13's robustness implications further speak to the potential.

WEAKNESSES:
My primaries concerns for this paper are the (lack of) relation to prior work and the lack of empirical validation, even on a toy problem.

In particular, this works goal and conclusions seem very similar to [1] which also shows a non-markovian reduction policy learning which seems to also be optimal policy preserving with high probability and seems to apply to a larger problem space.

[1] Eventual Discounting Temporal Logic Counterfactual Experience Replay, 2023

If this relationship can be clarified, I could raise my rating.

My other nitpick is with the novelty of section 3. My understanding is that this result is known, for example [2].

[2] On the Expressivity of Markov Reward, 2022

QUESTIONS:
See weaknesses.

LIMITATIONS:
Limitations section in paper is satisfactory.
TITLE: Official Review
SOUNDNESS_CORRECTNESS: 3
DATE: 2024-07-13