CausalSmith · seminar slides
Evaluating Policies with Hidden States
Weighting recent action histories lets us evaluate a policy’s long-run reward; how much history we need depends on how far the policy can shift hidden-state occupancy.
slides for Latent Stationary Overlap and Minimax Off-policy Evaluation in Finite POMDPs
Motivation
- We observe one trajectory of length T under a known behavior policy b.
- Each date records observed state Xt, binary action At, and reward Yt.
- A known target policy e chooses actions differently.
- We want its long-run average reward, including how earlier actions change today’s hidden state.
Changing today’s treatment can change tomorrow’s condition. How can we evaluate that accumulated effect from a partially observed record?
Research Question
Current-action importance weighting replaces today’s behavior action probabilities with target probabilities.
It still averages rewards over states generated by earlier behavior actions.
- With the full Markov state observed, stationary distribution corrections can support parametric estimation: Mehrabi and Wager (2025).
- With hidden state, Hu and Wager (2023) weight recent action histories. Longer histories reduce bias but increase variance.
Does bounded target-to-behavior stationary occupancy restore parametric accuracy when the state is hidden?
Key Idea
Let db and de be the behavior and target stationary distributions of the full state s, including its hidden component.
Restrict how much the target can increase occupancy:
de(s)≤Cdb(s),s∈S.
Here S is the full state space and C≥1 is the occupancy bound. Its distance from equality is:
qC:=CC−1.
The radius qC bounds the state imbalance inherited from behavior actions.
Our answer: with finite states, binary actions, stationary data, known observed-state randomization, bounded rewards and action ratios, and geometric forgetting, calibrated history weighting attains matching minimax bounds.
Fixed C>1 still allows slower than parametric estimation. Parametric accuracy emerges when the radius is sufficiently small.
Example
The observed state is constant. Hidden state contains depth Jt∈{0,…,Q}, with Q≥1, and sign Ut∈{−1,+1}.
Depth transitions: below Q, advance to Jt+1 with probability α, and reset to zero with probability 1−α. At Q, reset with probability one. Here 0<α<1.
- An advance preserves sign under action one; action zero redraws sign fairly.
- A reset draws a fresh sign with mean εC=min{(C−1)/2,1/2}.
b(At=1)=L1,b(At=0)=1−L1,e(At=1)=1,e(At=0)=0.
Here L>1 controls action overlap. The target always preserves sign; behavior can erase it.
Rewards depend on sign only at terminal depth Q. Earlier actions therefore affect today’s reward even though the observed state never changes.
Model
The full Markov state is St=(Xt,Ht), with hidden component Ht. A time-invariant kernel K generates reward and next state from current full state and action.
- Known policies b,e depend only on Xt.
- Sequential ignorability: given Xt, behavior randomization additionally depends on neither hidden state nor past history.
- Stationary start: S0∼db.
- Rewards satisfy ∣Yt∣≤1; both state spaces are finite and actions are binary.
Our stationary target value is:
θ(K,e):=s=(x,h)∈S∑de(s)ge(s)=s=(x,h)∈S∑de(s)a∈A∑e(a∣x)EK[Yt∣St=s,At=a].
Here A={0,1}. The function ge(s) averages current reward over target actions at state s. The outer average uses the full-state distribution produced by running the target in the long run.
Assumptions
Action overlap controls observable importance weights:
e(a∣x)≤Lb(a∣x).
Here L=exp(ζ), with ζ>0. Every target action has behavior support; larger L permits larger weights.
Geometric mixing makes both policies forget their starting states:
∥νPp−ν′Pp∥TV≤α∥ν−ν′∥TV.
For p=b,e, Pp is the full-state transition under policy p. Total variation measures the difference between distributions ν,ν′.
Here α=exp(−1/t0), with t0>0; larger t0 means slower forgetting.
Together with stationary overlap de(s)≤Cdb(s) and the model conditions, these define MT(t0,ζ,C).
In the example, every state shares a reset component of probability 1−α. That component forgets both depth and sign, giving contraction by at most α.
Main Result
Let RT(t0,ζ,C) be the smallest worst-case mean squared error attainable from observed data and known policies over MT(t0,ζ,C).
β=2+t0ζ2,rT(t0,ζ,C)=T−1+T−βqC2(1−β).
The exponent β combines mixing and action overlap. The risk surface rT adds ordinary sampling error to the cost of repairing hidden-state imbalance.
informal · Theorem T-5 For fixed t0,ζ>0, all C≥1, and sufficiently large T, observable minimax risk over MT(t0,ζ,C) is comparable to rT; radius-calibrated histories attain its upper bound.
clorT(t0,ζ,C)≤RT(t0,ζ,C)≤chirT(t0,ζ,C),
The positive constants and sample-size threshold depend only on t0,ζ, uniformly over C and all finite state counts.
The estimator uses supplied values of t0,ζ,C. Every observable estimator faces the lower bound.
Risk Regimes
Three readings of the same surface:
- Fixed C>1: mean squared error is comparable to T−β, retaining the Hu–Wager hidden-state exponent.
- Equality, C=1: de=db, and current-action weighting attains the T−1 scale.
- Shrinking radius: the transition occurs at qC≍T−1/2. If TqC2 remains bounded, current-action weighting attains parametric accuracy.
In the example, fixed C>1 permits a fixed positive reset-sign bias. Increasing terminal depth then sustains the slower hidden-state rate while respecting stationary overlap.
Partial Histories
Define the observed action ratio ρt=e(At∣Xt)/b(At∣Xt) on behavior-supported actions.
Choose depth k: k past actions plus the current action.
Zt(k):=Ytj=t−k∏tρj,
The score Zt(k) reweights reward Yt by target-to-behavior action ratios throughout the window.
θk:=clip[−1,1]{T−k1t=k∑T−1Zt(k)}.
The estimator averages the complete windows, then clips to the reward range [−1,1].
In the example, only all-one action windows receive positive weight. Weighting them reproduces the target’s sign-preserving action sequence.
Remaining Bias
Sequential ignorability makes the weight product replace behavior actions with target actions throughout the window.
Its population mean is ∑sdb(s)(Pekge)(s): start under db, run k target transitions, then average reward under the target action rule.
- Stationary overlap means db contains at least a 1/C share of de. Their total variation distance is therefore at most qC.
- Each target transition contracts this mismatch by α.
- Remaining reward bias is controlled on the scale qCαk.
At depth zero, the state distribution remains db.
In the example, longer weighted histories preserve more sign memory. Resets make sign information predating the window progressively less consequential.
Bias–variance Bound
Action ratios have conditional mean one and are bounded by L. Multiplying them makes the variance grow on the scale Lk/T.
Overlapping windows do not add another factor of k: nonshared ratios average out, leaving geometric covariance bounds. For separated windows, behavior mixing controls the dependence.
For M∈MT(t0,ζ,C) and k≤T/2:
EM[{θk−θ(K,e)}2]≤4qC2α2k+T2{Lk+1(1+L−14)+1−α4},
The expectation averages over the behavior trajectory.
- Squared bias decreases with history length.
- Action-weighting variance increases with history length.
A smaller occupancy radius means less bias needs repair.
History Depth
Balance squared bias qC2α2k against variance Lk/T:
κTrad(C):=⎩⎨⎧0,min{⌊2T⌋,⌊2log(1/α)+logLlog(TqC2)⌋},TqC2≤1,TqC2>1.
The chosen depth κTrad(C) uses trajectory length and supplied mixing, action-overlap, and stationary-overlap bounds.
- When TqC2≤1, use depth zero: occupancy bias is already small enough.
- Otherwise, history grows logarithmically with TqC2.
The denominator combines two mixing exponents from squared bias with one action-overlap exponent from variance. This balance produces β and the upper risk bound.
Could another observable estimator avoid this tradeoff?
Stationary Occupancy
Return to the depth-and-sign example. Actions change sign memory, while depth transitions are identical under both policies.
Only an advance from j−1 reaches depth j>0, so stationary masses satisfy wj=αwj−1. The forced reset at Q closes the chain; normalizing this finite geometric sequence gives:
wj21+uεCL−j,wj=1−αQ+1(1−α)αj,j∈{0,…,Q}, u∈{−1,+1}.
The first expression is behavior’s stationary probability of depth j and sign u.
Both policies have depth mass wj. Behavior’s sign mean is εCL−j; the target preserves εC.
Their full-state laws satisfy:
de(s)≤(1+εC)db(s),1+εC≤C.
Increasing terminal depth preserves the occupancy restriction.
Reward Alternatives
The alternatives v=+1 and v=−1 share dynamics and policies. They reverse only the reward response.
Conditional on the current hidden state, the probability of reward y∈{−1,+1} is:
21+yvc0Ut1{Jt=Q}
Here c0=(1−α)/4 is the reward amplitude. The indicator turns on the sign response only at depth Q; all other rewards are fair coins.
Under the target, terminal sign has mean εC. Thus:
θ(K,e)=vc0(t0)εCwQ.
The notation c0(t0) emphasizes that the amplitude depends on the mixing scale.
The target-value gap is twice amplitude times reset-sign bias times terminal occupancy. Its square is comparable to εC2α2Q.
Observed Sign Memory
Let Ft−1obs be the past action-and-reward record, and o one realized record.
Define qtv(o)=Prv(Jt=Q∣Ft−1obs=o), the conditional terminal probability.
With ℓt=min{Q,t}, surviving sign memory is recorded by:
at(Q):=L−(Q−ℓt)j=t−ℓt∏t−11{Aj=1},
After Q dates, this is the indicator that the previous Q actions were all one. Earlier, the power of L accounts for pre-sample actions.
A run ending at Q has encountered only fair rewards since its reset. Those rewards cannot select its current sign.
The exact observed reward mean is:
Ev[Yt∣Ft−1obs=o]=vc0εCat(Q)(o)qtv(o),
The signal requires both surviving sign memory and a chance of terminal depth.
Reward Updating
Why can favorable reward histories not concentrate the conditional probability at Q?
- Ending at Q requires Q consecutive advances. They contribute αQ, and their preceding rewards are fair.
- An informative reward occurs at Q and is followed by a forced reset. Its information cannot carry forward along that same advance run.
- Conditioning still divides by the likelihood of observed rewards across all hidden paths.
At date i, a reward’s likelihood relative to a fair coin is at least 1−c0qiv.
Consequently, for t≥Q, the conditional terminal probability obeys qtv≤αQ∏i=t−Qt−1(1−c0qiv)−1, evaluated along the observed history.
Only the latest Q reward updates enter. Before Q dates, the stationary geometric depth tail supplies the missing advance probabilities.
Uniform Filtering
The reward-update bound can be used twice.
- Start with qiv≤1. Even the most favorable reward sequence gives qtv≤(α/(1−c0))Q.
- Write η0=α/(1−c0). Our amplitude choice c0=(1−α)/4 ensures η0<1.
- Insert the first bound back into the update: each likelihood denominator is now at least 1−c0η0Q.
The cumulative inflation is at most (1−c0η0Q)−Q. The exponentially small correction η0Q outweighs the Q possible updates, so this inflation is bounded uniformly over depth.
Therefore, for every observed history:
qtv(o)≤K0αQ.
Here K0 depends only on t0.
Terminal probability stays on its rarity scale even for reward sequences that favor terminal depth.
Information Limit
Hidden terminal probability enters the observed reward mean before information squares it.
Reward probabilities stay between (1−c0)/2 and (1+c0)/2. Thus information is quadratic in the conditional mean difference, giving the squared terminal factor α2Q.
The surviving-memory factor supplies another restriction: under behavior, an all-one history of length Q occurs with probability L−Q. Its indicator remains unchanged when squared. Initial incomplete windows have no larger second moment.
Let PQ,+1obs,T and PQ,−1obs,T be the two observed-trajectory laws. Their Kullback–Leibler divergence measures distinguishability:
KL(PQ,+1obs,TPQ,−1obs,T)≤1−c024c02K02TεC2α2QL−Q.
Across T dates, reset bias and hidden terminal probability are squared; the frequency of informative action histories enters once.
Matching Lower Bound
When TqC2>1, choose terminal depth Q so that TεC2α2QL−Q stays bounded.
The two alternatives remain statistically hard to distinguish, while their squared target-value separation is comparable to εC2α2Q.
The reset bias tracks the occupancy radius:
2qC≤εC≤qC
- Increasing depth reduces squared target separation through α2Q.
- Observable information falls faster, through α2QL−Q.
Balancing these effects leaves squared separation on the scale T−βqC2(1−β), with the same β as the estimator’s balance. Hard-to-distinguish values force that order of worst-case error.
Ordinary reward uncertainty also forces a T−1 floor, including when the radius is small. Together these give the matching risk surface.
Open Questions
- Choosing history depth when the stationary-overlap radius is unknown.
- Confidence intervals for stationary target values.
- Policy-learning regret built on value estimation.
- Risk with a fixed hidden-state size: our matching alternatives increase terminal depth, and therefore state count, with T.
Takeaways
- History weighting changes the transitions that generated today’s state. Mixing limits how much unreweighted history still matters.
- Action overlap determines the variance cost of longer histories; stationary overlap determines how much initial imbalance needs repair.
- Fixed C>1 retains the hidden-state rate. At qC≲T−1/2, parametric accuracy is possible. The matching construction keeps terminal depth rare even after conditioning on rewards.
Appendix: Uniform Overlap Frontier
The complete all-radius statement gives matching minimax bounds and an observable estimator attaining them.
Fix t0>0 and ζ>0. Let RT(t0,ζ,C) be the minimax squared-error risk in Definition P-3, let qC=(C−1)/C be the overlap-distance radius in Definition P-10, and set β=2+t0ζ2,rT(t0,ζ,C)=T−1+T−βqC2(1−β). There exist constants clo,chi>0, with clo≤chi, and an integer T⋆≥1, all depending only on t0 and ζ, such that for every C≥1 and every T≥T⋆, clorT(t0,ζ,C)≤RT(t0,ζ,C)≤chirT(t0,ζ,C), and the radius-adaptive partial-history importance-weighted estimator with depth κTrad(C) from Definition P-11 satisfies m∈MT(t0,ζ,C)supEm[(θκTrad(C)−θm)2]≤chirT(t0,ζ,C). Moreover, for every sequence CT≥1, if TqCT2 is eventually bounded, then there is a constant cimm>0, depending on the sequence and on t0,ζ, such that eventually m∈MT(t0,ζ,CT)supEm[(θ0−θm)2]≤Tcimm.
Appendix: Fixed-overlap Minimax Rate
At every fixed nonunit radius, partial histories attain the hidden-state exponent and finite depth-and-sign alternatives force it.
Fix t0,ζ,C∈R. Assume:
- (Positive memory exponent.) t0>0.
- (Positive overlap exponent.) ζ>0.
- (Fixed latent-overlap radius.) C>1.
Let the exponent β be β=2+t0ζ2. There exist constants c⋆,c⋆∈R and an integer T⋆≥1 such that 0<c⋆≤c⋆ and, for every integer T≥T⋆, c⋆T−β≤RT(t0,ζ,C)≤c⋆T−β, where RT(t0,ζ,C) is the minimax squared-error risk in Definition P-3. Moreover, the clipped partial-history importance-weighted estimator θkT, with kT as in Definition P-5, satisfies M∈MT(t0,ζ,C)supEM[{θkT−θ(M)}2]≤c⋆T−β, with θ(M) the stationary target-policy mean reward in Definition P-2. For each integer T≥T⋆, there is an integer Q≥1 such that the lower bound is witnessed by the two signed-depth alternatives MQ,vT, v∈{−1,+1}, generated by Definition P-6 with one observed state and 2(Q+1) latent states: for every measurable observable-data estimator θ, under the usual squared-error integrability conditions for both alternatives, c⋆T−β≤v∈{−1,+1}maxEMQ,vT[{θ−θ(MQ,vT)}2].
Appendix: Shrinking-overlap Frontier
Along radii approaching unit overlap, the same surface describes the transition to immediate weighting and parametric risk.
The following conditions hold:
- (Fixed smoothness.) The constants satisfy t0>0 and ζ>0.
- (Shrinking radius.) The deterministic radius excess sequence (δT)T≥1 satisfies δT≥0 for every T.
- (Local limit.) The sequence satisfies δT→0.
- (Rate exponent.) Let β=2/(2+t0ζ).
- (Local rate and depth.) Define rT(δ)=T−1+T−βδT2(1−β) and κT=⎩⎨⎧0,min{⌊T/2⌋,⌊2log(1/α)+logLlog(TδT2)⌋},TδT2≤1,TδT2>1.
Then there exist constants cloc,Cloc with 0<cloc≤Cloc, depending only on t0 and ζ, such that, for all sufficiently large T, clocrT(δ)≤RT(t0,ζ,1+δT)≤ClocrT(δ), where RT is the minimax squared-error risk in Definition P-3. Moreover, the observable partial-history importance-weighted estimator θκT of Definition P-4 satisfies M∈MT(t0,ζ,1+δT)supEM[(θκT−θ(M))2]≤ClocrT(δ) for all sufficiently large T. Finally, if there is a constant D≥0 such that TδT2≤D for all sufficiently large T, then there is a constant cimm>0 such that M∈MT(t0,ζ,1+δT)supEM[(θ0−θ(M))2]≤Tcimm for all sufficiently large T.