monte-carlo tree search
Last edited: October 10, 2025- \(\mathcal{P}\) problem (states, transitions, etc.)
- \(N\) visit counts
- \(Q\) a q-table: action-value estimates
- \(d\) depth (how many next states to look into)—more is more accurate but slower
- \(U\) value function estimate; usually a Rollout Policy, estimate at some depth \(d\)
- \(c\) exploration constant
After \(n\) simulation s from the starting state; we find the best action for our current state from our q-table.
Subroutine: simulate(state, depth_remaining)
- If
depth_remaining=0, simply return the utility from the value function estimate - For some
s, Actionsthat we just got, if we haven’t seen it, we just return the value function estimate + initialize the N and Q tables - select an action via the monte-carlo exploration formula
- sample a next state and current reward based on the action you gotten via a generative model
value = reward + discount*simulate(next_state, depth_remaining-1)- add to the
N(state, action)count - update the q table at (state, action):
Q[s,a] + = (value-Q[s,a])/N[s,a](“how much better is taking this action?” — with later times taking this action more heavily discounted)
monte-carlo exploration
\begin{equation} \max_{a} Q(s,a) + c \sqrt{ \frac{\log \sum_{a}N(s,a)}{N(s,a)}} \end{equation}
SU-CS161 OCT212025
Last edited: October 10, 2025Key Sequence
Notation
New Concepts
Important Results / Claims
Questions
Interesting Factoids
SU-CS229 OCT222025
Last edited: October 10, 2025Key Sequence
Notation
New Concepts
Important Results / Claims
Questions
Interesting Factoids
SU-CS254 MAR052025
Last edited: October 10, 2025Review! Probability
Let \(A_1 …, A_{M}\) be independent events, each with probability \(p\). Let \(T = \sum_{i=1}^{n} A_{i}\), meaning \(T \sim \text{Bin}\qty(n,p)\). \(\mu = \mathbb{E}\qty[T] = np\).
Two facts:
Markov bound
\(P\qty [X \geq k \mathbb{E}[x]] \leq \frac{1}{k}\)
;
Chebyshev’s inequality
\begin{equation} P\qty [T \not \in\mu \pm k \sigma] \leq \frac{1}{k^{2}} \end{equation}
Pairwise Independence
Gouldwasser-Sipsr
Given circuit \(C : \qty {0,1}^{n} \to \qty {0,1}\) and some parameter \(s\), there is an AM (one-round interaction) protocol: if \(\#c > 2s\), we will accept with probability \(\geq \frac{2}{3}\); if \(#c \leq s\), we will reject with probability \(\geq \frac{2}{3}\).
Universal Hash Family
Last edited: October 10, 2025\begin{equation} H = \qty {h: \qty {0,1}^{h} \to \qty {0,1}^{k}} \end{equation}
properties of pairwise independence:
- 1 wise independent: \(\forall y, \forall a\), \(P_{h \sim H}\qty [h\qty(y) = a] = 2^{-k}\)
- 2 wise independent: \(\forall y \neq y’\), \(P_{h \sim H}\qty [h\qty(y) = h\qty(y’)] = 2^{-k}\)
You will notice that this is not full randomness, just that there are some amount of randomness.
requirements
For all \(u_{i}, u_{j} \in U\) in the universe, \(n\) buckets in terms of desired randomness, with \(u_{i} \neq u_{j}\), then:
