{"title": "PAC Reinforcement Learning with Rich Observations", "book": "Advances in Neural Information Processing Systems", "page_first": 1840, "page_last": 1848, "abstract": "We propose and study a new model for reinforcement learning with rich observations, generalizing contextual bandits to sequential decision making.  These models require an agent to take actions based on observations (features) with the goal of achieving long-term performance competitive with a large set of policies.  To avoid barriers to sample-efficient learning associated with large observation spaces and general POMDPs, we focus on problems that can be summarized by a small number of hidden states and have long-term rewards that are predictable by a reactive function class.  In this setting, we design and analyze a new reinforcement learning algorithm, Least Squares Value Elimination by Exploration. We prove that the algorithm learns near optimal behavior after a number of episodes that is polynomial in all relevant parameters, logarithmic in the number of policies, and independent of the size of the observation space. Our result provides theoretical justification for reinforcement learning with function approximation.", "full_text": "PAC Reinforcement Learning with Rich Observations\n\nAkshay Krishnamurthy\n\nUniversity of Massachusetts, Amherst\n\nAmherst, MA, 01003\n\nakshay@cs.umass.edu\n\nAlekh Agarwal\n\nMicrosoft Research\nNew York, NY 10011\n\nalekha@microsoft.com\n\nJohn Langford\n\nMicrosoft Research\nNew York, NY 10011\njcl@microsoft.com\n\nAbstract\n\nWe propose and study a new model for reinforcement learning with rich obser-\nvations, generalizing contextual bandits to sequential decision making. These\nmodels require an agent to take actions based on observations (features) with the\ngoal of achieving long-term performance competitive with a large set of policies.\nTo avoid barriers to sample-ef\ufb01cient learning associated with large observation\nspaces and general POMDPs, we focus on problems that can be summarized by a\nsmall number of hidden states and have long-term rewards that are predictable by a\nreactive function class. In this setting, we design and analyze a new reinforcement\nlearning algorithm, Least Squares Value Elimination by Exploration. We prove\nthat the algorithm learns near optimal behavior after a number of episodes that is\npolynomial in all relevant parameters, logarithmic in the number of policies, and\nindependent of the size of the observation space. Our result provides theoretical\njusti\ufb01cation for reinforcement learning with function approximation.\n\n1\n\nIntroduction\n\nThe Atari Reinforcement Learning research program [21] has highlighted a critical de\ufb01ciency of\npractical reinforcement learning algorithms in settings with rich observation spaces: they cannot ef-\nfectively solve problems that require sophisticated exploration. How can we construct Reinforcement\nLearning (RL) algorithms which effectively plan and plan to explore?\nIn RL theory, this is a solved problem for Markov Decision Processes (MDPs) [6, 13, 26]. Why do\nthese results not apply?\nAn easy response is, \u201cbecause the hard games are not MDPs.\u201d This may be true for some of the hard\ngames, but it is misleading\u2014popular algorithms like Q-learning with \u270f-greedy exploration do not\neven engage in minimal planning and global exploration1 as is required to solve MDPs ef\ufb01ciently.\nMDP-optimized global exploration has also been avoided because of a polynomial dependence on\nthe number of unique observations which is intractably large with observations from a visual sensor.\nIn contrast, supervised and contextual bandit learning algorithms have no dependence on the number\nof observations and at most a logarithmic dependence on the size of the underlying policy set.\nApproaches to RL with a weak dependence on these quantities exist [15] but suffer from an exponential\ndependence on the time horizon\u2014with K actions and a horizon of H, they require \u2326(KH) samples.\nExamples show that this dependence is necessary, although they typically require a large number of\nstates. Can we \ufb01nd an RL algorithm with no dependence on the number of unique observations and a\npolynomial dependence on the number of actions K, the number of necessary states M, the horizon\nH, and the policy complexity log(|\u21e7|)?\n\n1We use \u201cglobal exploration\u201d to distinguish the sophisticated exploration strategies required to solve an MDP\n\nef\ufb01ciently from exponentially less ef\ufb01cient alternatives such as \u270f-greedy.\n\n30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain.\n\n\fTo begin answering this question we consider a simpli\ufb01ed setting with episodes of bounded length H\nand deterministic state transitions. We further assume that we have a function class that contains the\noptimal observation-action value function Q?. These simpli\ufb01cations make the problem signi\ufb01cantly\nmore tractable without trivializing the core goal of designing a Poly(K, M, H, log(|\u21e7|))) algorithm.\nTo this end, our contributions are:\n1. A new class of models for studying reinforcement learning with rich observations. These\nmodels generalize both contextual bandits and small-state MDPs, but do not exhibit the partial\nobservability issues of more complex models like POMDPs. We show exponential lower bounds\non sample complexity in the absence of the assumptions to justify our model.\n\n2. A new reinforcement learning algorithm Least Squares Value Elimination by Exploration\n(LSVEE) and a PAC guarantee that it \ufb01nds a policy that is at most \u270f sub-optimal (with the\n\nabove assumptions) using O\u21e3 M K2H 6\n\n\u270f3\n\nlog(|\u21e7|)\u2318 samples, with no dependence on the number of\n\nunique observations. This is done by combining ideas from contextual bandits with a novel state\nequality test and a global exploration technique. Like initial contextual bandit approaches [1],\nthe algorithm is computationally inef\ufb01cient since it requires enumeration of the policy class, an\naspect we hope to address in future work.\n\nLSVEE uses a function class to approximate future rewards, and thus lends theoretical backing for\nreinforcement learning with function approximation, which is the empirical state-of-the-art.\n\n2 The Model\n\nOur model is a Contextual Decision Process, a term we use broadly to refer to any sequential\ndecision making task where an agent must make decision on the basis of rich features (context) to\noptimize long-term reward. In this section, we introduce the model, starting with basic notation. Let\nH 2 N denote an episode length, X\u2713 Rd an observation space, A a \ufb01nite set of actions, and S a\n\ufb01nite set of latent states. Let K , |A|. We partition S into H disjoint groups S1, . . . ,SH, each of\nsize at most M. For a set P , (P ) denotes the set of distributions over P .\n\n2.1 Basic De\ufb01nitions\nOur model is de\ufb01ned by the tuple (1, , D) where 1 2 (S1) denotes a starting state distribution,\n: ( S\u21e5A ) ! (S) denotes the transition dynamics, and Ds 2 (X\u21e5 [0, 1]K) associates a\ndistribution over observation-reward pairs with each state s 2S . We also use Ds to denote the\nmarginal distribution over observations (usage will be clear from context) and use Ds|x for the\nconditional distribution over reward given the observation x in state s. The marginal and conditional\nprobabilities are referred to as Ds(x) and Ds|x(r).\nWe assume that the process is layered (also known as loop-free or acyclic) so that for any sh 2S h\nand action a 2A , (sh, a) 2 (Sh+1). Thus, the environment transitions from state space S1 up to\nSH via a sequence of actions. Layered structure allows us to avoid indexing policies and Q-functions\nwith time, which enables concise notation.\nEach episode produces a full record of interaction (s1, x1, a1, r1, . . . , sH, xH, aH, rH) where s1 \u21e0\n1, sh \u21e0 (sh1, ah1), (xh, rh) \u21e0 Dsh and all actions ah are chosen by the learning agent. The\nrecord of interaction observed by the learner is (x1, a1, r1(a1), . . . , xH, aH, rH(aH)) and at time\npoint h, the learner may use all observable information up to and including xh to select ah. Notice\nthat all state information and rewards for alternative actions are unobserved by the learning agent.\nh=1 rh(ah), and the goal is to maximize the expected\nh=1 rh(ah)], where the expectation accounts for all the randomness\nh=1 rh(ah) 2 [0, 1] for any action\n\nThe learner\u2019s reward for an episode isPH\ncumulative reward, R = E[PH\nin the model and the learner. We assume that almost surelyPH\n\nsequence.\nIn this model, the optimal expected reward achievable can be computed recursively as\n\nV ? , Es\u21e01[V ?(s)] with V ?(s) , Ex\u21e0Ds max\n\na Er\u21e0Ds|x\u21e5r(a) + Es0\u21e0(s,a)V ?(s0)\u21e4 .\n\n(1)\n\n2\n\n\fAs the base case, we assume that for states s 2S H, all actions transition to a terminal state sH+1\nwith V ?(sH+1) , 0. For each (s, x) pair such that Ds(x) > 0 we also de\ufb01ne a Q? function as\n\nQ?\n\ns(x, a) , Er\u21e0Ds|x\u21e5r(a) + Es0\u21e0(s,a)V ?(s0)\u21e4 .\n\n(2)\nThis function captures the optimal choice of action given this (state, observation) pair and therefore\nencodes optimal behavior in the model.\nWith no further assumptions, the above model is a layered episodic Partially Observable Markov\nDecision Process (LE-POMDP). Both learning and planning are notoriously challenging in POMDPs,\nbecause the optimal policy depends on the entire trajectory and the complexity of learning such a\npolicy grows exponentially with H (see e.g. Kearns et al. [15] as well as Propositions 1 and 2 below).\nOur model avoids this statistical barrier with two assumptions: (a) we consider only reactive policies,\nand (b) we assume access to a class of functions that can realize the Q? function. Both assumptions\nare implicit in the empirical state of the art RL results. They also eliminate issues related to partial\nobservability, allowing us to focus on our core goal of systematic exploration. We describe both\nassumptions in detail before formally de\ufb01ning the model.\nReactive Policies: One approach taken by some prior theoretical work is to consider reactive (or\nmemoryless) policies that use only the current observation to select an action [4, 20]. Memorylessness\nis slightly generalized in the recent empirical advances in RL, which typically employ policies that\ndepend only on the few most recent observations [21].\nA reactive policy \u21e1 : X!A is a strategy for navigating the search space by taking actions \u21e1(x)\ngiven observation x. The expected reward for a policy is de\ufb01ned recursively through\nand V (s, \u21e1) , E(x,r)\u21e0Ds\u21e5r(\u21e1(x)) + Es0\u21e0(s,\u21e1(x))V (s0,\u21e1 )\u21e4 .\n\nV (\u21e1) , Es\u21e01[V (s, \u21e1)]\n\nA natural learning goal is to identify a policy with maximal value V (\u21e1) from a given collection of\nreactive policies \u21e7. Unfortunately, even when restricting to reactive policies, learning in POMDPs\nrequires exponentially many samples, as we show in the next lower bound.\n\nProposition 1. Fix H, K 2 N with K  2 and \u270f 2 (0,p1/8). For any algorithm, there exists a\nLE-POMDP with horizon H, K actions, and 2H total states; a class \u21e7 of reactive policies with\n|\u21e7| = KH; and a constant c > 0 such that the probability that the algorithm outputs a policy \u02c6\u21e1 with\nV (\u02c6\u21e1) > max\u21e12\u21e7 V (\u21e1)  \u270f after collecting T trajectories is at most 2/3 for all T \uf8ff cKH/\u270f2.\nThis lower bound precludes a Poly(K, M, H, log(|\u21e7|)) sample complexity bound for learning reac-\ntive policies in general POMDPs as log(|\u21e7|) = H log(K) in the construction, but the number of\nsamples required is exponential in H. The lower bound instance provides essentially no instantaneous\nfeedback and therefore forces the agent to reason over KH paths independently.\nPredictability of Q?: The assumption underlying the empirical successes in RL is that the Q?\nfunction can be well-approximated by some large set of functions F. To formalize this assump-\ntion, note that for some POMDPs, we may be able to write Q? as a function of the observed\nhistory (x1, a1, r1(a1), . . . , xh) at time h. For example, this is always true in deterministic-transition\nPOMDPs, since the sequence of previous actions encodes the state and Q? as in Eq. (2) depends only\non the state, the current observation, and the proposed action. In the realizable setting, we have access\nto a collection of functions F mapping the observed history to [0, 1], and we assume that Q? 2F .\nUnfortunately, even with realizability, learning in POMDPs can require exponentially many samples.\nProposition 2. Fix H, K 2 N with K  2 and \u270f 2 (0,p1/8). For any algorithm, there exists\na LE-POMDP with time horizon H, K actions, and 2H total states; a class of predictors F with\n|F| = KH and Q? 2F ; and a constant c  0 such that the probability that the algorithm outputs a\npolicy \u02c6\u21e1 with V (\u02c6\u21e1) > V ?  \u270f after collecting T trajectories is at most 2/3 for all T \uf8ff cKH/\u270f2.\nAs with Proposition 1, this lower bound precludes a Poly(K, M, H, log(|\u21e7|)) sample complexity\nbound for learning POMDPs with realizability. The lower bound shows that even with realizability,\nthe agent may have to reason over KH paths independently since the functions can depend on the\nentire history. Proofs of both lower bounds here are deferred to Appendix A.\nBoth lower bounds use POMDPs with deterministic transitions and an extremely small observation\nspace. Consequently, even learning in deterministic-transition POMDPs requires further assumptions.\n\n3\n\n\f2.2 Main Assumptions\n\ns(x, a) = Q?\n\nAs we have seen, neither restricting to reactive policies, nor imposing realizability enable tractable\nlearning in POMDPs on their own. Combined however, we will see that sample-ef\ufb01cient learning is\npossible, and the combination of these two assumptions is precisely how we characterize our model.\nSpeci\ufb01cally, we study POMDPs for which Q? can be realized by a predictor that uses only the current\nobservation and proposed action.\nAssumption 1 (Reactive Value Functions). We assume that for all x 2X , a 2A and any two state\ns, s0 such that Ds(x), Ds0(x) > 0, we have Q?\nThe restriction on Q? implies that the optimal policy is reactive and also that the optimal predictor of\nlong-term reward depends only on the current observation. In the following section, we describe how\nthis condition relates to other RL models in the literature. We \ufb01rst present a natural example.\nExample 1 (Disjoint observations). The simplest example is one where each state s can be identi\ufb01ed\nwith a subset Xs with Ds(x) > 0 only for x 2X s and where Xs \\X s0 = ; when s 6= s0. A realized\nobservation then uniquely identi\ufb01es the underlying state s so that Assumption 1 trivially holds, but\nthis mapping from s to Xs is unknown to the agent. Thus, the problem cannot be easily reduced\nto a small-state MDP. This setting is quite natural in several robotics and navigation tasks, where\nthe visual signals are rich enough to uniquely identify the agent\u2019s position (and hence state). It also\napplies to video game playing, where the raw pixel intensities suf\ufb01ce to decode the game\u2019s memory\nstate, but learning this mapping is challenging.\n\ns0(x, a).\n\nThinking of x as the state, the above example is an MDP with in\ufb01nite state space but with structured\ntransition operator. While our model is more general, we are primarily motivated by these in\ufb01nite-\nstate MDPs, for which the reactivity assumptions are completely non-restrictive. For in\ufb01nite-state\nMDPs, our model describes a particular structure on the transition operator that we show enables\nef\ufb01cient learning. We emphasize that our focus is not on partial observability issues.\nAs we are interested in understanding function approximation, we make a realizability assumption.\nAssumption 2 (Realizability). We are given access to a class of predictors F\u2713 (X\u21e5A! [0, 1])\nof size |F| = N and assume that Q? = f ? 2F . We identify each predictor f with a policy\n\u21e1f (x) , argmaxa f (x, a). Observe that the optimal policy is \u21e1f ? which satis\ufb01es V (\u21e1f ?) = V ?.\nAssumptions 1 and 2 exclude the lower bounds from Propositions 1 and 2. Our algorithm requires\none further assumption.\nAssumption 3 (Deterministic Transitions). We assume that the transition model is deterministic.\nThis means that the starting distribution 1 is a point-mass on some state s1 and : ( S\u21e5A ) !S .\nEven with deterministic transitions, learning requires systematic global exploration that is unaddressed\nin previous work. Recall that the lower bound constructions for Propositions 1 and 2 actually use\ndeterministic transition POMDPs. Therefore, deterministic transitions combined with either the\nreactive or the realizability assumption by itself still precludes tractable learning. Nevertheless, we\nhope to relax this \ufb01nal assumption in future work.\nMore broadly, this model provides a framework to reason about reinforcement learning with function\napproximation. This is highly desirable as such approaches are the empirical state-of-the-art, but the\nlimited supporting theory provides little advice on systematic global exploration.\n\n2.3 Connections to Other Models and Techniques\n\nThe above model is closely related to several well-studied models in the literature, namely:\nContextual Bandits: If H = 1, then our model reduces to stochastic contextual bandits [8, 16], a\nwell-studied simpli\ufb01cation of the general reinforcement learning problem. The main difference is\nthat the choice of action does not in\ufb02uence the future observations (there is only one state), and\nalgorithms do not need to perform long-term planning to obtain low sample complexity.\nMarkov Decision Processes: If X = S and Ds(x) for each state s is concentrated on s, then our\nmodel reduces to small-state MDPs, which can be ef\ufb01ciently solved by tabular approaches [6, 13, 26].\nThe key differences in our setting are that the observation space X is extremely large or in\ufb01nite\n\n4\n\n\fand the underlying state is unobserved, so tabular methods are not viable and algorithms need to\ngeneralize across observations.\nWhen the number of states is large, existing methods typically require exponentially many samples\nsuch as the O(KH) result of Kearns et al. [15]. Others depend poorly on the complexity of the policy\nset or scale linearly in the size of a covering over the state space [10, 12, 23]. Lastly, policy gradient\nmethods avoid dependence on size of the state space, but do not achieve global optimality [11, 27] in\ntheory and in practice, unlike our algorithm which is guaranteed to \ufb01nd the globally optimal policy.\nPOMDPs: By de\ufb01nition our model is a POMDP where the Q? function is consistent across states.\nThis restriction implies that the agent does not have to reason over belief states as is required in\nPOMDPs. There are some sample complexity guarantees for learning in arbitrarily complex POMDPs,\nbut the bounds we are aware of are quite weak as they scale linearly with |\u21e7| [14, 19], or require\ndiscrete observations from a small set [4].\nState Abstraction: State abstraction (see [18] for a survey) focuses on understanding what optimality\nproperties are preserved in an MDP after the state space is compressed. While our model does have a\nsmall number of underlying states, they do not necessarily admit non-trivial state abstractions that are\neasy to discover (i.e. that do not amount to learning the optimal behavior) as the optimal behavior\ncan depend on the observation in an arbitrary manner. Furthermore, most sample complexity results\ncannot search over large abstraction sets (see e.g. Jiang et al. [9]), limiting their scope.\nFunction Approximation: Our approach uses function approximation to address the generalization\nproblem implicit in our model. Function approximation is the empirical state-of-the-art in reinforce-\nment learning [21], but theoretical analysis has been quite limited. Several authors have studied linear\nor more general function approximation (See [5, 24, 28]), but none of these results give \ufb01nite sample\nbounds, as they do not address the exploration question. Li and Littman [17] do give \ufb01nite sample\nbounds, but they assume access to a \u201cKnows-what-it-knows\" (KWIK) oracle, which cannot exist\neven for simple problems. Other theoretical results either make stronger realizability assumptions\n(c.f., [2]) or scale poorly with problem parameters (e.g., polynomial in the number of functions [22]\nor the size of the observation space [23]).\n\n3 The Result\n\nWe consider the task of Probably Approximately Correct (PAC) learning the models de\ufb01ned in\nSection 2. Given F (Assumption 2), we say that an algorithm PAC learns our model if for any\n\u270f,  2 (0, 1), the algorithm outputs a policy \u02c6\u21e1 satisfying V (\u02c6\u21e1)  V ?  \u270f with probability at least\n1  . The sample complexity is a function n : (0, 1)2 ! N such that for any \u270f,  2 (0, 1), the\nalgorithm returns an \u270f-suboptimal policy with probability at least 1  using at most n(\u270f, ) episodes.\nWe refer to a Poly(M, K, H, 1/\u270f, log N, log(1/)) sample complexity bound as polynomial in all\nrelevant parameters. Notably, there should be no dependence on |X|, which may be in\ufb01nite.\n3.1 The Algorithm\n\nBefore turning to the algorithm, it is worth clarifying some additional notation. Since we are focused\non the deterministic transition setting, it is natural to think about the environment as an exponentially\nlarge search tree with fan-out K and depth H. Each node in the search tree is labeled with an\n(unobserved) state s 2S , and each edge is labeled with an action a 2A , consistent with the\ntransition model. A path p 2A ? is a sequence of actions from the root of the search tree, and we also\nuse p to denote the state reached after executing the path p from the root. Thus, Dp is the observation\ndistribution of the state at the end of the path p. We use p  a to denote a path formed by executing\nall actions in p and then executing action a, and we use |p| to denote the length of the path. Let ?\ndenote the empty path, which corresponds to the root of the search tree.\nThe pseudocode for the algorithm, which we call Least Squares Value Elimination by Exploration\n(LSVEE), is displayed in Algorithm 1 (See also Appendix B). LSVEE has two main components: a\ndepth-\ufb01rst-search routine with a learning step (step 6 in Algorithm 2) and an on-demand exploration\ntechnique (steps 5-8 in Algorithm 1). The high-level idea of the algorithm is to eliminate regression\nfunctions that do not meet Bellman-like consistency properties of the Q? function. We now describe\nboth components and their properties in detail.\n\n5\n\n\fAlgorithm 1 Least Squares Value Elimination by Exploration: LSVEE (F,\u270f, )\n1: F DFS-LEARN(?,F,\u270f,/ 2).\n2: Choose any f 2F . Let \u02c6V ? be a Monte Carlo estimate of V f (?,\u21e1 f ). (See Eq. (3))\n3: Set \u270fdemand = \u270f/2, n1 = 32 log(12M H/ )\n4: while true do\n5:\n6:\n7:\n8:\n\nFix a regressor f 2F .\nCollect n1 trajectories according to \u21e1f and estimate V (\u21e1f ) via Monte-Carlo estimate \u02c6V (\u21e1f ).\nIf | \u02c6V (\u21e1f )  \u02c6V ?|\uf8ff \u270fdemand, return \u21e1f .\nOtherwise update F by calling DFS-LEARN (p,F,\u270f,\n\n) on each of the H  1 pre\ufb01xes\n\nand n2 = 8 log(6M H/ )\n\n6M H 2n2\n\np of each of the \ufb01rst n2 paths collected in step 6.\n\n\u270f2\n\n.\n\n\n\n\u270f\n\n9: end while\n\n\u270f\n\n320H 2pK and \u270ftest = 20(H | p| 5/4)pK.\nM KH ) do\n\nAlgorithm 2 DFS-LEARN (p,F,\u270f, )\n1: Set  =\n2: for a 2A , if not CONSENSUS(p  a,F,\u270f test,,\n3:\n4: end for\n5: Collect ntrain = 24\n\nF DFS-LEARN(p  a,F,\u270f, ).\n\n/2\n\nuniformly at random, and ri = r0i(ai).\n\n2 log 8M HN\n6: Returnnf 2F : \u02dcR(f ) \uf8ff minf02F\n\n observations (xi, ai, ri) where (xi, r0i) \u21e0 Dp, ai is chosen\no, \u02dcR(f ) de\ufb01ned in Eq. (4).\n\n\u02dcR(f0) + 22 + 22 log(4M HN/ )\n\nntrain\n\n\n\nThe DFS routine: When the DFS routine, displayed in Algorithm 2, is run at some path p, we \ufb01rst\ndecide whether to recursively expand the descendants p  a by performing a consensus test. Given a\npath p0, this test, displayed in Algorithm 3, computes estimates of value predictions,\n\nV f (p0,\u21e1 f ) , Ex\u21e0Dp0 f (x, \u21e1f (x)),\n\n(3)\n\nfor all the surviving regressors. These value predictions are easily estimated by collecting many\nobservations after rolling in to p0 and using empirical averages (See line 2 in Algorithm 3). If all the\nfunctions agree on this value for p0 the DFS need not visit this path.\nAfter the recursive calls, the DFS routine performs the elimination step (line 6). When this step is\ninvoked at path p, the algorithm collects ntrain observations (xi, ai, ri) where (xi, r0i) \u21e0 Dp, ai is\nchosen uniformly at random, and ri = r0i(ai) and eliminates regressors that have high empirical risk,\n\n\u02dcR(f ) , 1\nntrain\n\nntrainXi=1\n\n(f (xi, ai)  ri  \u02c6V f (p  ai,\u21e1 f ))2.\n\n(4)\n\nIntuition for DFS: This regression problem is motivated by the realizability assumption and the\nde\ufb01nition of Q? in Eq. (2), which imply that at path p and for all actions a,\n\nf ?(x, a) = Er\u21e0Dp|xr(a) + V (p  a, \u21e1f ?) = Er\u21e0Dp|xr(a) + Ex0\u21e0Dpaf ?(x0,\u21e1 f ?(x0)).\n\n(5)\n\nThus f ? is consistent between its estimate at the current state s and the future state s0 = (s, a).\nThe regression problem (4) is essentially a \ufb01nite sample version of this identity. However, some\ncare must be taken as the target for the regression function f includes V f (p  a, \u21e1f ), which is f\u2019s\nvalue prediction for the future. The fact that the target differs across functions can cause instability in\nthe regression problem, as some targets may have substantially lower variance than f ?\u2019s. To ensure\ncorrect behavior, we must obtain high-quality future value prediction estimates, and so, we re-use\nthe Monte-Carlo estimates \u02c6V f (p  a, \u21e1f ) in Eq. (3) from the consensus tests. Each time we perform\nelimination, the regression targets are close for all considered f in Equation (4) owing to consensus\nbeing satis\ufb01ed at the successor nodes in Step 2 of Algorithm 2.\nGiven consensus at all the descendants, each elimination step inductively propagates learning towards\nthe start state by ensuring the following desirable properties hold: (i) f ? is not eliminated, (ii)\n\n6\n\n\f2 log(2N/). Collect ntest observations xi \u21e0 Dp.\n\nAlgorithm 3 CONSENSUS(p,F,\u270f test,, )\n1: Set ntest = 2\nntestPntest\n2: Compute for each function, \u02c6V f (p, \u21e1f ) = 1\n3: Return 1h| \u02c6V f (p, \u21e1f )  \u02c6V g(p, \u21e1g)|\uf8ff \u270ftest 8f, g 2Fi.\n\ni=1 f (xi,\u21e1 f (xi)).\n\nconsensus is reached at p, and (iii) surviving policies choose good actions at p. Property (ii) controls\nthe sample complexity, since consensus tests at state s return true once elimination has been invoked\non s, so DFS avoids exploring the entire search space. Property (iii) leads to the PAC-bound; if we\nhave run the elimination step on all states visited by a policy, that policy must be near-optimal.\nTo bound the sample complexity of the DFS routine, since there are M states per level and the\nconsensus test returns true once elimination has been performed, we know that the DFS does not visit\na large fraction of the search tree. Speci\ufb01cally, this means DFS is invoked on at most M H nodes\nin total, so we run elimination at most M H times, and we perform at most M KH consensus tests.\nEach of these operations requires polynomially many samples.\nThe elimination step is inspired by the RegressorElimination algorithm of Agarwal et. al [1] for\ncontextual bandit learning in the realizable setting. In addition to forming a different regression\nproblem, RegressorElimination carefully chooses actions to balance exploration and exploitation\nwhich leads to an optimal regret bound. In contrast, we are pursuing a PAC-guarantee here, for which\nit suf\ufb01ces to focus exclusively on exploration.\nOn-demand Exploration: While DFS is guaranteed to estimate the optimal value V ?, it unfor-\ntunately does not identify the optimal policy. For example, if consensus is satis\ufb01ed at a state s\nwithout invoking the elimination step, then each function accurately predicts the value V ?(s), but\nthe associated policies are not guaranteed to achieve this value. To overcome this issue, we use an\non-demand exploration technique in the second phase of the algorithm (Algorithm 1, steps 5-8).\nAt each iteration of this phase, we select a policy \u21e1f and estimate its value via Monte Carlo sampling.\nIf the policy has sub-optimal value, we invoke the DFS procedure on many of the paths visited. If the\npolicy has near-optimal value, we have found a good policy, so we are done. This procedure requires\nan accurate estimate of the optimal value, which we already obtained by invoking the DFS routine at\nthe root, since it guarantees that all surviving regressors agree with f ?\u2019s value on the starting state\ndistribution. f ?\u2019s value is precisely the optimal value.\nIntuition for On-demand Exploration: Running the elimination step at some path p ensures that\nall surviving regressors take good actions at p, in the sense that taking one action according to any\nsurviving policy and then behaving optimally thereafter achieves near-optimal reward for path p.\nThis does not ensure that all surviving policies achieve near-optimal reward, because they may take\nhighly sub-optimal actions after the \ufb01rst one. On the other hand, if a surviving policy \u21e1f visits only\nstates for which the elimination step has been invoked, then it must have near-optimal reward. More\nprecisely, letting L denote the set of states for which the elimination step has been invoked (the\n\u201clearned\" states), we prove that any surviving \u21e1f satis\ufb01es\n\nV ?  V (\u21e1f ) \uf8ff \u270f/8 + P [\u21e1f visits a states /2 L]\n\nThus, if \u21e1f is highly sub-optimal, it must visit some unlearned states with substantial probability. By\ncalling DFS-LEARN on the paths visited by \u21e1f , we ensure that the elimination step is run on at least\none unlearned states. Since there are only M H distinct states and each non-terminal iteration ensures\ntraining on an unlearned state, the algorithm must terminate and output a near-optimal policy.\nComputationally, the running time of the algorithm may be O(N ), since eliminating regression\nfunctions according to Eq. (4) may require enumerating over the class and the consensus function\nrequires computing the maximum and minimum of N numbers, one for each function. This may\nbe intractably slow for rich function classes, but our focus is on statistical ef\ufb01ciency, so we ignore\ncomputational issues here.\n\n3.2 The PAC Guarantee\nOur main result certi\ufb01es that LSVEE PAC-learns our models with polynomial sample complexity.\n\n7\n\n\fTheorem 1 (PAC bound). For any (\u270f, ) 2 (0, 1) and under Assumptions 1, 2, and 3, with probability\nat least 1  , the policy \u21e1 returned by LSVEE is at most \u270f-suboptimal. Moreover, the number of\nepisodes required is at most\n\n\u02dcO\u2713 M H 6K2\n\n\u270f3\n\nlog(N/) log(1/)\u25c6 .\n\nThis result uses the \u02dcO notation to suppress logarithmic dependence in all parameters except for N\nand . The precise dependence on all parameters can be recovered by examination of our proof and is\nshortened here simply for clarity. See Appendix C for the full proof of the result.\nThis theorem states that LSVEE produces a policy that is at most \u270f-suboptimal using a number of\nepisodes that is polynomial in all relevant parameters. To our knowledge, this is the \ufb01rst polynomial\nsample complexity bound for reinforcement learning with in\ufb01nite observation spaces, without\nprohibitively strong assumptions (e.g., [2, 22, 23]). We also believe this is the \ufb01rst \ufb01nite-sample\nguarantee for reinforcement learning with general function approximation without prohibitively\nstrong assumptions (e.g., [2]).\nSince our model generalizes both contextual bandits and MDPs, it is worth comparing the sample\ncomplexity bounds.\n1.\n\n\u270f3 log(N/) log(1/)), in contrast with known \u02dcO( K\n\nIn contextual bandits, we have M = H = 1 so that the sample complexity of LSVEE is\n\u02dcO( K2\ntic transitions is \u02dcO( M Kpoly(H)\n\n2. Prior results establish the sample complexity for learning layered episodic MDPs with determinis-\n\n\u270f2 log(N/)) results.\n\nlog(1/)) [7, 25].\n\n\u270f2\n\nBoth comparisons show our sample complexity bound may be suboptimal in its dependence on K\nand \u270f. Looking into our proof, the additional factor of K comes from collecting observations to\nestimate the value of future states, while the additional 1/\u270f factor arises from trying to identify a\npreviously unexplored state. In contextual bandits, these issues do not arise since there is only one\nstate, while, in tabular MDPs, they can be trivially resolved as the states are observed. Thus, with\nminor modi\ufb01cations, LSVEE can avoid these dependencies for both special cases. In addition, our\nbound disagrees with the MDP results in the dependence on the policy complexity log(N ); which we\nbelieve is unavoidable when working with rich observation spaces.\nFinally, our bound depends on the number of states M in the worst case, but the algorithm actually\nuses a more re\ufb01ned notion. Since the states are unobserved, the algorithm considers two states distinct\nonly if they have reasonably different value functions, meaning learning on one does not lead to\nconsensus on the other. Thus, a more distribution-dependent analysis de\ufb01ning states through the\nfunction class is a promising avenue for future work.\n\n4 Discussion\n\nThis paper introduces a new model in which it is possible to design and analyze principled rein-\nforcement learning algorithms engaging in global exploration. As a \ufb01rst step, we develop a new\nalgorithm and show that it learns near-optimal behavior under a deterministic-transition assumption\nwith polynomial sample complexity. This represents a signi\ufb01cant advance in our understanding of\nreinforcement learning with rich observations. However, there are major open questions:\n1. Do polynomial sample bounds for this model with stochastic transitions exist?\n2. Can we design an algorithm for learning this model that is both computationally and statistically\nef\ufb01cient? The sample complexity of our algorithm is logarithmic in the size of the function class\nF but uses an intractably slow enumeration of these functions.\n\nGood answers to both of these questions may yield new practical reinforcement learning algorithms.\n\nAcknowledgements\n\nWe thank Akshay Balsubramani and Hal Daum\u00e9 III for formative discussions, and we thank Tzu-Kuo\nHuang and Nan Jiang for carefully reading an early draft of this paper. This work was carried out\nwhile AK was at Microsoft Research.\n\n8\n\n\fReferences\n[1] A. Agarwal, M. Dud\u00edk, S. Kale, J. Langford, and R. E. Schapire. Contextual bandit learning with predictable\n\nrewards. In AISTATS, 2012.\n\n[2] A. Antos, C. Szepesv\u00e1ri, and R. Munos. Learning near-optimal policies with Bellman-residual minimization\n\nbased \ufb01tted policy iteration and a single sample path. MLJ, 2008.\n\n[3] P. Auer, N. Cesa-Bianchi, Y. Freund, and R. E. Schapire. The nonstochastic multiarmed bandit problem.\n\nSICOMP, 2002.\n\nmethods. In COLT, 2016.\n\n[4] K. Azizzadenesheli, A. Lazaric, and A. Anandkumar. Reinforcement learning of POMDPs using spectral\n\n[5] L. Baird. Residual algorithms: Reinforcement learning with function approximation. In ICML, 1995.\n[6] R. I. Brafman and M. Tennenholtz. R-max \u2013 a general polynomial time algorithm for near-optimal\n\nreinforcement learning. JMLR, 2003.\n\n[7] C. Dann and E. Brunskill. Sample complexity of episodic \ufb01xed-horizon reinforcement learning. In NIPS,\n\n[8] M. Dudik, D. Hsu, S. Kale, N. Karampatziakis, J. Langford, L. Reyzin, and T. Zhang. Ef\ufb01cient optimal\n\nlearning for contextual bandits. In UAI, 2011.\n\n[9] N. Jiang, A. Kulesza, and S. Singh. Abstraction selection in model-based reinforcement learning. In ICML,\n\n2015.\n\n2015.\n\n[10] N. K. Jong and P. Stone. Model-based exploration in continuous state spaces. In Abstraction, Reformulation,\n\nand Approximation, 2007.\n\n[11] S. Kakade and J. Langford. Approximately optimal approximate reinforcement learning. In ICML, 2002.\n[12] S. Kakade, M. J. Kearns, and J. Langford. Exploration in metric state spaces. In ICML, 2003.\n[13] M. Kearns and S. Singh. Near-optimal reinforcement learning in polynomial time. MLJ, 2002.\n[14] M. J. Kearns, Y. Mansour, and A. Y. Ng. Approximate planning in large POMDPs via reusable trajectories.\n\n[15] M. J. Kearns, Y. Mansour, and A. Y. Ng. A sparse sampling algorithm for near-optimal planning in large\n\nmarkov decision processes. MLJ, 2002.\n\n[16] J. Langford and T. Zhang. The epoch-greedy algorithm for multi-armed bandits with side information. In\n\n[17] L. Li and M. L. Littman. Reducing reinforcement learning to KWIK online regression. Ann. Math AI,\n\n[18] L. Li, T. J. Walsh, and M. L. Littman. Towards a uni\ufb01ed theory of state abstraction for MDPs. In ISAIM,\n\n[19] Y. Mansour. Reinforcement learning and mistake bounded algorithms. In COLT, 1999.\n[20] N. Meuleau, L. Peshkin, K.-E. Kim, and L. P. Kaelbling. Learning \ufb01nite-state controllers for partially\n\nobservable environments. In UAI, 1999.\n\n[21] V. Mnih, K. Kavukcuoglu, D. Silver, A. A. Rusu, J. Veness, M. G. Bellemare, A. Graves, M. Riedmiller,\nA. K. Fidjeland, G. Ostrovski, S. Petersen, B. Charles, S. Amir, I. Antonoglou, H. King, D. Kumaran,\nD. Wierstra, S. Legg, and D. Hassabis. Human-level control through deep reinforcement learning. Nature,\n2015.\n\n[22] P. Nguyen, O.-A. Maillard, D. Ryabko, and R. Ortner. Competing with an in\ufb01nite set of models in\n\nreinforcement learning. In AISTATS, 2013.\n\n[23] J. Pazis and R. Parr. Ef\ufb01cient PAC-optimal exploration in concurrent, continuous state MDPs with delayed\n\nupdates. In AAAI, 2016.\n\n[24] T. J. Perkins and D. Precup. A convergent form of approximate policy iteration. In NIPS, 2002.\n[25] S. Reveliotis and T. Bountourelis. Ef\ufb01cient PAC learning for episodic tasks with acyclic state spaces.\n\n[26] A. L. Strehl, L. Li, E. Wiewiora, J. Langford, and M. L. Littman. PAC model-free reinforcement learning.\n\n[27] R. S. Sutton, D. A. McAllester, S. P. Singh, and Y. Mansour. Policy gradient methods for reinforcement\n\nlearning with function approximation. In NIPS, 1999.\n\n[28] J. N. Tsitsiklis and B. Van Roy. An analysis of temporal-difference learning with function approximation.\n\nDEDS, 2007.\n\nIn ICML, 2006.\n\nIEEE TAC, 1997.\n\nIn NIPS, 1999.\n\nNIPS, 2008.\n\n2010.\n\n2006.\n\n9\n\n\f", "award": [], "sourceid": 1005, "authors": [{"given_name": "Akshay", "family_name": "Krishnamurthy", "institution": "UMass Amherst"}, {"given_name": "Alekh", "family_name": "Agarwal", "institution": "Microsoft"}, {"given_name": "John", "family_name": "Langford", "institution": "Microsoft Research New York"}]}